/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace Macie2 { namespace Model { /** *

Provides information about the default server-side encryption settings for an * S3 bucket. For detailed information about these settings, see Setting * default server-side encryption behavior for Amazon S3 buckets in the * Amazon Simple Storage Service User Guide.

See Also:

AWS * API Reference

*/ class BucketServerSideEncryption { public: AWS_MACIE2_API BucketServerSideEncryption(); AWS_MACIE2_API BucketServerSideEncryption(Aws::Utils::Json::JsonView jsonValue); AWS_MACIE2_API BucketServerSideEncryption& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_MACIE2_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

The Amazon Resource Name (ARN) or unique identifier (key ID) for the KMS key * that's used by default to encrypt objects that are added to the bucket. This * value is null if the bucket is configured to use an Amazon S3 managed key to * encrypt new objects.

*/ inline const Aws::String& GetKmsMasterKeyId() const{ return m_kmsMasterKeyId; } /** *

The Amazon Resource Name (ARN) or unique identifier (key ID) for the KMS key * that's used by default to encrypt objects that are added to the bucket. This * value is null if the bucket is configured to use an Amazon S3 managed key to * encrypt new objects.

*/ inline bool KmsMasterKeyIdHasBeenSet() const { return m_kmsMasterKeyIdHasBeenSet; } /** *

The Amazon Resource Name (ARN) or unique identifier (key ID) for the KMS key * that's used by default to encrypt objects that are added to the bucket. This * value is null if the bucket is configured to use an Amazon S3 managed key to * encrypt new objects.

*/ inline void SetKmsMasterKeyId(const Aws::String& value) { m_kmsMasterKeyIdHasBeenSet = true; m_kmsMasterKeyId = value; } /** *

The Amazon Resource Name (ARN) or unique identifier (key ID) for the KMS key * that's used by default to encrypt objects that are added to the bucket. This * value is null if the bucket is configured to use an Amazon S3 managed key to * encrypt new objects.

*/ inline void SetKmsMasterKeyId(Aws::String&& value) { m_kmsMasterKeyIdHasBeenSet = true; m_kmsMasterKeyId = std::move(value); } /** *

The Amazon Resource Name (ARN) or unique identifier (key ID) for the KMS key * that's used by default to encrypt objects that are added to the bucket. This * value is null if the bucket is configured to use an Amazon S3 managed key to * encrypt new objects.

*/ inline void SetKmsMasterKeyId(const char* value) { m_kmsMasterKeyIdHasBeenSet = true; m_kmsMasterKeyId.assign(value); } /** *

The Amazon Resource Name (ARN) or unique identifier (key ID) for the KMS key * that's used by default to encrypt objects that are added to the bucket. This * value is null if the bucket is configured to use an Amazon S3 managed key to * encrypt new objects.

*/ inline BucketServerSideEncryption& WithKmsMasterKeyId(const Aws::String& value) { SetKmsMasterKeyId(value); return *this;} /** *

The Amazon Resource Name (ARN) or unique identifier (key ID) for the KMS key * that's used by default to encrypt objects that are added to the bucket. This * value is null if the bucket is configured to use an Amazon S3 managed key to * encrypt new objects.

*/ inline BucketServerSideEncryption& WithKmsMasterKeyId(Aws::String&& value) { SetKmsMasterKeyId(std::move(value)); return *this;} /** *

The Amazon Resource Name (ARN) or unique identifier (key ID) for the KMS key * that's used by default to encrypt objects that are added to the bucket. This * value is null if the bucket is configured to use an Amazon S3 managed key to * encrypt new objects.

*/ inline BucketServerSideEncryption& WithKmsMasterKeyId(const char* value) { SetKmsMasterKeyId(value); return *this;} /** *

The server-side encryption algorithm that's used by default to encrypt * objects that are added to the bucket. Possible values are:

  • AES256 * - New objects are encrypted with an Amazon S3 managed key. They use SSE-S3 * encryption.

  • aws:kms - New objects are encrypted with an KMS key * (kmsMasterKeyId), either an Amazon Web Services managed key or a customer * managed key. They use SSE-KMS encryption.

  • NONE - The bucket's * default encryption settings don't specify server-side encryption behavior for * new objects.

*/ inline const Type& GetType() const{ return m_type; } /** *

The server-side encryption algorithm that's used by default to encrypt * objects that are added to the bucket. Possible values are:

  • AES256 * - New objects are encrypted with an Amazon S3 managed key. They use SSE-S3 * encryption.

  • aws:kms - New objects are encrypted with an KMS key * (kmsMasterKeyId), either an Amazon Web Services managed key or a customer * managed key. They use SSE-KMS encryption.

  • NONE - The bucket's * default encryption settings don't specify server-side encryption behavior for * new objects.

*/ inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; } /** *

The server-side encryption algorithm that's used by default to encrypt * objects that are added to the bucket. Possible values are:

  • AES256 * - New objects are encrypted with an Amazon S3 managed key. They use SSE-S3 * encryption.

  • aws:kms - New objects are encrypted with an KMS key * (kmsMasterKeyId), either an Amazon Web Services managed key or a customer * managed key. They use SSE-KMS encryption.

  • NONE - The bucket's * default encryption settings don't specify server-side encryption behavior for * new objects.

*/ inline void SetType(const Type& value) { m_typeHasBeenSet = true; m_type = value; } /** *

The server-side encryption algorithm that's used by default to encrypt * objects that are added to the bucket. Possible values are:

  • AES256 * - New objects are encrypted with an Amazon S3 managed key. They use SSE-S3 * encryption.

  • aws:kms - New objects are encrypted with an KMS key * (kmsMasterKeyId), either an Amazon Web Services managed key or a customer * managed key. They use SSE-KMS encryption.

  • NONE - The bucket's * default encryption settings don't specify server-side encryption behavior for * new objects.

*/ inline void SetType(Type&& value) { m_typeHasBeenSet = true; m_type = std::move(value); } /** *

The server-side encryption algorithm that's used by default to encrypt * objects that are added to the bucket. Possible values are:

  • AES256 * - New objects are encrypted with an Amazon S3 managed key. They use SSE-S3 * encryption.

  • aws:kms - New objects are encrypted with an KMS key * (kmsMasterKeyId), either an Amazon Web Services managed key or a customer * managed key. They use SSE-KMS encryption.

  • NONE - The bucket's * default encryption settings don't specify server-side encryption behavior for * new objects.

*/ inline BucketServerSideEncryption& WithType(const Type& value) { SetType(value); return *this;} /** *

The server-side encryption algorithm that's used by default to encrypt * objects that are added to the bucket. Possible values are:

  • AES256 * - New objects are encrypted with an Amazon S3 managed key. They use SSE-S3 * encryption.

  • aws:kms - New objects are encrypted with an KMS key * (kmsMasterKeyId), either an Amazon Web Services managed key or a customer * managed key. They use SSE-KMS encryption.

  • NONE - The bucket's * default encryption settings don't specify server-side encryption behavior for * new objects.

*/ inline BucketServerSideEncryption& WithType(Type&& value) { SetType(std::move(value)); return *this;} private: Aws::String m_kmsMasterKeyId; bool m_kmsMasterKeyIdHasBeenSet = false; Type m_type; bool m_typeHasBeenSet = false; }; } // namespace Model } // namespace Macie2 } // namespace Aws