sdk

package
v0.1.9 Latest Latest
Warning

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

Go to latest
Published: Jan 24, 2024 License: Apache-2.0 Imports: 21 Imported by: 8

Documentation

Index

Constants

View Source
const (
	SDK_NSAME      = "alibabacloud-dkms-transfer-go-sdk"
	SDK_VERSION    = "0.1.9"
	SDK_USER_AGENT = SDK_NSAME + "/" + SDK_VERSION
)
View Source
const (
	EktIdLength              = 36
	GcmIvLength              = 12
	MigrationKeyVersionIdKey = "x-kms-migrationkeyversionid"
)
View Source
const (
	InvalidParamErrorCode                 = "InvalidParam"
	InvalidParameterErrorCode             = "InvalidParameter"
	UnauthorizedErrorCode                 = "Unauthorized"
	InvalidParamDateErrorMessage          = "The Param Date is invalid."
	InvalidParamAuthorizationErrorMessage = "The Param Authorization is invalid."
)
View Source
const (
	KmsKeySpecAes256 = "AES_256"
	KmsKeySpecAes128 = "AES_128"
)

Variables

This section is empty.

Functions

func EncodeUserEncryptionContext added in v0.1.6

func EncodeUserEncryptionContext(encryptionContext string) ([]byte, error)

func TransferTeaErrorClientError

func TransferTeaErrorClientError(err error) error

func TransferTeaErrorServerError

func TransferTeaErrorServerError(err error) error

Types

type ErrorContent

type ErrorContent struct {
	HttpCode  int
	RequestId string
	HostId    string
	Code      string
	Message   string
}

type KmsTransferClient

type KmsTransferClient struct {
	*kms.Client

	Verify string
	// contains filtered or unexported fields
}

func NewClientWithAccessKey

func NewClientWithAccessKey(regionId, accessKeyId, accessKeySecret string, dkmsConfig *dedicatedkmsopenapi.Config) (*KmsTransferClient, error)

func NewClientWithEcsRamRole

func NewClientWithEcsRamRole(regionId string, roleName string, dkmsConfig *dedicatedkmsopenapi.Config) (*KmsTransferClient, error)

func NewClientWithOptions

func NewClientWithOptions(regionId string, kmsConfig *sdk.Config, credential auth.Credential, dkmsConfig *dedicatedkmsopenapi.Config) (*KmsTransferClient, error)

func NewClientWithProvider

func NewClientWithProvider(regionId string, dkmsConfig *dedicatedkmsopenapi.Config, providers ...provider.Provider) (*KmsTransferClient, error)

func NewClientWithRamRoleArn

func NewClientWithRamRoleArn(regionId string, accessKeyId, accessKeySecret, roleArn, roleSessionName string, dkmsConfig *dedicatedkmsopenapi.Config) (*KmsTransferClient, error)

func NewClientWithRamRoleArnAndPolicy

func NewClientWithRamRoleArnAndPolicy(regionId string, accessKeyId, accessKeySecret, roleArn, roleSessionName, policy string, dkmsConfig *dedicatedkmsopenapi.Config) (*KmsTransferClient, error)

func NewClientWithRsaKeyPair

func NewClientWithRsaKeyPair(regionId string, publicKeyId, privateKey string, sessionExpiration int, dkmsConfig *dedicatedkmsopenapi.Config) (*KmsTransferClient, error)

func NewClientWithStsToken

func NewClientWithStsToken(regionId, stsAccessKeyId, stsAccessKeySecret, stsToken string, dkmsConfig *dedicatedkmsopenapi.Config) (*KmsTransferClient, error)

func (*KmsTransferClient) AsymmetricDecrypt

func (client *KmsTransferClient) AsymmetricDecrypt(request *kms.AsymmetricDecryptRequest) (*kms.AsymmetricDecryptResponse, error)

func (*KmsTransferClient) AsymmetricEncrypt

func (client *KmsTransferClient) AsymmetricEncrypt(request *kms.AsymmetricEncryptRequest) (*kms.AsymmetricEncryptResponse, error)

func (*KmsTransferClient) AsymmetricSign

func (client *KmsTransferClient) AsymmetricSign(request *kms.AsymmetricSignRequest) (*kms.AsymmetricSignResponse, error)

func (*KmsTransferClient) AsymmetricVerify

func (client *KmsTransferClient) AsymmetricVerify(request *kms.AsymmetricVerifyRequest) (*kms.AsymmetricVerifyResponse, error)

func (*KmsTransferClient) Decrypt

func (client *KmsTransferClient) Decrypt(request *kms.DecryptRequest) (*kms.DecryptResponse, error)

func (*KmsTransferClient) Encrypt

func (client *KmsTransferClient) Encrypt(request *kms.EncryptRequest) (*kms.EncryptResponse, error)

func (*KmsTransferClient) GenerateDataKey

func (client *KmsTransferClient) GenerateDataKey(request *kms.GenerateDataKeyRequest) (*kms.GenerateDataKeyResponse, error)

func (*KmsTransferClient) GenerateDataKeyWithoutPlaintext

func (*KmsTransferClient) GetPublicKey

func (client *KmsTransferClient) GetPublicKey(request *kms.GetPublicKeyRequest) (*kms.GetPublicKeyResponse, error)

func (*KmsTransferClient) GetSecretValue added in v0.1.0

func (client *KmsTransferClient) GetSecretValue(request *kms.GetSecretValueRequest) (*kms.GetSecretValueResponse, error)

func (*KmsTransferClient) SetVerify

func (client *KmsTransferClient) SetVerify(v string)

Jump to

Keyboard shortcuts

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