AWS SDK Version 3 for .NET
API Reference

AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.

Contains metadata about a customer master key (CMK).

This data type is used as a response element for the CreateKey and DescribeKey operations.

Inheritance Hierarchy

System.Object
  Amazon.KeyManagementService.Model.KeyMetadata

Namespace: Amazon.KeyManagementService.Model
Assembly: AWSSDK.KeyManagementService.dll
Version: 3.x.y.z

Syntax

C#
public class KeyMetadata

The KeyMetadata type exposes the following members

Constructors

NameDescription
Public Method KeyMetadata()

Properties

NameTypeDescription
Public Property Arn System.String

Gets and sets the property Arn.

The Amazon Resource Name (ARN) of the CMK. For examples, see AWS Key Management Service (AWS KMS) in the Example ARNs section of the AWS General Reference.

Public Property AWSAccountId System.String

Gets and sets the property AWSAccountId.

The twelve-digit account ID of the AWS account that owns the CMK.

Public Property CreationDate System.DateTime

Gets and sets the property CreationDate.

The date and time when the CMK was created.

Public Property DeletionDate System.DateTime

Gets and sets the property DeletionDate.

The date and time after which AWS KMS deletes the CMK. This value is present only when KeyState is PendingDeletion, otherwise this value is omitted.

Public Property Description System.String

Gets and sets the property Description.

The description of the CMK.

Public Property Enabled System.Boolean

Gets and sets the property Enabled.

Specifies whether the CMK is enabled. When KeyState is Enabled this value is true, otherwise it is false.

Public Property ExpirationModel Amazon.KeyManagementService.ExpirationModelType

Gets and sets the property ExpirationModel.

Specifies whether the CMK's key material expires. This value is present only when Origin is EXTERNAL, otherwise this value is omitted.

Public Property KeyId System.String

Gets and sets the property KeyId.

The globally unique identifier for the CMK.

Public Property KeyManager Amazon.KeyManagementService.KeyManagerType

Gets and sets the property KeyManager.

The CMK's manager. CMKs are either customer-managed or AWS-managed. For more information about the difference, see Customer Master Keys in the AWS Key Management Service Developer Guide.

Public Property KeyState Amazon.KeyManagementService.KeyState

Gets and sets the property KeyState.

The state of the CMK.

For more information about how key state affects the use of a CMK, see How Key State Affects the Use of a Customer Master Key in the AWS Key Management Service Developer Guide.

Public Property KeyUsage Amazon.KeyManagementService.KeyUsageType

Gets and sets the property KeyUsage.

The cryptographic operations for which you can use the CMK. Currently the only allowed value is ENCRYPT_DECRYPT, which means you can use the CMK for the Encrypt and Decrypt operations.

Public Property Origin Amazon.KeyManagementService.OriginType

Gets and sets the property Origin.

The source of the CMK's key material. When this value is AWS_KMS, AWS KMS created the key material. When this value is EXTERNAL, the key material was imported from your existing key management infrastructure or the CMK lacks key material.

Public Property ValidTo System.DateTime

Gets and sets the property ValidTo.

The time at which the imported key material expires. When the key material expires, AWS KMS deletes the key material and the CMK becomes unusable. This value is present only for CMKs whose Origin is EXTERNAL and whose ExpirationModel is KEY_MATERIAL_EXPIRES, otherwise this value is omitted.

Version Information

.NET Standard:
Supported in: 1.3

.NET Framework:
Supported in: 4.5, 4.0, 3.5

Portable Class Library:
Supported in: Windows Store Apps
Supported in: Windows Phone 8.1
Supported in: Xamarin Android
Supported in: Xamarin iOS (Unified)
Supported in: Xamarin.Forms