Documentation ¶
Overview ¶
Copyright © 2019, Oracle and/or its affiliates.
Index ¶
- Constants
- func WithAuthTypeApiKey(with bool) wrapping.Option
- func WithCryptoEndpoint(with string) wrapping.Option
- func WithManagementEndpoint(with string) wrapping.Option
- type OptionFunc
- type Wrapper
- func (k *Wrapper) Decrypt(ctx context.Context, in *wrapping.BlobInfo, opt ...wrapping.Option) ([]byte, error)
- func (k *Wrapper) Encrypt(ctx context.Context, plaintext []byte, opt ...wrapping.Option) (*wrapping.BlobInfo, error)
- func (k *Wrapper) KeyId(_ context.Context) (string, error)
- func (k *Wrapper) SetConfig(_ context.Context, opt ...wrapping.Option) (*wrapping.WrapperConfig, error)
- func (k *Wrapper) Type(_ context.Context) (wrapping.WrapperType, error)
Constants ¶
View Source
const ( // OCI KMS key ID to use for encryption and decryption EnvOciKmsWrapperKeyId = "OCIKMS_WRAPPER_KEY_ID" EnvVaultOciKmsSealKeyId = "VAULT_OCIKMS_SEAL_KEY_ID" // OCI KMS crypto endpoint to use for encryption and decryption EnvOciKmsWrapperCryptoEndpoint = "OCIKMS_WRAPPER_CRYPTO_ENDPOINT" EnvVaultOciKmsSealCryptoEndpoint = "VAULT_OCIKMS_CRYPTO_ENDPOINT" // OCI KMS management endpoint to manage keys EnvOciKmsWrapperManagementEndpoint = "OCIKMS_WRAPPER_MANAGEMENT_ENDPOINT" EnvVaultOciKmsSealManagementEndpoint = "VAULT_OCIKMS_MANAGEMENT_ENDPOINT" // Maximum number of retries KMSMaximumNumberOfRetries = 5 )
View Source
const ( // keyId config KmsConfigKeyId = "key_id" // cryptoEndpoint config KmsConfigCryptoEndpoint = "crypto_endpoint" // managementEndpoint config KmsConfigManagementEndpoint = "management_endpoint" // authTypeApiKey config KmsConfigAuthTypeApiKey = "auth_type_api_key" )
Variables ¶
This section is empty.
Functions ¶
func WithAuthTypeApiKey ¶
WithAuthTypeApiKey provides a way to say to use api keys for auth
func WithCryptoEndpoint ¶
WithCryptoEndpoint provides a way to chose the endpoint
func WithManagementEndpoint ¶
WithManagementEndpoint provides a way to chose the management endpoint
Types ¶
type OptionFunc ¶
type OptionFunc func(*options) error
OptionFunc holds a function with local options
Click to show internal directories.
Click to hide internal directories.