Documentation ¶
Index ¶
Constants ¶
View Source
const (
EnvKeyDataSecretKey = "FLOGO_DATA_SECRET_KEY"
)
Variables ¶
This section is empty.
Functions ¶
func GetDataSecretKey ¶
func GetDataSecretKey() string
func PreProcessConfig ¶
func PropertyProcessor ¶
func SetSecretValueHandler ¶
func SetSecretValueHandler(pwdResolver SecretValueHandler)
Set secret value decoder
Types ¶
type KeyBasedSecretValueHandler ¶
type KeyBasedSecretValueHandler struct {
Key string
}
A key based secret value decoder. Secret value encryption/decryption is based on SHA256 and uses implementation from https://gist.github.com/willshiao/f4b03650e5a82561a460b4a15789cfa1
func (*KeyBasedSecretValueHandler) DecodeValue ¶
func (defaultResolver *KeyBasedSecretValueHandler) DecodeValue(value interface{}) (string, error)
Decode value based on a key
func (*KeyBasedSecretValueHandler) EncodeValue ¶
func (defaultResolver *KeyBasedSecretValueHandler) EncodeValue(value interface{}) (string, error)
type SecretValueHandler ¶
type SecretValueHandler interface { EncodeValue(value interface{}) (string, error) DecodeValue(value interface{}) (string, error) }
SecretValueDecoder defines method for decoding value
func GetSecretValueHandler ¶
func GetSecretValueHandler() SecretValueHandler
Get secret value handler. If not already set by SetSecretValueHandler(), will return default KeyBasedSecretValueDecoder where decoding key value is expected to be set through FLOGO_DATA_SECRET_KEY environment variable. If key is not set, a default key value(github.com/project-flogo/core/config.DATA_SECRET_KEY_DEFAULT) will be used.
Click to show internal directories.
Click to hide internal directories.