v20190118

package
v0.0.0-...-0832e34 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2020 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const APIVersion = "2019-01-18"

Variables

This section is empty.

Functions

This section is empty.

Types

type CancelKeyDeletionRequest

type CancelKeyDeletionRequest struct {
	*tchttp.BaseRequest

	// 需要被取消删除的CMK的唯一标志
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`
}

func NewCancelKeyDeletionRequest

func NewCancelKeyDeletionRequest() (request *CancelKeyDeletionRequest)

func (*CancelKeyDeletionRequest) FromJsonString

func (r *CancelKeyDeletionRequest) FromJsonString(s string) error

func (*CancelKeyDeletionRequest) ToJsonString

func (r *CancelKeyDeletionRequest) ToJsonString() string

type CancelKeyDeletionResponse

type CancelKeyDeletionResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 唯一标志被取消删除的CMK。
		KeyId *string `json:"KeyId,omitempty" name:"KeyId"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewCancelKeyDeletionResponse

func NewCancelKeyDeletionResponse() (response *CancelKeyDeletionResponse)

func (*CancelKeyDeletionResponse) FromJsonString

func (r *CancelKeyDeletionResponse) FromJsonString(s string) error

func (*CancelKeyDeletionResponse) ToJsonString

func (r *CancelKeyDeletionResponse) ToJsonString() string

type Client

type Client struct {
	common.Client
}

func NewClient

func NewClient(credential *common.Credential, region string, clientProfile *profile.ClientProfile) (client *Client, err error)

func NewClientWithSecretId

func NewClientWithSecretId(secretId, secretKey, region string) (client *Client, err error)

Deprecated

func (*Client) CancelKeyDeletion

func (c *Client) CancelKeyDeletion(request *CancelKeyDeletionRequest) (response *CancelKeyDeletionResponse, err error)

取消CMK的计划删除操作

func (*Client) CreateKey

func (c *Client) CreateKey(request *CreateKeyRequest) (response *CreateKeyResponse, err error)

创建用户管理数据密钥的主密钥CMK(Custom Master Key)。

func (*Client) Decrypt

func (c *Client) Decrypt(request *DecryptRequest) (response *DecryptResponse, err error)

本接口用于解密密文,得到明文数据。

func (*Client) DeleteImportedKeyMaterial

func (c *Client) DeleteImportedKeyMaterial(request *DeleteImportedKeyMaterialRequest) (response *DeleteImportedKeyMaterialResponse, err error)

用于删除导入的密钥材料,仅对EXTERNAL类型的CMK有效,该接口将CMK设置为PendingImport 状态,并不会删除CMK,在重新进行密钥导入后可继续使用。彻底删除CMK请使用 ScheduleKeyDeletion 接口。

func (*Client) DescribeKey

func (c *Client) DescribeKey(request *DescribeKeyRequest) (response *DescribeKeyResponse, err error)

用于获取指定KeyId的主密钥属性详情信息。

func (*Client) DescribeKeys

func (c *Client) DescribeKeys(request *DescribeKeysRequest) (response *DescribeKeysResponse, err error)

该接口用于批量获取主密钥属性信息。

func (*Client) DisableKey

func (c *Client) DisableKey(request *DisableKeyRequest) (response *DisableKeyResponse, err error)

本接口用于禁用一个主密钥,处于禁用状态的Key无法用于加密、解密操作。

func (*Client) DisableKeyRotation

func (c *Client) DisableKeyRotation(request *DisableKeyRotationRequest) (response *DisableKeyRotationResponse, err error)

对指定的CMK禁止密钥轮换功能。

func (*Client) DisableKeys

func (c *Client) DisableKeys(request *DisableKeysRequest) (response *DisableKeysResponse, err error)

该接口用于批量禁止CMK的使用。

func (*Client) EnableKey

func (c *Client) EnableKey(request *EnableKeyRequest) (response *EnableKeyResponse, err error)

用于启用一个指定的CMK。

func (*Client) EnableKeyRotation

func (c *Client) EnableKeyRotation(request *EnableKeyRotationRequest) (response *EnableKeyRotationResponse, err error)

对指定的CMK开启密钥轮换功能。

func (*Client) EnableKeys

func (c *Client) EnableKeys(request *EnableKeysRequest) (response *EnableKeysResponse, err error)

该接口用于批量启用CMK。

func (*Client) Encrypt

func (c *Client) Encrypt(request *EncryptRequest) (response *EncryptResponse, err error)

本接口用于加密最多为4KB任意数据,可用于加密数据库密码,RSA Key,或其它较小的敏感信息。对于应用的数据加密,使用GenerateDataKey生成的DataKey进行本地数据的加解密操作

func (*Client) GenerateDataKey

func (c *Client) GenerateDataKey(request *GenerateDataKeyRequest) (response *GenerateDataKeyResponse, err error)

本接口生成一个数据密钥,您可以用这个密钥进行本地数据的加密。

func (*Client) GenerateRandom

func (c *Client) GenerateRandom(request *GenerateRandomRequest) (response *GenerateRandomResponse, err error)

随机数生成接口。

func (*Client) GetKeyRotationStatus

func (c *Client) GetKeyRotationStatus(request *GetKeyRotationStatusRequest) (response *GetKeyRotationStatusResponse, err error)

查询指定的CMK是否开启了密钥轮换功能。

func (*Client) GetParametersForImport

func (c *Client) GetParametersForImport(request *GetParametersForImportRequest) (response *GetParametersForImportResponse, err error)

获取导入主密钥(CMK)材料的参数,返回的Token作为执行ImportKeyMaterial的参数之一,返回的PublicKey用于对自主导入密钥材料进行加密。返回的Token和PublicKey 24小时后失效,失效后如需重新导入,需要再次调用该接口获取新的Token和PublicKey。

func (*Client) GetServiceStatus

func (c *Client) GetServiceStatus(request *GetServiceStatusRequest) (response *GetServiceStatusResponse, err error)

用于查询该用户是否已开通KMS服务

func (*Client) ImportKeyMaterial

func (c *Client) ImportKeyMaterial(request *ImportKeyMaterialRequest) (response *ImportKeyMaterialResponse, err error)

用于导入密钥材料。只有类型为EXTERNAL 的CMK 才可以导入,导入的密钥材料使用 GetParametersForImport 获取的密钥进行加密。可以为指定的 CMK 重新导入密钥材料,并重新指定过期时间,但必须导入相同的密钥材料。CMK 密钥材料导入后不可以更换密钥材料。导入的密钥材料过期或者被删除后,指定的CMK将无法使用,需要再次导入相同的密钥材料才能正常使用。CMK是独立的,同样的密钥材料可导入不同的 CMK 中,但使用其中一个 CMK 加密的数据无法使用另一个 CMK解密。 只有Enabled 和 PendingImport状态的CMK可以导入密钥材料。

func (*Client) ListKeyDetail

func (c *Client) ListKeyDetail(request *ListKeyDetailRequest) (response *ListKeyDetailResponse, err error)

根据指定Offset和Limit获取主密钥列表详情。

func (*Client) ListKeys

func (c *Client) ListKeys(request *ListKeysRequest) (response *ListKeysResponse, err error)

列出账号下面状态为Enabled, Disabled 和 PendingImport 的CMK KeyId 列表

func (*Client) ReEncrypt

func (c *Client) ReEncrypt(request *ReEncryptRequest) (response *ReEncryptResponse, err error)

使用指定CMK对密文重新加密。

func (*Client) ScheduleKeyDeletion

func (c *Client) ScheduleKeyDeletion(request *ScheduleKeyDeletionRequest) (response *ScheduleKeyDeletionResponse, err error)

CMK计划删除接口,用于指定CMK删除的时间,可选时间区间为[7,30]天

func (*Client) UpdateAlias

func (c *Client) UpdateAlias(request *UpdateAliasRequest) (response *UpdateAliasResponse, err error)

用于修改CMK的别名。对于处于PendingDelete状态的CMK禁止修改。

func (*Client) UpdateKeyDescription

func (c *Client) UpdateKeyDescription(request *UpdateKeyDescriptionRequest) (response *UpdateKeyDescriptionResponse, err error)

该接口用于对指定的cmk修改描述信息。对于处于PendingDelete状态的CMK禁止修改。

type CreateKeyRequest

type CreateKeyRequest struct {
	*tchttp.BaseRequest

	// 作为密钥更容易辨识,更容易被人看懂的别名, 不可为空,1-60个字母数字 - _ 的组合。以 kms- 作为前缀的用于云产品使用,Alias 不可重复。
	Alias *string `json:"Alias,omitempty" name:"Alias"`

	// CMK 的描述,最大1024字节
	Description *string `json:"Description,omitempty" name:"Description"`

	// 指定key的用途。目前,仅支持"ENCRYPT_DECRYPT",默认为  "ENCRYPT_DECRYPT",即key用于加密和解密
	KeyUsage *string `json:"KeyUsage,omitempty" name:"KeyUsage"`

	// 指定key类型,默认为1,1表示默认类型,由KMS创建CMK密钥,2 表示EXTERNAL 类型,该类型需要用户导入密钥材料,参考 GetParametersForImport 和 ImportKeyMaterial 接口
	Type *uint64 `json:"Type,omitempty" name:"Type"`
}

func NewCreateKeyRequest

func NewCreateKeyRequest() (request *CreateKeyRequest)

func (*CreateKeyRequest) FromJsonString

func (r *CreateKeyRequest) FromJsonString(s string) error

func (*CreateKeyRequest) ToJsonString

func (r *CreateKeyRequest) ToJsonString() string

type CreateKeyResponse

type CreateKeyResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// CMK的全局唯一标识符
		KeyId *string `json:"KeyId,omitempty" name:"KeyId"`

		// 作为密钥更容易辨识,更容易被人看懂的别名
		Alias *string `json:"Alias,omitempty" name:"Alias"`

		// 密钥创建时间,unix时间戳
		CreateTime *uint64 `json:"CreateTime,omitempty" name:"CreateTime"`

		// CMK的描述
		// 注意:此字段可能返回 null,表示取不到有效值。
		Description *string `json:"Description,omitempty" name:"Description"`

		// CMK的状态
		KeyState *string `json:"KeyState,omitempty" name:"KeyState"`

		// CMK的用途
		KeyUsage *string `json:"KeyUsage,omitempty" name:"KeyUsage"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewCreateKeyResponse

func NewCreateKeyResponse() (response *CreateKeyResponse)

func (*CreateKeyResponse) FromJsonString

func (r *CreateKeyResponse) FromJsonString(s string) error

func (*CreateKeyResponse) ToJsonString

func (r *CreateKeyResponse) ToJsonString() string

type DecryptRequest

type DecryptRequest struct {
	*tchttp.BaseRequest

	// 待解密的密文数据
	CiphertextBlob *string `json:"CiphertextBlob,omitempty" name:"CiphertextBlob"`

	// key/value对的json字符串,如果Encrypt指定了该参数,则在调用Decrypt API时需要提供同样的参数,最大支持1024字符
	EncryptionContext *string `json:"EncryptionContext,omitempty" name:"EncryptionContext"`
}

func NewDecryptRequest

func NewDecryptRequest() (request *DecryptRequest)

func (*DecryptRequest) FromJsonString

func (r *DecryptRequest) FromJsonString(s string) error

func (*DecryptRequest) ToJsonString

func (r *DecryptRequest) ToJsonString() string

type DecryptResponse

type DecryptResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// CMK的全局唯一标识
		KeyId *string `json:"KeyId,omitempty" name:"KeyId"`

		// 解密后的明文。该字段是base64编码的,为了得到原始明文,调用方需要进行base64解码
		Plaintext *string `json:"Plaintext,omitempty" name:"Plaintext"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewDecryptResponse

func NewDecryptResponse() (response *DecryptResponse)

func (*DecryptResponse) FromJsonString

func (r *DecryptResponse) FromJsonString(s string) error

func (*DecryptResponse) ToJsonString

func (r *DecryptResponse) ToJsonString() string

type DeleteImportedKeyMaterialRequest

type DeleteImportedKeyMaterialRequest struct {
	*tchttp.BaseRequest

	// 指定需要删除密钥材料的EXTERNAL CMK。
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`
}

func NewDeleteImportedKeyMaterialRequest

func NewDeleteImportedKeyMaterialRequest() (request *DeleteImportedKeyMaterialRequest)

func (*DeleteImportedKeyMaterialRequest) FromJsonString

func (r *DeleteImportedKeyMaterialRequest) FromJsonString(s string) error

func (*DeleteImportedKeyMaterialRequest) ToJsonString

func (r *DeleteImportedKeyMaterialRequest) ToJsonString() string

type DeleteImportedKeyMaterialResponse

type DeleteImportedKeyMaterialResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewDeleteImportedKeyMaterialResponse

func NewDeleteImportedKeyMaterialResponse() (response *DeleteImportedKeyMaterialResponse)

func (*DeleteImportedKeyMaterialResponse) FromJsonString

func (r *DeleteImportedKeyMaterialResponse) FromJsonString(s string) error

func (*DeleteImportedKeyMaterialResponse) ToJsonString

func (r *DeleteImportedKeyMaterialResponse) ToJsonString() string

type DescribeKeyRequest

type DescribeKeyRequest struct {
	*tchttp.BaseRequest

	// CMK全局唯一标识符
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`
}

func NewDescribeKeyRequest

func NewDescribeKeyRequest() (request *DescribeKeyRequest)

func (*DescribeKeyRequest) FromJsonString

func (r *DescribeKeyRequest) FromJsonString(s string) error

func (*DescribeKeyRequest) ToJsonString

func (r *DescribeKeyRequest) ToJsonString() string

type DescribeKeyResponse

type DescribeKeyResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 密钥属性信息
		// 注意:此字段可能返回 null,表示取不到有效值。
		KeyMetadata *KeyMetadata `json:"KeyMetadata,omitempty" name:"KeyMetadata"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewDescribeKeyResponse

func NewDescribeKeyResponse() (response *DescribeKeyResponse)

func (*DescribeKeyResponse) FromJsonString

func (r *DescribeKeyResponse) FromJsonString(s string) error

func (*DescribeKeyResponse) ToJsonString

func (r *DescribeKeyResponse) ToJsonString() string

type DescribeKeysRequest

type DescribeKeysRequest struct {
	*tchttp.BaseRequest

	// 查询CMK的ID列表,批量查询一次最多支持100个KeyId
	KeyIds []*string `json:"KeyIds,omitempty" name:"KeyIds" list`
}

func NewDescribeKeysRequest

func NewDescribeKeysRequest() (request *DescribeKeysRequest)

func (*DescribeKeysRequest) FromJsonString

func (r *DescribeKeysRequest) FromJsonString(s string) error

func (*DescribeKeysRequest) ToJsonString

func (r *DescribeKeysRequest) ToJsonString() string

type DescribeKeysResponse

type DescribeKeysResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 返回的属性信息列表
		// 注意:此字段可能返回 null,表示取不到有效值。
		KeyMetadatas []*KeyMetadata `json:"KeyMetadatas,omitempty" name:"KeyMetadatas" list`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewDescribeKeysResponse

func NewDescribeKeysResponse() (response *DescribeKeysResponse)

func (*DescribeKeysResponse) FromJsonString

func (r *DescribeKeysResponse) FromJsonString(s string) error

func (*DescribeKeysResponse) ToJsonString

func (r *DescribeKeysResponse) ToJsonString() string

type DisableKeyRequest

type DisableKeyRequest struct {
	*tchttp.BaseRequest

	// CMK唯一标识符
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`
}

func NewDisableKeyRequest

func NewDisableKeyRequest() (request *DisableKeyRequest)

func (*DisableKeyRequest) FromJsonString

func (r *DisableKeyRequest) FromJsonString(s string) error

func (*DisableKeyRequest) ToJsonString

func (r *DisableKeyRequest) ToJsonString() string

type DisableKeyResponse

type DisableKeyResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewDisableKeyResponse

func NewDisableKeyResponse() (response *DisableKeyResponse)

func (*DisableKeyResponse) FromJsonString

func (r *DisableKeyResponse) FromJsonString(s string) error

func (*DisableKeyResponse) ToJsonString

func (r *DisableKeyResponse) ToJsonString() string

type DisableKeyRotationRequest

type DisableKeyRotationRequest struct {
	*tchttp.BaseRequest

	// CMK唯一标识符
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`
}

func NewDisableKeyRotationRequest

func NewDisableKeyRotationRequest() (request *DisableKeyRotationRequest)

func (*DisableKeyRotationRequest) FromJsonString

func (r *DisableKeyRotationRequest) FromJsonString(s string) error

func (*DisableKeyRotationRequest) ToJsonString

func (r *DisableKeyRotationRequest) ToJsonString() string

type DisableKeyRotationResponse

type DisableKeyRotationResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewDisableKeyRotationResponse

func NewDisableKeyRotationResponse() (response *DisableKeyRotationResponse)

func (*DisableKeyRotationResponse) FromJsonString

func (r *DisableKeyRotationResponse) FromJsonString(s string) error

func (*DisableKeyRotationResponse) ToJsonString

func (r *DisableKeyRotationResponse) ToJsonString() string

type DisableKeysRequest

type DisableKeysRequest struct {
	*tchttp.BaseRequest

	// 需要批量禁用的CMK Id 列表,CMK数量最大支持100
	KeyIds []*string `json:"KeyIds,omitempty" name:"KeyIds" list`
}

func NewDisableKeysRequest

func NewDisableKeysRequest() (request *DisableKeysRequest)

func (*DisableKeysRequest) FromJsonString

func (r *DisableKeysRequest) FromJsonString(s string) error

func (*DisableKeysRequest) ToJsonString

func (r *DisableKeysRequest) ToJsonString() string

type DisableKeysResponse

type DisableKeysResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewDisableKeysResponse

func NewDisableKeysResponse() (response *DisableKeysResponse)

func (*DisableKeysResponse) FromJsonString

func (r *DisableKeysResponse) FromJsonString(s string) error

func (*DisableKeysResponse) ToJsonString

func (r *DisableKeysResponse) ToJsonString() string

type EnableKeyRequest

type EnableKeyRequest struct {
	*tchttp.BaseRequest

	// CMK唯一标识符
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`
}

func NewEnableKeyRequest

func NewEnableKeyRequest() (request *EnableKeyRequest)

func (*EnableKeyRequest) FromJsonString

func (r *EnableKeyRequest) FromJsonString(s string) error

func (*EnableKeyRequest) ToJsonString

func (r *EnableKeyRequest) ToJsonString() string

type EnableKeyResponse

type EnableKeyResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewEnableKeyResponse

func NewEnableKeyResponse() (response *EnableKeyResponse)

func (*EnableKeyResponse) FromJsonString

func (r *EnableKeyResponse) FromJsonString(s string) error

func (*EnableKeyResponse) ToJsonString

func (r *EnableKeyResponse) ToJsonString() string

type EnableKeyRotationRequest

type EnableKeyRotationRequest struct {
	*tchttp.BaseRequest

	// CMK唯一标识符
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`
}

func NewEnableKeyRotationRequest

func NewEnableKeyRotationRequest() (request *EnableKeyRotationRequest)

func (*EnableKeyRotationRequest) FromJsonString

func (r *EnableKeyRotationRequest) FromJsonString(s string) error

func (*EnableKeyRotationRequest) ToJsonString

func (r *EnableKeyRotationRequest) ToJsonString() string

type EnableKeyRotationResponse

type EnableKeyRotationResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewEnableKeyRotationResponse

func NewEnableKeyRotationResponse() (response *EnableKeyRotationResponse)

func (*EnableKeyRotationResponse) FromJsonString

func (r *EnableKeyRotationResponse) FromJsonString(s string) error

func (*EnableKeyRotationResponse) ToJsonString

func (r *EnableKeyRotationResponse) ToJsonString() string

type EnableKeysRequest

type EnableKeysRequest struct {
	*tchttp.BaseRequest

	// 需要批量启用的CMK Id 列表, CMK数量最大支持100
	KeyIds []*string `json:"KeyIds,omitempty" name:"KeyIds" list`
}

func NewEnableKeysRequest

func NewEnableKeysRequest() (request *EnableKeysRequest)

func (*EnableKeysRequest) FromJsonString

func (r *EnableKeysRequest) FromJsonString(s string) error

func (*EnableKeysRequest) ToJsonString

func (r *EnableKeysRequest) ToJsonString() string

type EnableKeysResponse

type EnableKeysResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewEnableKeysResponse

func NewEnableKeysResponse() (response *EnableKeysResponse)

func (*EnableKeysResponse) FromJsonString

func (r *EnableKeysResponse) FromJsonString(s string) error

func (*EnableKeysResponse) ToJsonString

func (r *EnableKeysResponse) ToJsonString() string

type EncryptRequest

type EncryptRequest struct {
	*tchttp.BaseRequest

	// 调用CreateKey生成的CMK全局唯一标识符
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`

	// 被加密的明文数据,该字段必须使用base64编码,原文最大长度支持4K
	Plaintext *string `json:"Plaintext,omitempty" name:"Plaintext"`

	// key/value对的json字符串,如果指定了该参数,则在调用Decrypt API时需要提供同样的参数,最大支持1024个字符
	EncryptionContext *string `json:"EncryptionContext,omitempty" name:"EncryptionContext"`
}

func NewEncryptRequest

func NewEncryptRequest() (request *EncryptRequest)

func (*EncryptRequest) FromJsonString

func (r *EncryptRequest) FromJsonString(s string) error

func (*EncryptRequest) ToJsonString

func (r *EncryptRequest) ToJsonString() string

type EncryptResponse

type EncryptResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 加密后经过base64编码的密文
		CiphertextBlob *string `json:"CiphertextBlob,omitempty" name:"CiphertextBlob"`

		// 加密使用的CMK的全局唯一标识
		KeyId *string `json:"KeyId,omitempty" name:"KeyId"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewEncryptResponse

func NewEncryptResponse() (response *EncryptResponse)

func (*EncryptResponse) FromJsonString

func (r *EncryptResponse) FromJsonString(s string) error

func (*EncryptResponse) ToJsonString

func (r *EncryptResponse) ToJsonString() string

type GenerateDataKeyRequest

type GenerateDataKeyRequest struct {
	*tchttp.BaseRequest

	// CMK全局唯一标识符
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`

	// 指定生成Datakey的加密算法以及Datakey大小,AES_128或者AES_256。KeySpec 和 NumberOfBytes 必须指定一个
	KeySpec *string `json:"KeySpec,omitempty" name:"KeySpec"`

	// 生成的DataKey的长度,同时指定NumberOfBytes和KeySpec时,以NumberOfBytes为准。最小值为1, 最大值为1024。KeySpec 和 NumberOfBytes 必须指定一个
	NumberOfBytes *uint64 `json:"NumberOfBytes,omitempty" name:"NumberOfBytes"`

	// key/value对的json字符串,如果使用该字段,则返回的DataKey在解密时需要填入相同的字符串
	EncryptionContext *string `json:"EncryptionContext,omitempty" name:"EncryptionContext"`
}

func NewGenerateDataKeyRequest

func NewGenerateDataKeyRequest() (request *GenerateDataKeyRequest)

func (*GenerateDataKeyRequest) FromJsonString

func (r *GenerateDataKeyRequest) FromJsonString(s string) error

func (*GenerateDataKeyRequest) ToJsonString

func (r *GenerateDataKeyRequest) ToJsonString() string

type GenerateDataKeyResponse

type GenerateDataKeyResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// CMK的全局唯一标识
		KeyId *string `json:"KeyId,omitempty" name:"KeyId"`

		// 生成的DataKey的明文,该明文使用base64编码,用户需要使用base64解码得到明文
		Plaintext *string `json:"Plaintext,omitempty" name:"Plaintext"`

		// DataKey加密后经过base64编码的密文,用户需要自行保存密文
		CiphertextBlob *string `json:"CiphertextBlob,omitempty" name:"CiphertextBlob"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewGenerateDataKeyResponse

func NewGenerateDataKeyResponse() (response *GenerateDataKeyResponse)

func (*GenerateDataKeyResponse) FromJsonString

func (r *GenerateDataKeyResponse) FromJsonString(s string) error

func (*GenerateDataKeyResponse) ToJsonString

func (r *GenerateDataKeyResponse) ToJsonString() string

type GenerateRandomRequest

type GenerateRandomRequest struct {
	*tchttp.BaseRequest

	// 生成的随机数的长度。最小值为1, 最大值为1024。
	NumberOfBytes *uint64 `json:"NumberOfBytes,omitempty" name:"NumberOfBytes"`
}

func NewGenerateRandomRequest

func NewGenerateRandomRequest() (request *GenerateRandomRequest)

func (*GenerateRandomRequest) FromJsonString

func (r *GenerateRandomRequest) FromJsonString(s string) error

func (*GenerateRandomRequest) ToJsonString

func (r *GenerateRandomRequest) ToJsonString() string

type GenerateRandomResponse

type GenerateRandomResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 生成的随机数的明文,该明文使用base64编码,用户需要使用base64解码得到明文。
		Plaintext *string `json:"Plaintext,omitempty" name:"Plaintext"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewGenerateRandomResponse

func NewGenerateRandomResponse() (response *GenerateRandomResponse)

func (*GenerateRandomResponse) FromJsonString

func (r *GenerateRandomResponse) FromJsonString(s string) error

func (*GenerateRandomResponse) ToJsonString

func (r *GenerateRandomResponse) ToJsonString() string

type GetKeyRotationStatusRequest

type GetKeyRotationStatusRequest struct {
	*tchttp.BaseRequest

	// CMK唯一标识符
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`
}

func NewGetKeyRotationStatusRequest

func NewGetKeyRotationStatusRequest() (request *GetKeyRotationStatusRequest)

func (*GetKeyRotationStatusRequest) FromJsonString

func (r *GetKeyRotationStatusRequest) FromJsonString(s string) error

func (*GetKeyRotationStatusRequest) ToJsonString

func (r *GetKeyRotationStatusRequest) ToJsonString() string

type GetKeyRotationStatusResponse

type GetKeyRotationStatusResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 密钥轮换是否开启
		KeyRotationEnabled *bool `json:"KeyRotationEnabled,omitempty" name:"KeyRotationEnabled"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewGetKeyRotationStatusResponse

func NewGetKeyRotationStatusResponse() (response *GetKeyRotationStatusResponse)

func (*GetKeyRotationStatusResponse) FromJsonString

func (r *GetKeyRotationStatusResponse) FromJsonString(s string) error

func (*GetKeyRotationStatusResponse) ToJsonString

func (r *GetKeyRotationStatusResponse) ToJsonString() string

type GetParametersForImportRequest

type GetParametersForImportRequest struct {
	*tchttp.BaseRequest

	// CMK的唯一标识,获取密钥参数的CMK必须是EXTERNAL类型,即在CreateKey时指定Type=2 类型的CMK。
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`

	// 指定加密密钥材料的算法,目前支持RSAES_PKCS1_V1_5、RSAES_OAEP_SHA_1、RSAES_OAEP_SHA_256
	WrappingAlgorithm *string `json:"WrappingAlgorithm,omitempty" name:"WrappingAlgorithm"`

	// 指定加密密钥材料的类型,目前只支持RSA_2048
	WrappingKeySpec *string `json:"WrappingKeySpec,omitempty" name:"WrappingKeySpec"`
}

func NewGetParametersForImportRequest

func NewGetParametersForImportRequest() (request *GetParametersForImportRequest)

func (*GetParametersForImportRequest) FromJsonString

func (r *GetParametersForImportRequest) FromJsonString(s string) error

func (*GetParametersForImportRequest) ToJsonString

func (r *GetParametersForImportRequest) ToJsonString() string

type GetParametersForImportResponse

type GetParametersForImportResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// CMK的唯一标识,用于指定目标导入密钥材料的CMK。
		KeyId *string `json:"KeyId,omitempty" name:"KeyId"`

		// 导入密钥材料需要的token,用于作为 ImportKeyMaterial 的参数。
		ImportToken *string `json:"ImportToken,omitempty" name:"ImportToken"`

		// 用于加密密钥材料的RSA公钥,base64编码。使用PublicKey base64解码后的公钥将导入密钥进行加密后作为 ImportKeyMaterial 的参数。
		PublicKey *string `json:"PublicKey,omitempty" name:"PublicKey"`

		// 该导出token和公钥的有效期,超过该时间后无法导入,需要重新调用GetParametersForImport获取。
		ParametersValidTo *uint64 `json:"ParametersValidTo,omitempty" name:"ParametersValidTo"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewGetParametersForImportResponse

func NewGetParametersForImportResponse() (response *GetParametersForImportResponse)

func (*GetParametersForImportResponse) FromJsonString

func (r *GetParametersForImportResponse) FromJsonString(s string) error

func (*GetParametersForImportResponse) ToJsonString

func (r *GetParametersForImportResponse) ToJsonString() string

type GetServiceStatusRequest

type GetServiceStatusRequest struct {
	*tchttp.BaseRequest
}

func NewGetServiceStatusRequest

func NewGetServiceStatusRequest() (request *GetServiceStatusRequest)

func (*GetServiceStatusRequest) FromJsonString

func (r *GetServiceStatusRequest) FromJsonString(s string) error

func (*GetServiceStatusRequest) ToJsonString

func (r *GetServiceStatusRequest) ToJsonString() string

type GetServiceStatusResponse

type GetServiceStatusResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// KMS服务是否开通, true 表示已开通
		ServiceEnabled *bool `json:"ServiceEnabled,omitempty" name:"ServiceEnabled"`

		// 服务不可用类型: 0-未购买,1-正常, 2-欠费停服, 3-资源释放
		// 注意:此字段可能返回 null,表示取不到有效值。
		InvalidType *int64 `json:"InvalidType,omitempty" name:"InvalidType"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewGetServiceStatusResponse

func NewGetServiceStatusResponse() (response *GetServiceStatusResponse)

func (*GetServiceStatusResponse) FromJsonString

func (r *GetServiceStatusResponse) FromJsonString(s string) error

func (*GetServiceStatusResponse) ToJsonString

func (r *GetServiceStatusResponse) ToJsonString() string

type ImportKeyMaterialRequest

type ImportKeyMaterialRequest struct {
	*tchttp.BaseRequest

	// 使用GetParametersForImport 返回的PublicKey加密后的密钥材料base64编码。对于国密版本region的KMS,导入的密钥材料长度要求为 128 bit,FIPS版本region的KMS, 导入的密钥材料长度要求为 256 bit。
	EncryptedKeyMaterial *string `json:"EncryptedKeyMaterial,omitempty" name:"EncryptedKeyMaterial"`

	// 通过调用GetParametersForImport获得的导入令牌。
	ImportToken *string `json:"ImportToken,omitempty" name:"ImportToken"`

	// 指定导入密钥材料的CMK,需要和GetParametersForImport 指定的CMK相同。
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`

	// 密钥材料过期时间 unix 时间戳,不指定或者 0 表示密钥材料不会过期,若指定过期时间,需要大于当前时间点,最大支持 2147443200。
	ValidTo *uint64 `json:"ValidTo,omitempty" name:"ValidTo"`
}

func NewImportKeyMaterialRequest

func NewImportKeyMaterialRequest() (request *ImportKeyMaterialRequest)

func (*ImportKeyMaterialRequest) FromJsonString

func (r *ImportKeyMaterialRequest) FromJsonString(s string) error

func (*ImportKeyMaterialRequest) ToJsonString

func (r *ImportKeyMaterialRequest) ToJsonString() string

type ImportKeyMaterialResponse

type ImportKeyMaterialResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewImportKeyMaterialResponse

func NewImportKeyMaterialResponse() (response *ImportKeyMaterialResponse)

func (*ImportKeyMaterialResponse) FromJsonString

func (r *ImportKeyMaterialResponse) FromJsonString(s string) error

func (*ImportKeyMaterialResponse) ToJsonString

func (r *ImportKeyMaterialResponse) ToJsonString() string

type Key

type Key struct {

	// CMK的全局唯一标识。
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`
}

type KeyMetadata

type KeyMetadata struct {

	// CMK的全局唯一标识
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`

	// 作为密钥更容易辨识,更容易被人看懂的别名
	Alias *string `json:"Alias,omitempty" name:"Alias"`

	// 密钥创建时间
	CreateTime *uint64 `json:"CreateTime,omitempty" name:"CreateTime"`

	// CMK的描述
	Description *string `json:"Description,omitempty" name:"Description"`

	// CMK的状态, 取值为:Enabled | Disabled | PendingDelete | PendingImport
	KeyState *string `json:"KeyState,omitempty" name:"KeyState"`

	// CMK用途,当前是 ENCRYPT_DECRYPT
	KeyUsage *string `json:"KeyUsage,omitempty" name:"KeyUsage"`

	// CMK类型,2 表示符合FIPS标准,4表示符合国密标准
	Type *int64 `json:"Type,omitempty" name:"Type"`

	// 创建者
	CreatorUin *uint64 `json:"CreatorUin,omitempty" name:"CreatorUin"`

	// 是否开启了密钥轮换功能
	KeyRotationEnabled *bool `json:"KeyRotationEnabled,omitempty" name:"KeyRotationEnabled"`

	// CMK的创建者,用户创建的为 user,授权各云产品自动创建的为对应的产品名
	Owner *string `json:"Owner,omitempty" name:"Owner"`

	// 在密钥轮换开启状态下,下次轮换的时间
	NextRotateTime *uint64 `json:"NextRotateTime,omitempty" name:"NextRotateTime"`

	// 计划删除的时间
	// 注意:此字段可能返回 null,表示取不到有效值。
	DeletionDate *uint64 `json:"DeletionDate,omitempty" name:"DeletionDate"`

	// CMK 密钥材料类型,由KMS创建的为: TENCENT_KMS, 由用户导入的类型为:EXTERNAL
	// 注意:此字段可能返回 null,表示取不到有效值。
	Origin *string `json:"Origin,omitempty" name:"Origin"`

	// 在Origin为  EXTERNAL 时有效,表示密钥材料的有效日期, 0 表示不过期
	// 注意:此字段可能返回 null,表示取不到有效值。
	ValidTo *uint64 `json:"ValidTo,omitempty" name:"ValidTo"`
}

type ListKeyDetailRequest

type ListKeyDetailRequest struct {
	*tchttp.BaseRequest

	// 含义跟 SQL 查询的 Offset 一致,表示本次获取从按一定顺序排列数组的第 Offset 个元素开始,缺省为0
	Offset *uint64 `json:"Offset,omitempty" name:"Offset"`

	// 含义跟 SQL 查询的 Limit 一致,表示本次获最多获取 Limit 个元素。缺省值为10,最大值为200
	Limit *uint64 `json:"Limit,omitempty" name:"Limit"`

	// 根据创建者角色筛选,默认 0 表示用户自己创建的cmk, 1 表示授权其它云产品自动创建的cmk
	Role *uint64 `json:"Role,omitempty" name:"Role"`

	// 根据CMK创建时间排序, 0 表示按照降序排序,1表示按照升序排序
	OrderType *uint64 `json:"OrderType,omitempty" name:"OrderType"`

	// 根据CMK状态筛选, 0表示全部CMK, 1 表示仅查询Enabled CMK, 2 表示仅查询Disabled CMK,3 表示查询PendingDelete 状态的CMK(处于计划删除状态的Key),4 表示查询 PendingImport 状态的CMK
	KeyState *uint64 `json:"KeyState,omitempty" name:"KeyState"`

	// 根据KeyId或者Alias进行模糊匹配查询
	SearchKeyAlias *string `json:"SearchKeyAlias,omitempty" name:"SearchKeyAlias"`

	// 根据CMK类型筛选, "TENCENT_KMS" 表示筛选密钥材料由KMS创建的CMK, "EXTERNAL" 表示筛选密钥材料需要用户导入的 EXTERNAL类型CMK,"ALL" 或者不设置表示两种类型都查询,大小写敏感。
	Origin *string `json:"Origin,omitempty" name:"Origin"`
}

func NewListKeyDetailRequest

func NewListKeyDetailRequest() (request *ListKeyDetailRequest)

func (*ListKeyDetailRequest) FromJsonString

func (r *ListKeyDetailRequest) FromJsonString(s string) error

func (*ListKeyDetailRequest) ToJsonString

func (r *ListKeyDetailRequest) ToJsonString() string

type ListKeyDetailResponse

type ListKeyDetailResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// CMK的总数量
		TotalCount *uint64 `json:"TotalCount,omitempty" name:"TotalCount"`

		// 返回的属性信息列表,此字段可能返回 null,表示取不到有效值。
		// 注意:此字段可能返回 null,表示取不到有效值。
		KeyMetadatas []*KeyMetadata `json:"KeyMetadatas,omitempty" name:"KeyMetadatas" list`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewListKeyDetailResponse

func NewListKeyDetailResponse() (response *ListKeyDetailResponse)

func (*ListKeyDetailResponse) FromJsonString

func (r *ListKeyDetailResponse) FromJsonString(s string) error

func (*ListKeyDetailResponse) ToJsonString

func (r *ListKeyDetailResponse) ToJsonString() string

type ListKeysRequest

type ListKeysRequest struct {
	*tchttp.BaseRequest

	// 含义跟 SQL 查询的 Offset 一致,表示本次获取从按一定顺序排列数组的第 Offset 个元素开始,缺省为0
	Offset *uint64 `json:"Offset,omitempty" name:"Offset"`

	// 含义跟 SQL 查询的 Limit 一致,表示本次获最多获取 Limit 个元素。缺省值为10,最大值为200
	Limit *uint64 `json:"Limit,omitempty" name:"Limit"`

	// 根据创建者角色筛选,默认 0 表示用户自己创建的cmk, 1 表示授权其它云产品自动创建的cmk
	Role *uint64 `json:"Role,omitempty" name:"Role"`
}

func NewListKeysRequest

func NewListKeysRequest() (request *ListKeysRequest)

func (*ListKeysRequest) FromJsonString

func (r *ListKeysRequest) FromJsonString(s string) error

func (*ListKeysRequest) ToJsonString

func (r *ListKeysRequest) ToJsonString() string

type ListKeysResponse

type ListKeysResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// CMK列表数组
		// 注意:此字段可能返回 null,表示取不到有效值。
		Keys []*Key `json:"Keys,omitempty" name:"Keys" list`

		// CMK的总数量
		TotalCount *uint64 `json:"TotalCount,omitempty" name:"TotalCount"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewListKeysResponse

func NewListKeysResponse() (response *ListKeysResponse)

func (*ListKeysResponse) FromJsonString

func (r *ListKeysResponse) FromJsonString(s string) error

func (*ListKeysResponse) ToJsonString

func (r *ListKeysResponse) ToJsonString() string

type ReEncryptRequest

type ReEncryptRequest struct {
	*tchttp.BaseRequest

	// 需要重新加密的密文
	CiphertextBlob *string `json:"CiphertextBlob,omitempty" name:"CiphertextBlob"`

	// 重新加密使用的CMK,如果为空,则使用密文原有的CMK重新加密(若密钥没有轮换则密文不会刷新)
	DestinationKeyId *string `json:"DestinationKeyId,omitempty" name:"DestinationKeyId"`

	// CiphertextBlob 密文加密时使用的key/value对的json字符串。如果加密时未使用,则为空
	SourceEncryptionContext *string `json:"SourceEncryptionContext,omitempty" name:"SourceEncryptionContext"`

	// 重新加密使用的key/value对的json字符串,如果使用该字段,则返回的新密文在解密时需要填入相同的字符串
	DestinationEncryptionContext *string `json:"DestinationEncryptionContext,omitempty" name:"DestinationEncryptionContext"`
}

func NewReEncryptRequest

func NewReEncryptRequest() (request *ReEncryptRequest)

func (*ReEncryptRequest) FromJsonString

func (r *ReEncryptRequest) FromJsonString(s string) error

func (*ReEncryptRequest) ToJsonString

func (r *ReEncryptRequest) ToJsonString() string

type ReEncryptResponse

type ReEncryptResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 重新加密后的密文
		CiphertextBlob *string `json:"CiphertextBlob,omitempty" name:"CiphertextBlob"`

		// 重新加密使用的CMK
		KeyId *string `json:"KeyId,omitempty" name:"KeyId"`

		// 重新加密前密文使用的CMK
		SourceKeyId *string `json:"SourceKeyId,omitempty" name:"SourceKeyId"`

		// true表示密文已经重新加密。同一个CMK进行重加密,在密钥没有发生轮换的情况下不会进行实际重新加密操作,返回原密文
		ReEncrypted *bool `json:"ReEncrypted,omitempty" name:"ReEncrypted"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewReEncryptResponse

func NewReEncryptResponse() (response *ReEncryptResponse)

func (*ReEncryptResponse) FromJsonString

func (r *ReEncryptResponse) FromJsonString(s string) error

func (*ReEncryptResponse) ToJsonString

func (r *ReEncryptResponse) ToJsonString() string

type ScheduleKeyDeletionRequest

type ScheduleKeyDeletionRequest struct {
	*tchttp.BaseRequest

	// CMK的唯一标志
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`

	// 计划删除时间区间[7,30]
	PendingWindowInDays *uint64 `json:"PendingWindowInDays,omitempty" name:"PendingWindowInDays"`
}

func NewScheduleKeyDeletionRequest

func NewScheduleKeyDeletionRequest() (request *ScheduleKeyDeletionRequest)

func (*ScheduleKeyDeletionRequest) FromJsonString

func (r *ScheduleKeyDeletionRequest) FromJsonString(s string) error

func (*ScheduleKeyDeletionRequest) ToJsonString

func (r *ScheduleKeyDeletionRequest) ToJsonString() string

type ScheduleKeyDeletionResponse

type ScheduleKeyDeletionResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 计划删除执行时间
		DeletionDate *uint64 `json:"DeletionDate,omitempty" name:"DeletionDate"`

		// 唯一标志被计划删除的CMK
		KeyId *string `json:"KeyId,omitempty" name:"KeyId"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewScheduleKeyDeletionResponse

func NewScheduleKeyDeletionResponse() (response *ScheduleKeyDeletionResponse)

func (*ScheduleKeyDeletionResponse) FromJsonString

func (r *ScheduleKeyDeletionResponse) FromJsonString(s string) error

func (*ScheduleKeyDeletionResponse) ToJsonString

func (r *ScheduleKeyDeletionResponse) ToJsonString() string

type UpdateAliasRequest

type UpdateAliasRequest struct {
	*tchttp.BaseRequest

	// 新的别名,1-60个字符或数字的组合
	Alias *string `json:"Alias,omitempty" name:"Alias"`

	// CMK的全局唯一标识符
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`
}

func NewUpdateAliasRequest

func NewUpdateAliasRequest() (request *UpdateAliasRequest)

func (*UpdateAliasRequest) FromJsonString

func (r *UpdateAliasRequest) FromJsonString(s string) error

func (*UpdateAliasRequest) ToJsonString

func (r *UpdateAliasRequest) ToJsonString() string

type UpdateAliasResponse

type UpdateAliasResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewUpdateAliasResponse

func NewUpdateAliasResponse() (response *UpdateAliasResponse)

func (*UpdateAliasResponse) FromJsonString

func (r *UpdateAliasResponse) FromJsonString(s string) error

func (*UpdateAliasResponse) ToJsonString

func (r *UpdateAliasResponse) ToJsonString() string

type UpdateKeyDescriptionRequest

type UpdateKeyDescriptionRequest struct {
	*tchttp.BaseRequest

	// 新的描述信息,最大支持1024字节
	Description *string `json:"Description,omitempty" name:"Description"`

	// 需要修改描述信息的的CMK ID
	KeyId *string `json:"KeyId,omitempty" name:"KeyId"`
}

func NewUpdateKeyDescriptionRequest

func NewUpdateKeyDescriptionRequest() (request *UpdateKeyDescriptionRequest)

func (*UpdateKeyDescriptionRequest) FromJsonString

func (r *UpdateKeyDescriptionRequest) FromJsonString(s string) error

func (*UpdateKeyDescriptionRequest) ToJsonString

func (r *UpdateKeyDescriptionRequest) ToJsonString() string

type UpdateKeyDescriptionResponse

type UpdateKeyDescriptionResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewUpdateKeyDescriptionResponse

func NewUpdateKeyDescriptionResponse() (response *UpdateKeyDescriptionResponse)

func (*UpdateKeyDescriptionResponse) FromJsonString

func (r *UpdateKeyDescriptionResponse) FromJsonString(s string) error

func (*UpdateKeyDescriptionResponse) ToJsonString

func (r *UpdateKeyDescriptionResponse) ToJsonString() string

Jump to

Keyboard shortcuts

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