/AWS1/IF_ACP=>CREATECERTIFICATEAUTHORITY()¶
About CreateCertificateAuthority¶
Creates a root or subordinate private certificate authority (CA). You must specify the CA configuration, an optional configuration for Online Certificate Status Protocol (OCSP) and/or a certificate revocation list (CRL), the CA type, and an optional idempotency token to avoid accidental creation of multiple CAs. The CA configuration specifies the name of the algorithm and key size to be used to create the CA private key, the type of signing algorithm that the CA uses, and X.500 subject information. The OCSP configuration can optionally specify a custom URL for the OCSP responder. The CRL configuration specifies the CRL expiration period in days (the validity period of the CRL), the Amazon S3 bucket that will contain the CRL, and a CNAME alias for the S3 bucket that is included in certificates issued by the CA. If successful, this action returns the Amazon Resource Name (ARN) of the CA.
Both Amazon Web Services Private CA and the IAM principal must have permission to write to the S3 bucket that you specify. If the IAM principal making the call does not have permission to write to the bucket, then an exception is thrown. For more information, see Access policies for CRLs in Amazon S3.
Amazon Web Services Private CA assets that are stored in Amazon S3 can be protected with encryption. For more information, see Encrypting Your CRLs.
Method Signature¶
METHODS /AWS1/IF_ACP~CREATECERTIFICATEAUTHORITY
IMPORTING
!IO_CERTIFICATEAUTHORITYCONF TYPE REF TO /AWS1/CL_ACPCERTAUTHORITYCONF OPTIONAL
!IO_REVOCATIONCONFIGURATION TYPE REF TO /AWS1/CL_ACPREVOCATIONCONF OPTIONAL
!IV_CERTIFICATEAUTHORITYTYPE TYPE /AWS1/ACPCERTAUTHORITYTYPE OPTIONAL
!IV_IDEMPOTENCYTOKEN TYPE /AWS1/ACPIDEMPOTENCYTOKEN OPTIONAL
!IV_KEYSTORAGESECSTANDARD TYPE /AWS1/ACPKEYSTORAGESECSTANDARD OPTIONAL
!IT_TAGS TYPE /AWS1/CL_ACPTAG=>TT_TAGLIST OPTIONAL
!IV_USAGEMODE TYPE /AWS1/ACPCERTAUTHORITYUSAGEMDE OPTIONAL
RETURNING
VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_acpcrecrtauthorityrsp
RAISING
/AWS1/CX_ACPINVALIDARGSEX
/AWS1/CX_ACPINVALIDPOLICYEX
/AWS1/CX_ACPINVALIDTAGEX
/AWS1/CX_ACPLIMITEXCEEDEDEX
/AWS1/CX_ACPCLIENTEXC
/AWS1/CX_ACPSERVEREXC
/AWS1/CX_RT_TECHNICAL_GENERIC
/AWS1/CX_RT_SERVICE_GENERIC.
IMPORTING¶
Required arguments:¶
io_certificateauthorityconf TYPE REF TO /AWS1/CL_ACPCERTAUTHORITYCONF /AWS1/CL_ACPCERTAUTHORITYCONF¶
Name and bit size of the private key algorithm, the name of the signing algorithm, and X.500 certificate subject information.
iv_certificateauthoritytype TYPE /AWS1/ACPCERTAUTHORITYTYPE /AWS1/ACPCERTAUTHORITYTYPE¶
The type of the certificate authority.
Optional arguments:¶
io_revocationconfiguration TYPE REF TO /AWS1/CL_ACPREVOCATIONCONF /AWS1/CL_ACPREVOCATIONCONF¶
Contains information to enable support for Online Certificate Status Protocol (OCSP), certificate revocation list (CRL), both protocols, or neither. By default, both certificate validation mechanisms are disabled.
The following requirements apply to revocation configurations.
A configuration disabling CRLs or OCSP must contain only the
Enabled=Falseparameter, and will fail if other parameters such asCustomCnameorExpirationInDaysare included.In a CRL configuration, the
S3BucketNameparameter must conform to Amazon S3 bucket naming rules.A configuration containing a custom Canonical Name (CNAME) parameter for CRLs or OCSP must conform to RFC2396 restrictions on the use of special characters in a CNAME.
In a CRL or OCSP configuration, the value of a CNAME parameter must not include a protocol prefix such as "http://" or "https://".
For more information, see the OcspConfiguration and CrlConfiguration types.
iv_idempotencytoken TYPE /AWS1/ACPIDEMPOTENCYTOKEN /AWS1/ACPIDEMPOTENCYTOKEN¶
Custom string that can be used to distinguish between calls to the CreateCertificateAuthority action. Idempotency tokens for CreateCertificateAuthority time out after five minutes. Therefore, if you call CreateCertificateAuthority multiple times with the same idempotency token within five minutes, Amazon Web Services Private CA recognizes that you are requesting only certificate authority and will issue only one. If you change the idempotency token for each call, Amazon Web Services Private CA recognizes that you are requesting multiple certificate authorities.
iv_keystoragesecstandard TYPE /AWS1/ACPKEYSTORAGESECSTANDARD /AWS1/ACPKEYSTORAGESECSTANDARD¶
Specifies a cryptographic key management compliance standard for handling and protecting CA keys.
Default: FIPS_140_2_LEVEL_3_OR_HIGHER
Some Amazon Web Services Regions don't support the default value. When you create a CA in these Regions, you must use
CCPC_LEVEL_1_OR_HIGHERfor theKeyStorageSecurityStandardparameter. If you don't, the operation returns anInvalidArgsExceptionwith this message: "A certificate authority cannot be created in this region with the specified security standard."For information about security standard support in different Amazon Web Services Regions, see Storage and security compliance of Amazon Web Services Private CA private keys.
it_tags TYPE /AWS1/CL_ACPTAG=>TT_TAGLIST TT_TAGLIST¶
Key-value pairs that will be attached to the new private CA. You can associate up to 50 tags with a private CA. For information using tags with IAM to manage permissions, see Controlling Access Using IAM Tags.
iv_usagemode TYPE /AWS1/ACPCERTAUTHORITYUSAGEMDE /AWS1/ACPCERTAUTHORITYUSAGEMDE¶
Specifies whether the CA issues general-purpose certificates that typically require a revocation mechanism, or short-lived certificates that may optionally omit revocation because they expire quickly. Short-lived certificate validity is limited to seven days.
The default value is GENERAL_PURPOSE.
RETURNING¶
oo_output TYPE REF TO /aws1/cl_acpcrecrtauthorityrsp /AWS1/CL_ACPCRECRTAUTHORITYRSP¶
Domain /AWS1/RT_ACCOUNT_ID Primitive Type NUMC
Examples¶
Syntax Example¶
This is an example of the syntax for calling the method. It includes every possible argument and initializes every possible value. The data provided is not necessarily semantically accurate (for example the value "string" may be provided for something that is intended to be an instance ID, or in some cases two arguments may be mutually exclusive). The syntax shows the ABAP syntax for creating the various data structures.
DATA(lo_result) = lo_client->createcertificateauthority(
io_certificateauthorityconf = new /aws1/cl_acpcertauthorityconf(
io_csrextensions = new /aws1/cl_acpcsrextensions(
io_keyusage = new /aws1/cl_acpkeyusage(
iv_crlsign = ABAP_TRUE
iv_dataencipherment = ABAP_TRUE
iv_decipheronly = ABAP_TRUE
iv_digitalsignature = ABAP_TRUE
iv_encipheronly = ABAP_TRUE
iv_keyagreement = ABAP_TRUE
iv_keycertsign = ABAP_TRUE
iv_keyencipherment = ABAP_TRUE
iv_nonrepudiation = ABAP_TRUE
)
it_subjectinformationaccess = VALUE /aws1/cl_acpaccessdescription=>tt_accessdescriptionlist(
(
new /aws1/cl_acpaccessdescription(
io_accesslocation = new /aws1/cl_acpgeneralname(
io_directoryname = new /aws1/cl_acpasn1subject(
it_customattributes = VALUE /aws1/cl_acpcustomattribute=>tt_customattributelist(
(
new /aws1/cl_acpcustomattribute(
iv_objectidentifier = |string|
iv_value = |string|
)
)
)
iv_commonname = |string|
iv_country = |string|
iv_distinguishednamequalif00 = |string|
iv_generationqualifier = |string|
iv_givenname = |string|
iv_initials = |string|
iv_locality = |string|
iv_organization = |string|
iv_organizationalunit = |string|
iv_pseudonym = |string|
iv_serialnumber = |string|
iv_state = |string|
iv_surname = |string|
iv_title = |string|
)
io_edipartyname = new /aws1/cl_acpedipartyname(
iv_nameassigner = |string|
iv_partyname = |string|
)
io_othername = new /aws1/cl_acpothername(
iv_typeid = |string|
iv_value = |string|
)
iv_dnsname = |string|
iv_ipaddress = |string|
iv_registeredid = |string|
iv_rfc822name = |string|
iv_uniformresourceidentifier = |string|
)
io_accessmethod = new /aws1/cl_acpaccessmethod(
iv_accessmethodtype = |string|
iv_customobjectidentifier = |string|
)
)
)
)
)
io_subject = new /aws1/cl_acpasn1subject(
it_customattributes = VALUE /aws1/cl_acpcustomattribute=>tt_customattributelist(
(
new /aws1/cl_acpcustomattribute(
iv_objectidentifier = |string|
iv_value = |string|
)
)
)
iv_commonname = |string|
iv_country = |string|
iv_distinguishednamequalif00 = |string|
iv_generationqualifier = |string|
iv_givenname = |string|
iv_initials = |string|
iv_locality = |string|
iv_organization = |string|
iv_organizationalunit = |string|
iv_pseudonym = |string|
iv_serialnumber = |string|
iv_state = |string|
iv_surname = |string|
iv_title = |string|
)
iv_keyalgorithm = |string|
iv_signingalgorithm = |string|
)
io_revocationconfiguration = new /aws1/cl_acprevocationconf(
io_crlconfiguration = new /aws1/cl_acpcrlconfiguration(
io_crldistributionptxtensi00 = new /aws1/cl_acpcrldistributionp00( ABAP_TRUE )
iv_crltype = |string|
iv_customcname = |string|
iv_custompath = |string|
iv_enabled = ABAP_TRUE
iv_expirationindays = 123
iv_s3bucketname = |string|
iv_s3objectacl = |string|
)
io_ocspconfiguration = new /aws1/cl_acpocspconfiguration(
iv_enabled = ABAP_TRUE
iv_ocspcustomcname = |string|
)
)
it_tags = VALUE /aws1/cl_acptag=>tt_taglist(
(
new /aws1/cl_acptag(
iv_key = |string|
iv_value = |string|
)
)
)
iv_certificateauthoritytype = |string|
iv_idempotencytoken = |string|
iv_keystoragesecstandard = |string|
iv_usagemode = |string|
).
This is an example of reading all possible response values
lo_result = lo_result.
IF lo_result IS NOT INITIAL.
lv_arn = lo_result->get_certificateauthorityarn( ).
ENDIF.