Class: AWSCDK::CertificateManager::CfnCertificateProps

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
certificate_manager/cfn_certificate_props.rb

Overview

Properties for defining a CfnCertificate.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(domain_name:, certificate_authority_arn: nil, certificate_export: nil, certificate_transparency_logging_preference: nil, domain_validation_options: nil, key_algorithm: nil, subject_alternative_names: nil, tags: nil, validation_method: nil) ⇒ CfnCertificateProps

Returns a new instance of CfnCertificateProps.

Parameters:

  • domain_name (String)

    The fully qualified domain name (FQDN), such as www.example.com, with which you want to secure an ACM certificate. Use an asterisk () to create a wildcard certificate that protects several sites in the same domain. For example, `.example.comprotectswww.example.com` , site.example.com , and images.example.com..

  • certificate_authority_arn (String, nil) (defaults to: nil)

    The Amazon Resource Name (ARN) of the private certificate authority (CA) that will be used to issue the certificate.

  • certificate_export (String, nil) (defaults to: nil)

    You can opt out of allowing export of your certificate by specifying the DISABLED option.

  • certificate_transparency_logging_preference (String, nil) (defaults to: nil)

    You can opt out of certificate transparency logging by specifying the DISABLED option.

  • domain_validation_options (AWSCDK::IResolvable, Array<AWSCDK::IResolvable, AWSCDK::CertificateManager::CfnCertificate::DomainValidationOptionProperty>, nil) (defaults to: nil)

    Domain information that domain name registrars use to verify your identity.

  • key_algorithm (String, nil) (defaults to: nil)

    Specifies the algorithm of the public and private key pair that your certificate uses to encrypt data.

  • subject_alternative_names (Array<String>, nil) (defaults to: nil)

    Additional FQDNs to be included in the Subject Alternative Name extension of the ACM certificate.

  • tags (Array<AWSCDK::CfnTag>, nil) (defaults to: nil)

    Key-value pairs that can identify the certificate.

  • validation_method (String, nil) (defaults to: nil)

    The method you want to use to validate that you own or control the domain associated with a public certificate.



18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# File 'certificate_manager/cfn_certificate_props.rb', line 18

def initialize(domain_name:, certificate_authority_arn: nil, certificate_export: nil, certificate_transparency_logging_preference: nil, domain_validation_options: nil, key_algorithm: nil, subject_alternative_names: nil, tags: nil, validation_method: nil)
  @domain_name = domain_name
  Jsii::Type.check_type(@domain_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "domainName")
  @certificate_authority_arn = certificate_authority_arn
  Jsii::Type.check_type(@certificate_authority_arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "certificateAuthorityArn") unless @certificate_authority_arn.nil?
  @certificate_export = certificate_export
  Jsii::Type.check_type(@certificate_export, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "certificateExport") unless @certificate_export.nil?
  @certificate_transparency_logging_preference = certificate_transparency_logging_preference
  Jsii::Type.check_type(@certificate_transparency_logging_preference, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "certificateTransparencyLoggingPreference") unless @certificate_transparency_logging_preference.nil?
  @domain_validation_options = domain_validation_options
  Jsii::Type.check_type(@domain_validation_options, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfY2VydGlmaWNhdGVtYW5hZ2VyLkNmbkNlcnRpZmljYXRlLkRvbWFpblZhbGlkYXRpb25PcHRpb25Qcm9wZXJ0eSJ9XX19LCJraW5kIjoiYXJyYXkifX1dfX0=")), "domainValidationOptions") unless @domain_validation_options.nil?
  @key_algorithm = key_algorithm
  Jsii::Type.check_type(@key_algorithm, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "keyAlgorithm") unless @key_algorithm.nil?
  @subject_alternative_names = subject_alternative_names
  Jsii::Type.check_type(@subject_alternative_names, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "subjectAlternativeNames") unless @subject_alternative_names.nil?
  @tags = tags.is_a?(Array) ? tags.map { |jsii_v0| jsii_v0.is_a?(Hash) ? ::AWSCDK::CfnTag.new(**jsii_v0.transform_keys(&:to_sym)) : jsii_v0 } : tags
  Jsii::Type.check_type(@tags, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLkNmblRhZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "tags") unless @tags.nil?
  @validation_method = validation_method
  Jsii::Type.check_type(@validation_method, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "validationMethod") unless @validation_method.nil?
end

Instance Attribute Details

#certificate_authority_arnString? (readonly)

The Amazon Resource Name (ARN) of the private certificate authority (CA) that will be used to issue the certificate.

If you do not provide an ARN and you are trying to request a private certificate, ACM will attempt to issue a public certificate. For more information about private CAs, see the AWS Private Certificate Authority user guide. The ARN must have the following form:

arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012



52
53
54
# File 'certificate_manager/cfn_certificate_props.rb', line 52

def certificate_authority_arn
  @certificate_authority_arn
end

#certificate_exportString? (readonly)

You can opt out of allowing export of your certificate by specifying the DISABLED option.

Allow export of your certificate by specifying the ENABLED option.

If you do not specify an export preference in a new CloudFormation template, it is the same as explicitly denying export of your certificate.



61
62
63
# File 'certificate_manager/cfn_certificate_props.rb', line 61

def certificate_export
  @certificate_export
end

#certificate_transparency_logging_preferenceString? (readonly)

You can opt out of certificate transparency logging by specifying the DISABLED option.

Opt in by specifying ENABLED . This setting doces not apply to private certificates.

If you do not specify a certificate transparency logging preference on a new CloudFormation template, or if you remove the logging preference from an existing template, this is the same as explicitly enabling the preference.

Changing the certificate transparency logging preference will update the existing resource by calling UpdateCertificateOptions on the certificate. This action will not create a new resource.



72
73
74
# File 'certificate_manager/cfn_certificate_props.rb', line 72

def certificate_transparency_logging_preference
  @certificate_transparency_logging_preference
end

#domain_nameString (readonly)

The fully qualified domain name (FQDN), such as www.example.com, with which you want to secure an ACM certificate. Use an asterisk () to create a wildcard certificate that protects several sites in the same domain. For example, `.example.comprotectswww.example.com` , site.example.com , and images.example.com..



43
44
45
# File 'certificate_manager/cfn_certificate_props.rb', line 43

def domain_name
  @domain_name
end

#domain_validation_optionsAWSCDK::IResolvable, ... (readonly)

Domain information that domain name registrars use to verify your identity.

In order for a AWS::CertificateManager::Certificate to be provisioned and validated in CloudFormation automatically, the DomainName property needs to be identical to one of the DomainName property supplied in DomainValidationOptions, if the ValidationMethod is DNS. Failing to keep them like-for-like will result in failure to create the domain validation records in Route53.



79
80
81
# File 'certificate_manager/cfn_certificate_props.rb', line 79

def domain_validation_options
  @domain_validation_options
end

#key_algorithmString? (readonly)

Specifies the algorithm of the public and private key pair that your certificate uses to encrypt data.

RSA is the default key algorithm for ACM certificates. Elliptic Curve Digital Signature Algorithm (ECDSA) keys are smaller, offering security comparable to RSA keys but with greater computing efficiency. However, ECDSA is not supported by all network clients. Some AWS services may require RSA keys, or only support ECDSA keys of a particular size, while others allow the use of either RSA and ECDSA keys to ensure that compatibility is not broken. Check the requirements for the AWS service where you plan to deploy your certificate. For more information about selecting an algorithm, see Key algorithms .

Algorithms supported for an ACM certificate request include:

  • RSA_2048
  • EC_prime256v1
  • EC_secp384r1

Other listed algorithms are for imported certificates only. > When you request a private PKI certificate signed by a CA from AWS Private CA, the specified signing algorithm family (RSA or ECDSA) must match the algorithm family of the CA's secret key.

Default: RSA_2048



96
97
98
# File 'certificate_manager/cfn_certificate_props.rb', line 96

def key_algorithm
  @key_algorithm
end

#subject_alternative_namesArray<String>? (readonly)

Additional FQDNs to be included in the Subject Alternative Name extension of the ACM certificate.

For example, you can add www.example.net to a certificate for which the DomainName field is www.example.com if users can reach your site by using either name.



103
104
105
# File 'certificate_manager/cfn_certificate_props.rb', line 103

def subject_alternative_names
  @subject_alternative_names
end

#tagsArray<AWSCDK::CfnTag>? (readonly)

Key-value pairs that can identify the certificate.



108
109
110
# File 'certificate_manager/cfn_certificate_props.rb', line 108

def tags
  @tags
end

#validation_methodString? (readonly)

The method you want to use to validate that you own or control the domain associated with a public certificate.

You can validate with DNS or validate with email . We recommend that you use DNS validation.

If not specified, this property defaults to email validation.



117
118
119
# File 'certificate_manager/cfn_certificate_props.rb', line 117

def validation_method
  @validation_method
end

Class Method Details

.jsii_propertiesObject



119
120
121
122
123
124
125
126
127
128
129
130
131
# File 'certificate_manager/cfn_certificate_props.rb', line 119

def self.jsii_properties
  {
    :domain_name => "domainName",
    :certificate_authority_arn => "certificateAuthorityArn",
    :certificate_export => "certificateExport",
    :certificate_transparency_logging_preference => "certificateTransparencyLoggingPreference",
    :domain_validation_options => "domainValidationOptions",
    :key_algorithm => "keyAlgorithm",
    :subject_alternative_names => "subjectAlternativeNames",
    :tags => "tags",
    :validation_method => "validationMethod",
  }
end

Instance Method Details

#to_jsiiObject



133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
# File 'certificate_manager/cfn_certificate_props.rb', line 133

def to_jsii
  result = {}
  result.merge!({
    "domainName" => @domain_name,
    "certificateAuthorityArn" => @certificate_authority_arn,
    "certificateExport" => @certificate_export,
    "certificateTransparencyLoggingPreference" => @certificate_transparency_logging_preference,
    "domainValidationOptions" => @domain_validation_options,
    "keyAlgorithm" => @key_algorithm,
    "subjectAlternativeNames" => @subject_alternative_names,
    "tags" => @tags,
    "validationMethod" => @validation_method,
  })
  result.compact
end