Documentation ¶
Index ¶
- func CheckNameInList(listName []string, name string) bool
- func GetAPageSecrets(svc *secretsmanager.SecretsManager, token *string, maxResult int64) (*secretsmanager.ListSecretsOutput, error)
- func GetAWSCognitoAppName() string
- func GetAWSCognitoClientID() string
- func GetAWSCognitoClientSecret() string
- func GetAWSCognitoHost() string
- func GetAWSCognitoRegion() string
- func GetAWSRegions() ([]string, error)
- func GetFilterNames() []string
- func GetListSecrets(region string) ([]*secretsmanager.SecretListEntry, error)
- func GetSecretByARN(region, arn string) (secretsmanager.DescribeSecretOutput, error)
- func GetSecretValueByARN(region, arn string) (secretsmanager.GetSecretValueOutput, error)
- func UpdateSecretValue(region string, request secretsmanager.PutSecretValueInput) (secretsmanager.GetSecretValueOutput, error)
- func UpdateSecretValueBinary(region string, arn string, binaryVaue []byte) (secretsmanager.GetSecretValueOutput, error)
- func ValidPassword(username string, password string) (bool, error)
- type Accounts
- type CognitoToken
- type CognitoUserInfo
- type LoginClaims
- type Token
- type TokenPayload
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckNameInList ¶
func GetAPageSecrets ¶
func GetAPageSecrets(svc *secretsmanager.SecretsManager, token *string, maxResult int64) (*secretsmanager.ListSecretsOutput, error)
func GetAWSCognitoAppName ¶
func GetAWSCognitoAppName() string
func GetAWSCognitoClientID ¶
func GetAWSCognitoClientID() string
func GetAWSCognitoClientSecret ¶
func GetAWSCognitoClientSecret() string
func GetAWSCognitoHost ¶
func GetAWSCognitoHost() string
func GetAWSCognitoRegion ¶
func GetAWSCognitoRegion() string
func GetAWSRegions ¶
func GetFilterNames ¶
func GetFilterNames() []string
func GetListSecrets ¶
func GetListSecrets(region string) ([]*secretsmanager.SecretListEntry, error)
func GetSecretByARN ¶
func GetSecretByARN(region, arn string) (secretsmanager.DescribeSecretOutput, error)
func GetSecretValueByARN ¶
func GetSecretValueByARN(region, arn string) (secretsmanager.GetSecretValueOutput, error)
func UpdateSecretValue ¶
func UpdateSecretValue(region string, request secretsmanager.PutSecretValueInput) (secretsmanager.GetSecretValueOutput, error)
func UpdateSecretValueBinary ¶
func UpdateSecretValueBinary(region string, arn string, binaryVaue []byte) (secretsmanager.GetSecretValueOutput, error)
Types ¶
type CognitoToken ¶
type CognitoToken struct { AccessToken *string `json:"access_token"` TokenType *string `json:"token_type"` IDToken *string `json:"id_token"` ExpiresIn *int64 `json:"expires_in"` }
func GetAWSCognitoAccessToken ¶
func GetAWSCognitoAccessToken(authCode string) (CognitoToken, error)
type CognitoUserInfo ¶
type CognitoUserInfo struct { Sub string `json:"sub"` Name string `json:"name"` GivenName string `json:"given_name"` FamilyName string `json:"family_name"` PreferredUsername string `json:"preferred_username"` Email string `json:"email"` }
func GetAWSCognitoUserInfo ¶
func GetAWSCognitoUserInfo(accessToken string) (CognitoUserInfo, error)
func (CognitoUserInfo) IsValidEmail ¶
func (c CognitoUserInfo) IsValidEmail() (bool, error)
type LoginClaims ¶
type LoginClaims struct {
jwt.StandardClaims
}
type Token ¶
type Token struct { Token string `json:"token"` Expiry int `json:"expiry"` Created time.Time `json:"created"` }
func GenerateJWTToken ¶
func GenerateJWTToken(data TokenPayload, expiry int) (*Token, error)
type TokenPayload ¶
type TokenPayload struct {
Username string `json:"username"`
}
Click to show internal directories.
Click to hide internal directories.