sm

package
v0.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 11, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckIfSecretExists

func CheckIfSecretExists(id string) (bool, error)

CheckIfSecretExists determines if the input secret ID already exists in AWS Secrets Manager

func CreateSecretBinary

func CreateSecretBinary(id string, data []byte, description string, tagsCSV string) (secret *secretsmanager.CreateSecretOutput, err error)

CreateSecretBinary will create a new SecretBinary value to a specific secret by Name (id)

func CreateSecretString

func CreateSecretString(id string, data string, description string, tagsCSV string) (secret *secretsmanager.CreateSecretOutput, err error)

CreateSecretString will create a new SecretString value to a specific secret by Name (id)

func DeleteSecret

func DeleteSecret(id string, force bool) (secret *secretsmanager.DeleteSecretOutput, err error)

DeleteSecret will retrieve a specific secret by Name (id)

func DescribeSecret

func DescribeSecret(id string) (secret *secretsmanager.DescribeSecretOutput, err error)

DescribeSecret retrieves the describe data for a specific secret by Name (id)

func GetSecret

func GetSecret(id string) (secret *secretsmanager.GetSecretValueOutput, err error)

GetSecret will retrieve a specific secret by Name (id)

func ListSecrets

func ListSecrets() (secrets []secretsmanager.SecretListEntry, err error)

ListSecrets will retrieval ALL secrets via pagination of 100 per page. It will return once all pages have been processed.

func PutSecretBinary

func PutSecretBinary(id string, data []byte) (secret *secretsmanager.PutSecretValueOutput, err error)

PutSecretBinary will put an updated SecretBinary value to a specific secret by Name (id)

func PutSecretString

func PutSecretString(id string, data string) (secret *secretsmanager.PutSecretValueOutput, err error)

PutSecretString will put an updated SecretString value to a specific secret by Name (id)

func RetrieveSecret

func RetrieveSecret(variableName string) (secretBytes []byte, err error)

RetrieveSecret will pull the AWS Secrets Manager value and parse out the specific value needed.

NOTE: Refactor of https://github.com/cyberark/summon-aws-secrets/blob/master/main.go This was needed to have the command return the byte stream rather than have it write to STDOUT

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL