1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41
|
package kms
//The rersponse body from KMS, based on which action you take
//http://docs.aws.amazon.com/kms/latest/APIReference/API_Operations.html
type DescribeKeyResp struct {
KeyMetadata struct {
AWSAccountId string
Arn string
CreationDate float64
Description string
Enabled bool
KeyId string
KeyUsage string
}
}
type AliasInfo struct {
AliasArn string
AliasName string
TargetKeyId string
}
type ListAliasesResp struct {
Aliases []AliasInfo
NextMarker string
Truncated bool
}
type EncryptResp struct {
CiphertextBlob []byte
KeyId string
}
type DecryptResp struct {
KeyId string
Plaintext []byte
}
//For some actions, we just only check if it is success by status code. (200)
//1. EnableKey
//2. DisableKey
|