/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include namespace Aws { template class AmazonWebServiceResult; namespace Utils { namespace Json { class JsonValue; } // namespace Json } // namespace Utils namespace KMS { namespace Model { class SignResult { public: AWS_KMS_API SignResult(); AWS_KMS_API SignResult(const Aws::AmazonWebServiceResult& result); AWS_KMS_API SignResult& operator=(const Aws::AmazonWebServiceResult& result); /** *

The Amazon Resource Name (key * ARN) of the asymmetric KMS key that was used to sign the message.

*/ inline const Aws::String& GetKeyId() const{ return m_keyId; } /** *

The Amazon Resource Name (key * ARN) of the asymmetric KMS key that was used to sign the message.

*/ inline void SetKeyId(const Aws::String& value) { m_keyId = value; } /** *

The Amazon Resource Name (key * ARN) of the asymmetric KMS key that was used to sign the message.

*/ inline void SetKeyId(Aws::String&& value) { m_keyId = std::move(value); } /** *

The Amazon Resource Name (key * ARN) of the asymmetric KMS key that was used to sign the message.

*/ inline void SetKeyId(const char* value) { m_keyId.assign(value); } /** *

The Amazon Resource Name (key * ARN) of the asymmetric KMS key that was used to sign the message.

*/ inline SignResult& WithKeyId(const Aws::String& value) { SetKeyId(value); return *this;} /** *

The Amazon Resource Name (key * ARN) of the asymmetric KMS key that was used to sign the message.

*/ inline SignResult& WithKeyId(Aws::String&& value) { SetKeyId(std::move(value)); return *this;} /** *

The Amazon Resource Name (key * ARN) of the asymmetric KMS key that was used to sign the message.

*/ inline SignResult& WithKeyId(const char* value) { SetKeyId(value); return *this;} /** *

The cryptographic signature that was generated for the message.

    *
  • When used with the supported RSA signing algorithms, the encoding of * this value is defined by PKCS #1 * in RFC 8017.

  • When used with the * ECDSA_SHA_256, ECDSA_SHA_384, or * ECDSA_SHA_512 signing algorithms, this value is a DER-encoded * object as defined by ANSI X9.62–2005 and RFC 3279 Section * 2.2.3. This is the most commonly used signature format and is appropriate * for most uses.

When you use the HTTP API or the Amazon Web * Services CLI, the value is Base64-encoded. Otherwise, it is not * Base64-encoded.

*/ inline const Aws::Utils::ByteBuffer& GetSignature() const{ return m_signature; } /** *

The cryptographic signature that was generated for the message.

    *
  • When used with the supported RSA signing algorithms, the encoding of * this value is defined by PKCS #1 * in RFC 8017.

  • When used with the * ECDSA_SHA_256, ECDSA_SHA_384, or * ECDSA_SHA_512 signing algorithms, this value is a DER-encoded * object as defined by ANSI X9.62–2005 and RFC 3279 Section * 2.2.3. This is the most commonly used signature format and is appropriate * for most uses.

When you use the HTTP API or the Amazon Web * Services CLI, the value is Base64-encoded. Otherwise, it is not * Base64-encoded.

*/ inline void SetSignature(const Aws::Utils::ByteBuffer& value) { m_signature = value; } /** *

The cryptographic signature that was generated for the message.

    *
  • When used with the supported RSA signing algorithms, the encoding of * this value is defined by PKCS #1 * in RFC 8017.

  • When used with the * ECDSA_SHA_256, ECDSA_SHA_384, or * ECDSA_SHA_512 signing algorithms, this value is a DER-encoded * object as defined by ANSI X9.62–2005 and RFC 3279 Section * 2.2.3. This is the most commonly used signature format and is appropriate * for most uses.

When you use the HTTP API or the Amazon Web * Services CLI, the value is Base64-encoded. Otherwise, it is not * Base64-encoded.

*/ inline void SetSignature(Aws::Utils::ByteBuffer&& value) { m_signature = std::move(value); } /** *

The cryptographic signature that was generated for the message.

    *
  • When used with the supported RSA signing algorithms, the encoding of * this value is defined by PKCS #1 * in RFC 8017.

  • When used with the * ECDSA_SHA_256, ECDSA_SHA_384, or * ECDSA_SHA_512 signing algorithms, this value is a DER-encoded * object as defined by ANSI X9.62–2005 and RFC 3279 Section * 2.2.3. This is the most commonly used signature format and is appropriate * for most uses.

When you use the HTTP API or the Amazon Web * Services CLI, the value is Base64-encoded. Otherwise, it is not * Base64-encoded.

*/ inline SignResult& WithSignature(const Aws::Utils::ByteBuffer& value) { SetSignature(value); return *this;} /** *

The cryptographic signature that was generated for the message.

    *
  • When used with the supported RSA signing algorithms, the encoding of * this value is defined by PKCS #1 * in RFC 8017.

  • When used with the * ECDSA_SHA_256, ECDSA_SHA_384, or * ECDSA_SHA_512 signing algorithms, this value is a DER-encoded * object as defined by ANSI X9.62–2005 and RFC 3279 Section * 2.2.3. This is the most commonly used signature format and is appropriate * for most uses.

When you use the HTTP API or the Amazon Web * Services CLI, the value is Base64-encoded. Otherwise, it is not * Base64-encoded.

*/ inline SignResult& WithSignature(Aws::Utils::ByteBuffer&& value) { SetSignature(std::move(value)); return *this;} /** *

The signing algorithm that was used to sign the message.

*/ inline const SigningAlgorithmSpec& GetSigningAlgorithm() const{ return m_signingAlgorithm; } /** *

The signing algorithm that was used to sign the message.

*/ inline void SetSigningAlgorithm(const SigningAlgorithmSpec& value) { m_signingAlgorithm = value; } /** *

The signing algorithm that was used to sign the message.

*/ inline void SetSigningAlgorithm(SigningAlgorithmSpec&& value) { m_signingAlgorithm = std::move(value); } /** *

The signing algorithm that was used to sign the message.

*/ inline SignResult& WithSigningAlgorithm(const SigningAlgorithmSpec& value) { SetSigningAlgorithm(value); return *this;} /** *

The signing algorithm that was used to sign the message.

*/ inline SignResult& WithSigningAlgorithm(SigningAlgorithmSpec&& value) { SetSigningAlgorithm(std::move(value)); return *this;} inline const Aws::String& GetRequestId() const{ return m_requestId; } inline void SetRequestId(const Aws::String& value) { m_requestId = value; } inline void SetRequestId(Aws::String&& value) { m_requestId = std::move(value); } inline void SetRequestId(const char* value) { m_requestId.assign(value); } inline SignResult& WithRequestId(const Aws::String& value) { SetRequestId(value); return *this;} inline SignResult& WithRequestId(Aws::String&& value) { SetRequestId(std::move(value)); return *this;} inline SignResult& WithRequestId(const char* value) { SetRequestId(value); return *this;} private: Aws::String m_keyId; Aws::Utils::ByteBuffer m_signature; SigningAlgorithmSpec m_signingAlgorithm; Aws::String m_requestId; }; } // namespace Model } // namespace KMS } // namespace Aws