/** * 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 { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace IoT { namespace Model { /** *

Describes a custom method used to code sign a file.

See Also:

* AWS * API Reference

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

The signature for the file.

*/ inline const CodeSigningSignature& GetSignature() const{ return m_signature; } /** *

The signature for the file.

*/ inline bool SignatureHasBeenSet() const { return m_signatureHasBeenSet; } /** *

The signature for the file.

*/ inline void SetSignature(const CodeSigningSignature& value) { m_signatureHasBeenSet = true; m_signature = value; } /** *

The signature for the file.

*/ inline void SetSignature(CodeSigningSignature&& value) { m_signatureHasBeenSet = true; m_signature = std::move(value); } /** *

The signature for the file.

*/ inline CustomCodeSigning& WithSignature(const CodeSigningSignature& value) { SetSignature(value); return *this;} /** *

The signature for the file.

*/ inline CustomCodeSigning& WithSignature(CodeSigningSignature&& value) { SetSignature(std::move(value)); return *this;} /** *

The certificate chain.

*/ inline const CodeSigningCertificateChain& GetCertificateChain() const{ return m_certificateChain; } /** *

The certificate chain.

*/ inline bool CertificateChainHasBeenSet() const { return m_certificateChainHasBeenSet; } /** *

The certificate chain.

*/ inline void SetCertificateChain(const CodeSigningCertificateChain& value) { m_certificateChainHasBeenSet = true; m_certificateChain = value; } /** *

The certificate chain.

*/ inline void SetCertificateChain(CodeSigningCertificateChain&& value) { m_certificateChainHasBeenSet = true; m_certificateChain = std::move(value); } /** *

The certificate chain.

*/ inline CustomCodeSigning& WithCertificateChain(const CodeSigningCertificateChain& value) { SetCertificateChain(value); return *this;} /** *

The certificate chain.

*/ inline CustomCodeSigning& WithCertificateChain(CodeSigningCertificateChain&& value) { SetCertificateChain(std::move(value)); return *this;} /** *

The hash algorithm used to code sign the file. You can use a string as the * algorithm name if the target over-the-air (OTA) update devices are able to * verify the signature that was generated using the same signature algorithm. For * example, FreeRTOS uses SHA256 or SHA1, so you can pass * either of them based on which was used for generating the signature.

*/ inline const Aws::String& GetHashAlgorithm() const{ return m_hashAlgorithm; } /** *

The hash algorithm used to code sign the file. You can use a string as the * algorithm name if the target over-the-air (OTA) update devices are able to * verify the signature that was generated using the same signature algorithm. For * example, FreeRTOS uses SHA256 or SHA1, so you can pass * either of them based on which was used for generating the signature.

*/ inline bool HashAlgorithmHasBeenSet() const { return m_hashAlgorithmHasBeenSet; } /** *

The hash algorithm used to code sign the file. You can use a string as the * algorithm name if the target over-the-air (OTA) update devices are able to * verify the signature that was generated using the same signature algorithm. For * example, FreeRTOS uses SHA256 or SHA1, so you can pass * either of them based on which was used for generating the signature.

*/ inline void SetHashAlgorithm(const Aws::String& value) { m_hashAlgorithmHasBeenSet = true; m_hashAlgorithm = value; } /** *

The hash algorithm used to code sign the file. You can use a string as the * algorithm name if the target over-the-air (OTA) update devices are able to * verify the signature that was generated using the same signature algorithm. For * example, FreeRTOS uses SHA256 or SHA1, so you can pass * either of them based on which was used for generating the signature.

*/ inline void SetHashAlgorithm(Aws::String&& value) { m_hashAlgorithmHasBeenSet = true; m_hashAlgorithm = std::move(value); } /** *

The hash algorithm used to code sign the file. You can use a string as the * algorithm name if the target over-the-air (OTA) update devices are able to * verify the signature that was generated using the same signature algorithm. For * example, FreeRTOS uses SHA256 or SHA1, so you can pass * either of them based on which was used for generating the signature.

*/ inline void SetHashAlgorithm(const char* value) { m_hashAlgorithmHasBeenSet = true; m_hashAlgorithm.assign(value); } /** *

The hash algorithm used to code sign the file. You can use a string as the * algorithm name if the target over-the-air (OTA) update devices are able to * verify the signature that was generated using the same signature algorithm. For * example, FreeRTOS uses SHA256 or SHA1, so you can pass * either of them based on which was used for generating the signature.

*/ inline CustomCodeSigning& WithHashAlgorithm(const Aws::String& value) { SetHashAlgorithm(value); return *this;} /** *

The hash algorithm used to code sign the file. You can use a string as the * algorithm name if the target over-the-air (OTA) update devices are able to * verify the signature that was generated using the same signature algorithm. For * example, FreeRTOS uses SHA256 or SHA1, so you can pass * either of them based on which was used for generating the signature.

*/ inline CustomCodeSigning& WithHashAlgorithm(Aws::String&& value) { SetHashAlgorithm(std::move(value)); return *this;} /** *

The hash algorithm used to code sign the file. You can use a string as the * algorithm name if the target over-the-air (OTA) update devices are able to * verify the signature that was generated using the same signature algorithm. For * example, FreeRTOS uses SHA256 or SHA1, so you can pass * either of them based on which was used for generating the signature.

*/ inline CustomCodeSigning& WithHashAlgorithm(const char* value) { SetHashAlgorithm(value); return *this;} /** *

The signature algorithm used to code sign the file. You can use a string as * the algorithm name if the target over-the-air (OTA) update devices are able to * verify the signature that was generated using the same signature algorithm. For * example, FreeRTOS uses ECDSA or RSA, so you can pass * either of them based on which was used for generating the signature.

*/ inline const Aws::String& GetSignatureAlgorithm() const{ return m_signatureAlgorithm; } /** *

The signature algorithm used to code sign the file. You can use a string as * the algorithm name if the target over-the-air (OTA) update devices are able to * verify the signature that was generated using the same signature algorithm. For * example, FreeRTOS uses ECDSA or RSA, so you can pass * either of them based on which was used for generating the signature.

*/ inline bool SignatureAlgorithmHasBeenSet() const { return m_signatureAlgorithmHasBeenSet; } /** *

The signature algorithm used to code sign the file. You can use a string as * the algorithm name if the target over-the-air (OTA) update devices are able to * verify the signature that was generated using the same signature algorithm. For * example, FreeRTOS uses ECDSA or RSA, so you can pass * either of them based on which was used for generating the signature.

*/ inline void SetSignatureAlgorithm(const Aws::String& value) { m_signatureAlgorithmHasBeenSet = true; m_signatureAlgorithm = value; } /** *

The signature algorithm used to code sign the file. You can use a string as * the algorithm name if the target over-the-air (OTA) update devices are able to * verify the signature that was generated using the same signature algorithm. For * example, FreeRTOS uses ECDSA or RSA, so you can pass * either of them based on which was used for generating the signature.

*/ inline void SetSignatureAlgorithm(Aws::String&& value) { m_signatureAlgorithmHasBeenSet = true; m_signatureAlgorithm = std::move(value); } /** *

The signature algorithm used to code sign the file. You can use a string as * the algorithm name if the target over-the-air (OTA) update devices are able to * verify the signature that was generated using the same signature algorithm. For * example, FreeRTOS uses ECDSA or RSA, so you can pass * either of them based on which was used for generating the signature.

*/ inline void SetSignatureAlgorithm(const char* value) { m_signatureAlgorithmHasBeenSet = true; m_signatureAlgorithm.assign(value); } /** *

The signature algorithm used to code sign the file. You can use a string as * the algorithm name if the target over-the-air (OTA) update devices are able to * verify the signature that was generated using the same signature algorithm. For * example, FreeRTOS uses ECDSA or RSA, so you can pass * either of them based on which was used for generating the signature.

*/ inline CustomCodeSigning& WithSignatureAlgorithm(const Aws::String& value) { SetSignatureAlgorithm(value); return *this;} /** *

The signature algorithm used to code sign the file. You can use a string as * the algorithm name if the target over-the-air (OTA) update devices are able to * verify the signature that was generated using the same signature algorithm. For * example, FreeRTOS uses ECDSA or RSA, so you can pass * either of them based on which was used for generating the signature.

*/ inline CustomCodeSigning& WithSignatureAlgorithm(Aws::String&& value) { SetSignatureAlgorithm(std::move(value)); return *this;} /** *

The signature algorithm used to code sign the file. You can use a string as * the algorithm name if the target over-the-air (OTA) update devices are able to * verify the signature that was generated using the same signature algorithm. For * example, FreeRTOS uses ECDSA or RSA, so you can pass * either of them based on which was used for generating the signature.

*/ inline CustomCodeSigning& WithSignatureAlgorithm(const char* value) { SetSignatureAlgorithm(value); return *this;} private: CodeSigningSignature m_signature; bool m_signatureHasBeenSet = false; CodeSigningCertificateChain m_certificateChain; bool m_certificateChainHasBeenSet = false; Aws::String m_hashAlgorithm; bool m_hashAlgorithmHasBeenSet = false; Aws::String m_signatureAlgorithm; bool m_signatureAlgorithmHasBeenSet = false; }; } // namespace Model } // namespace IoT } // namespace Aws