Home | History | Annotate | Line # | Download | only in man5
      1      1.1  christos =pod
      2      1.1  christos 
      3      1.1  christos =head1 NAME
      4      1.1  christos 
      5      1.1  christos x509v3_config - X509 V3 certificate extension configuration format
      6      1.1  christos 
      7      1.1  christos =head1 DESCRIPTION
      8      1.1  christos 
      9  1.1.1.4  christos Several OpenSSL commands can add extensions to a certificate or
     10  1.1.1.4  christos certificate request based on the contents of a configuration file
     11  1.1.1.4  christos and CLI options such as B<-addext>.
     12  1.1.1.4  christos The syntax of configuration files is described in L<config(5)>.
     13  1.1.1.4  christos The commands typically have an option to specify the name of the configuration
     14  1.1.1.4  christos file, and a section within that file; see the documentation of the
     15  1.1.1.4  christos individual command for details.
     16      1.1  christos 
     17  1.1.1.4  christos This page uses B<extensions> as the name of the section, when needed
     18  1.1.1.4  christos in examples.
     19      1.1  christos 
     20  1.1.1.4  christos Each entry in the extension section takes the form:
     21      1.1  christos 
     22  1.1.1.4  christos  name = [critical, ]value(s)
     23      1.1  christos 
     24  1.1.1.4  christos If B<critical> is present then the extension will be marked as critical.
     25      1.1  christos 
     26  1.1.1.4  christos If multiple entries are processed for the same extension name,
     27  1.1.1.4  christos later entries override earlier ones with the same name.
     28      1.1  christos 
     29  1.1.1.4  christos The format of B<values> depends on the value of B<name>, many have a
     30  1.1.1.4  christos type-value pairing where the type and value are separated by a colon.
     31  1.1.1.4  christos There are four main types of extension:
     32      1.1  christos 
     33  1.1.1.4  christos  string
     34  1.1.1.4  christos  multi-valued
     35  1.1.1.4  christos  raw
     36  1.1.1.4  christos  arbitrary
     37      1.1  christos 
     38  1.1.1.4  christos Each is described in the following paragraphs.
     39  1.1.1.4  christos 
     40  1.1.1.4  christos String extensions simply have a string which contains either the value itself
     41  1.1.1.4  christos or how it is obtained.
     42      1.1  christos 
     43      1.1  christos Multi-valued extensions have a short form and a long form. The short form
     44  1.1.1.4  christos is a comma-separated list of names and values:
     45      1.1  christos 
     46  1.1.1.4  christos  basicConstraints = critical, CA:true, pathlen:1
     47      1.1  christos 
     48      1.1  christos The long form allows the values to be placed in a separate section:
     49      1.1  christos 
     50  1.1.1.4  christos  [extensions]
     51  1.1.1.4  christos  basicConstraints = critical, @basic_constraints
     52      1.1  christos 
     53  1.1.1.4  christos  [basic_constraints]
     54  1.1.1.4  christos  CA = true
     55  1.1.1.4  christos  pathlen = 1
     56      1.1  christos 
     57      1.1  christos Both forms are equivalent.
     58      1.1  christos 
     59  1.1.1.4  christos If an extension is multi-value and a field value must contain a comma the long
     60  1.1.1.4  christos form must be used otherwise the comma would be misinterpreted as a field
     61  1.1.1.4  christos separator. For example:
     62      1.1  christos 
     63  1.1.1.4  christos  subjectAltName = URI:ldap://somehost.com/CN=foo,OU=bar
     64      1.1  christos 
     65  1.1.1.4  christos will produce an error but the equivalent form:
     66      1.1  christos 
     67  1.1.1.4  christos  [extensions]
     68  1.1.1.4  christos  subjectAltName = @subject_alt_section
     69      1.1  christos 
     70  1.1.1.4  christos  [subject_alt_section]
     71  1.1.1.4  christos  subjectAltName = URI:ldap://somehost.com/CN=foo,OU=bar
     72      1.1  christos 
     73  1.1.1.4  christos is valid.
     74      1.1  christos 
     75  1.1.1.4  christos OpenSSL does not support multiple occurrences of the same field within a
     76  1.1.1.4  christos section. In this example:
     77  1.1.1.4  christos 
     78  1.1.1.4  christos  [extensions]
     79  1.1.1.4  christos  subjectAltName = @alt_section
     80      1.1  christos 
     81  1.1.1.4  christos  [alt_section]
     82  1.1.1.4  christos  email = steve (a] example.com
     83  1.1.1.4  christos  email = steve (a] example.org
     84      1.1  christos 
     85  1.1.1.4  christos will only recognize the last value.  To specify multiple values append a
     86  1.1.1.4  christos numeric identifier, as shown here:
     87      1.1  christos 
     88  1.1.1.4  christos  [extensions]
     89  1.1.1.4  christos  subjectAltName = @alt_section
     90      1.1  christos 
     91  1.1.1.4  christos  [alt_section]
     92  1.1.1.4  christos  email.1 = steve (a] example.com
     93  1.1.1.4  christos  email.2 = steve (a] example.org
     94      1.1  christos 
     95  1.1.1.4  christos The syntax of raw extensions is defined by the source code that parses
     96  1.1.1.5  christos the extension but should be documented.
     97  1.1.1.4  christos See L</Certificate Policies> for an example of a raw extension.
     98      1.1  christos 
     99  1.1.1.4  christos If an extension type is unsupported, then the I<arbitrary> extension syntax
    100  1.1.1.4  christos must be used, see the L</ARBITRARY EXTENSIONS> section for more details.
    101      1.1  christos 
    102  1.1.1.4  christos =head1 STANDARD EXTENSIONS
    103      1.1  christos 
    104  1.1.1.4  christos The following sections describe the syntax of each supported extension.
    105  1.1.1.4  christos They do not define the semantics of the extension.
    106      1.1  christos 
    107  1.1.1.4  christos =head2 Basic Constraints
    108      1.1  christos 
    109  1.1.1.4  christos This is a multi-valued extension which indicates whether a certificate is
    110  1.1.1.4  christos a CA certificate. The first value is B<CA> followed by B<TRUE> or
    111  1.1.1.4  christos B<FALSE>. If B<CA> is B<TRUE> then an optional B<pathlen> name followed by a
    112  1.1.1.4  christos nonnegative value can be included.
    113      1.1  christos 
    114  1.1.1.4  christos For example:
    115      1.1  christos 
    116  1.1.1.4  christos  basicConstraints = CA:TRUE
    117      1.1  christos 
    118  1.1.1.4  christos  basicConstraints = CA:FALSE
    119      1.1  christos 
    120  1.1.1.4  christos  basicConstraints = critical, CA:TRUE, pathlen:1
    121      1.1  christos 
    122  1.1.1.4  christos A CA certificate I<must> include the B<basicConstraints> name with the B<CA>
    123  1.1.1.4  christos parameter set to B<TRUE>. An end-user certificate must either have B<CA:FALSE>
    124  1.1.1.4  christos or omit the extension entirely.
    125  1.1.1.4  christos The B<pathlen> parameter specifies the maximum number of CAs that can appear
    126  1.1.1.4  christos below this one in a chain. A B<pathlen> of zero means the CA cannot sign
    127  1.1.1.4  christos any sub-CA's, and can only sign end-entity certificates.
    128      1.1  christos 
    129  1.1.1.4  christos =head2 Key Usage
    130      1.1  christos 
    131  1.1.1.4  christos Key usage is a multi-valued extension consisting of a list of names of
    132  1.1.1.4  christos the permitted key usages.  The defined values are: C<digitalSignature>,
    133  1.1.1.4  christos C<nonRepudiation>, C<keyEncipherment>, C<dataEncipherment>, C<keyAgreement>,
    134  1.1.1.4  christos C<keyCertSign>, C<cRLSign>, C<encipherOnly>, and C<decipherOnly>.
    135  1.1.1.4  christos 
    136  1.1.1.4  christos Examples:
    137  1.1.1.4  christos 
    138  1.1.1.4  christos  keyUsage = digitalSignature, nonRepudiation
    139  1.1.1.4  christos 
    140  1.1.1.4  christos  keyUsage = critical, keyCertSign
    141  1.1.1.4  christos 
    142  1.1.1.4  christos =head2 Extended Key Usage
    143  1.1.1.4  christos 
    144  1.1.1.4  christos This extension consists of a list of values indicating purposes for which
    145  1.1.1.4  christos the certificate public key can be used.
    146  1.1.1.4  christos Each value can be either a short text name or an OID.
    147  1.1.1.4  christos The following text names, and their intended meaning, are known:
    148  1.1.1.4  christos 
    149  1.1.1.4  christos  Value                  Meaning according to RFC 5280 etc.
    150  1.1.1.4  christos  -----                  ----------------------------------
    151  1.1.1.4  christos  serverAuth             SSL/TLS WWW Server Authentication
    152  1.1.1.4  christos  clientAuth             SSL/TLS WWW Client Authentication
    153  1.1.1.4  christos  codeSigning            Code Signing
    154  1.1.1.4  christos  emailProtection        E-mail Protection (S/MIME)
    155      1.1  christos  timeStamping           Trusted Timestamping
    156      1.1  christos  OCSPSigning            OCSP Signing
    157      1.1  christos  ipsecIKE               ipsec Internet Key Exchange
    158      1.1  christos  msCodeInd              Microsoft Individual Code Signing (authenticode)
    159      1.1  christos  msCodeCom              Microsoft Commercial Code Signing (authenticode)
    160      1.1  christos  msCTLSign              Microsoft Trust List Signing
    161      1.1  christos  msEFS                  Microsoft Encrypted File System
    162      1.1  christos 
    163  1.1.1.4  christos While IETF RFC 5280 says that B<id-kp-serverAuth> and B<id-kp-clientAuth>
    164  1.1.1.4  christos are only for WWW use, in practice they are used for all kinds of TLS clients
    165  1.1.1.4  christos and servers, and this is what OpenSSL assumes as well.
    166  1.1.1.4  christos 
    167      1.1  christos Examples:
    168      1.1  christos 
    169  1.1.1.4  christos  extendedKeyUsage = critical, codeSigning, 1.2.3.4
    170      1.1  christos 
    171  1.1.1.4  christos  extendedKeyUsage = serverAuth, clientAuth
    172      1.1  christos 
    173  1.1.1.4  christos =head2 Subject Key Identifier
    174      1.1  christos 
    175  1.1.1.4  christos The SKID extension specification has a value with three choices.
    176  1.1.1.4  christos If the value is the word B<none> then no SKID extension will be included.
    177  1.1.1.4  christos If the value is the word B<hash>, or by default for the B<x509>, B<req>, and
    178  1.1.1.4  christos B<ca> apps, the process specified in RFC 5280 section 4.2.1.2. (1) is followed:
    179  1.1.1.4  christos The keyIdentifier is composed of the 160-bit SHA-1 hash of the value of the BIT
    180  1.1.1.4  christos STRING subjectPublicKey (excluding the tag, length, and number of unused bits).
    181      1.1  christos 
    182  1.1.1.4  christos Otherwise, the value must be a hex string (possibly with C<:> separating bytes)
    183  1.1.1.4  christos to output directly, however, this is strongly discouraged.
    184      1.1  christos 
    185  1.1.1.4  christos Example:
    186      1.1  christos 
    187  1.1.1.4  christos  subjectKeyIdentifier = hash
    188      1.1  christos 
    189  1.1.1.4  christos =head2 Authority Key Identifier
    190      1.1  christos 
    191  1.1.1.4  christos The AKID extension specification may have the value B<none>
    192  1.1.1.4  christos indicating that no AKID shall be included.
    193  1.1.1.4  christos Otherwise it may have the value B<keyid> or B<issuer>
    194  1.1.1.4  christos or both of them, separated by C<,>.
    195  1.1.1.4  christos Either or both can have the option B<always>,
    196  1.1.1.4  christos indicated by putting a colon C<:> between the value and this option.
    197  1.1.1.4  christos For self-signed certificates the AKID is suppressed unless B<always> is present.
    198  1.1.1.4  christos By default the B<x509>, B<req>, and B<ca> apps behave as if
    199  1.1.1.4  christos "none" was given for self-signed certificates and "keyid, issuer" otherwise.
    200      1.1  christos 
    201  1.1.1.4  christos If B<keyid> is present, an attempt is made to
    202  1.1.1.4  christos copy the subject key identifier (SKID) from the issuer certificate except if
    203  1.1.1.4  christos the issuer certificate is the same as the current one and it is not self-signed.
    204  1.1.1.4  christos The hash of the public key related to the signing key is taken as fallback
    205  1.1.1.4  christos if the issuer certificate is the same as the current certificate.
    206  1.1.1.4  christos If B<always> is present but no value can be obtained, an error is returned.
    207      1.1  christos 
    208  1.1.1.4  christos If B<issuer> is present, and in addition it has the option B<always> specified
    209  1.1.1.4  christos or B<keyid> is not present,
    210  1.1.1.4  christos then the issuer DN and serial number are copied from the issuer certificate.
    211      1.1  christos 
    212  1.1.1.4  christos Examples:
    213      1.1  christos 
    214  1.1.1.4  christos  authorityKeyIdentifier = keyid, issuer
    215      1.1  christos 
    216  1.1.1.4  christos  authorityKeyIdentifier = keyid, issuer:always
    217      1.1  christos 
    218  1.1.1.4  christos =head2 Subject Alternative Name
    219      1.1  christos 
    220  1.1.1.4  christos This is a multi-valued extension that supports several types of name
    221  1.1.1.4  christos identifier, including
    222  1.1.1.4  christos B<email> (an email address),
    223  1.1.1.4  christos B<URI> (a uniform resource indicator),
    224  1.1.1.4  christos B<DNS> (a DNS domain name),
    225  1.1.1.4  christos B<RID> (a registered ID: OBJECT IDENTIFIER),
    226  1.1.1.4  christos B<IP> (an IP address),
    227  1.1.1.4  christos B<dirName> (a distinguished name),
    228  1.1.1.4  christos and B<otherName>.
    229  1.1.1.4  christos The syntax of each is described in the following paragraphs.
    230  1.1.1.4  christos 
    231  1.1.1.4  christos The B<email> option has two special values.
    232  1.1.1.4  christos C<copy> will automatically include any email addresses
    233  1.1.1.4  christos contained in the certificate subject name in the extension.
    234  1.1.1.4  christos C<move> will automatically move any email addresses
    235  1.1.1.4  christos from the certificate subject name to the extension.
    236  1.1.1.4  christos 
    237  1.1.1.4  christos The IP address used in the B<IP> option can be in either IPv4 or IPv6 format.
    238  1.1.1.4  christos 
    239  1.1.1.4  christos The value of B<dirName> is specifies the configuration section containing
    240  1.1.1.4  christos the distinguished name to use, as a set of name-value pairs.
    241  1.1.1.4  christos Multi-valued AVAs can be formed by prefacing the name with a B<+> character.
    242  1.1.1.4  christos 
    243  1.1.1.4  christos The value of B<otherName> can include arbitrary data associated with an OID;
    244  1.1.1.4  christos the value should be the OID followed by a semicolon and the content in specified
    245  1.1.1.4  christos using the syntax in L<ASN1_generate_nconf(3)>.
    246      1.1  christos 
    247  1.1.1.4  christos Examples:
    248      1.1  christos 
    249  1.1.1.4  christos  subjectAltName = email:copy, email:my (a] example.com, URI:http://my.example.com/
    250      1.1  christos 
    251  1.1.1.4  christos  subjectAltName = IP:192.168.7.1
    252      1.1  christos 
    253  1.1.1.4  christos  subjectAltName = IP:13::17
    254      1.1  christos 
    255  1.1.1.4  christos  subjectAltName = email:my (a] example.com, RID:1.2.3.4
    256      1.1  christos 
    257  1.1.1.4  christos  subjectAltName = otherName:1.2.3.4;UTF8:some other identifier
    258      1.1  christos 
    259  1.1.1.4  christos  [extensions]
    260  1.1.1.4  christos  subjectAltName = dirName:dir_sect
    261      1.1  christos 
    262      1.1  christos  [dir_sect]
    263  1.1.1.4  christos  C = UK
    264  1.1.1.4  christos  O = My Organization
    265  1.1.1.4  christos  OU = My Unit
    266  1.1.1.4  christos  CN = My Name
    267  1.1.1.4  christos 
    268  1.1.1.4  christos Non-ASCII Email Address conforming the syntax defined in Section 3.3 of RFC 6531
    269  1.1.1.4  christos are provided as otherName.SmtpUTF8Mailbox. According to RFC 8398, the email
    270  1.1.1.4  christos address should be provided as UTF8String. To enforce the valid representation in
    271  1.1.1.4  christos the certificate, the SmtpUTF8Mailbox should be provided as follows
    272  1.1.1.4  christos 
    273  1.1.1.4  christos  subjectAltName=@alts
    274  1.1.1.4  christos  [alts]
    275  1.1.1.4  christos  otherName = 1.3.6.1.5.5.7.8.9;FORMAT:UTF8,UTF8String:nonasciiname.example.com
    276  1.1.1.4  christos 
    277  1.1.1.4  christos =head2 Issuer Alternative Name
    278  1.1.1.4  christos 
    279  1.1.1.4  christos This extension supports most of the options of subject alternative name;
    280  1.1.1.4  christos it does not support B<email:copy>.
    281  1.1.1.4  christos It also adds B<issuer:copy> as an allowed value, which copies any subject
    282  1.1.1.4  christos alternative names from the issuer certificate, if possible.
    283      1.1  christos 
    284      1.1  christos Example:
    285      1.1  christos 
    286      1.1  christos  issuerAltName = issuer:copy
    287      1.1  christos 
    288  1.1.1.4  christos =head2 Authority Info Access
    289      1.1  christos 
    290  1.1.1.4  christos This extension gives details about how to retrieve information that
    291  1.1.1.4  christos related to the certificate that the CA makes available. The syntax is
    292  1.1.1.4  christos B<access_id;location>, where B<access_id> is an object identifier
    293  1.1.1.4  christos (although only a few values are well-known) and B<location> has the same
    294  1.1.1.4  christos syntax as subject alternative name (except that B<email:copy> is not supported).
    295  1.1.1.4  christos 
    296  1.1.1.4  christos Possible values for access_id include B<OCSP> (OCSP responder),
    297  1.1.1.4  christos B<caIssuers> (CA Issuers),
    298  1.1.1.4  christos B<ad_timestamping> (AD Time Stamping),
    299  1.1.1.4  christos B<AD_DVCS> (ad dvcs),
    300  1.1.1.4  christos B<caRepository> (CA Repository).
    301      1.1  christos 
    302  1.1.1.4  christos Examples:
    303      1.1  christos 
    304  1.1.1.4  christos  authorityInfoAccess = OCSP;URI:http://ocsp.example.com/,caIssuers;URI:http://myca.example.com/ca.cer
    305      1.1  christos 
    306  1.1.1.4  christos  authorityInfoAccess = OCSP;URI:http://ocsp.example.com/
    307      1.1  christos 
    308      1.1  christos =head2 CRL distribution points
    309      1.1  christos 
    310  1.1.1.4  christos This is a multi-valued extension whose values can be either a name-value
    311  1.1.1.4  christos pair using the same form as subject alternative name or a single value
    312  1.1.1.4  christos specifying the section name containing all the distribution point values.
    313  1.1.1.4  christos 
    314  1.1.1.4  christos When a name-value pair is used, a DistributionPoint extension will
    315  1.1.1.4  christos be set with the given value as the fullName field as the distributionPoint
    316  1.1.1.4  christos value, and the reasons and cRLIssuer fields will be omitted.
    317  1.1.1.4  christos 
    318  1.1.1.4  christos When a single option is used, the value specifies the section, and that
    319  1.1.1.4  christos section can have the following items:
    320  1.1.1.4  christos 
    321  1.1.1.4  christos =over 4
    322  1.1.1.4  christos 
    323  1.1.1.4  christos =item fullname
    324  1.1.1.4  christos 
    325  1.1.1.4  christos The full name of the distribution point, in the same format as the subject
    326  1.1.1.4  christos alternative name.
    327  1.1.1.4  christos 
    328  1.1.1.4  christos =item relativename
    329      1.1  christos 
    330  1.1.1.4  christos The value is taken as a distinguished name fragment that is set as the
    331  1.1.1.4  christos value of the nameRelativeToCRLIssuer field.
    332      1.1  christos 
    333  1.1.1.4  christos =item CRLIssuer
    334      1.1  christos 
    335  1.1.1.4  christos The value must in the same format as the subject alternative name.
    336      1.1  christos 
    337  1.1.1.4  christos =item reasons
    338      1.1  christos 
    339  1.1.1.4  christos A multi-value field that contains the reasons for revocation. The recognized
    340  1.1.1.4  christos values are: C<keyCompromise>, C<CACompromise>, C<affiliationChanged>,
    341  1.1.1.4  christos C<superseded>, C<cessationOfOperation>, C<certificateHold>,
    342  1.1.1.4  christos C<privilegeWithdrawn>, and C<AACompromise>.
    343      1.1  christos 
    344  1.1.1.4  christos =back
    345      1.1  christos 
    346  1.1.1.4  christos Only one of B<fullname> or B<relativename> should be specified.
    347      1.1  christos 
    348      1.1  christos Simple examples:
    349      1.1  christos 
    350  1.1.1.4  christos  crlDistributionPoints = URI:http://example.com/myca.crl
    351  1.1.1.4  christos 
    352  1.1.1.4  christos  crlDistributionPoints = URI:http://example.com/myca.crl, URI:http://example.org/my.crl
    353      1.1  christos 
    354      1.1  christos Full distribution point example:
    355      1.1  christos 
    356  1.1.1.4  christos  [extensions]
    357  1.1.1.4  christos  crlDistributionPoints = crldp1_section
    358      1.1  christos 
    359      1.1  christos  [crldp1_section]
    360  1.1.1.4  christos  fullname = URI:http://example.com/myca.crl
    361  1.1.1.4  christos  CRLissuer = dirName:issuer_sect
    362  1.1.1.4  christos  reasons = keyCompromise, CACompromise
    363      1.1  christos 
    364      1.1  christos  [issuer_sect]
    365  1.1.1.4  christos  C = UK
    366  1.1.1.4  christos  O = Organisation
    367  1.1.1.4  christos  CN = Some Name
    368      1.1  christos 
    369      1.1  christos =head2 Issuing Distribution Point
    370      1.1  christos 
    371  1.1.1.4  christos This extension should only appear in CRLs. It is a multi-valued extension
    372      1.1  christos whose syntax is similar to the "section" pointed to by the CRL distribution
    373  1.1.1.4  christos points extension. The following names have meaning:
    374      1.1  christos 
    375  1.1.1.4  christos =over 4
    376      1.1  christos 
    377  1.1.1.4  christos =item fullname
    378      1.1  christos 
    379  1.1.1.4  christos The full name of the distribution point, in the same format as the subject
    380  1.1.1.4  christos alternative name.
    381      1.1  christos 
    382  1.1.1.4  christos =item relativename
    383      1.1  christos 
    384  1.1.1.4  christos The value is taken as a distinguished name fragment that is set as the
    385  1.1.1.4  christos value of the nameRelativeToCRLIssuer field.
    386      1.1  christos 
    387  1.1.1.4  christos =item onlysomereasons
    388      1.1  christos 
    389  1.1.1.4  christos A multi-value field that contains the reasons for revocation. The recognized
    390  1.1.1.4  christos values are: C<keyCompromise>, C<CACompromise>, C<affiliationChanged>,
    391  1.1.1.4  christos C<superseded>, C<cessationOfOperation>, C<certificateHold>,
    392  1.1.1.4  christos C<privilegeWithdrawn>, and C<AACompromise>.
    393      1.1  christos 
    394  1.1.1.4  christos =item onlyuser, onlyCA, onlyAA, indirectCRL
    395      1.1  christos 
    396  1.1.1.4  christos The value for each of these names is a boolean.
    397      1.1  christos 
    398  1.1.1.4  christos =back
    399      1.1  christos 
    400  1.1.1.4  christos Example:
    401      1.1  christos 
    402  1.1.1.4  christos  [extensions]
    403  1.1.1.4  christos  issuingDistributionPoint = critical, @idp_section
    404      1.1  christos 
    405  1.1.1.4  christos  [idp_section]
    406  1.1.1.4  christos  fullname = URI:http://example.com/myca.crl
    407  1.1.1.4  christos  indirectCRL = TRUE
    408  1.1.1.4  christos  onlysomereasons = keyCompromise, CACompromise
    409      1.1  christos 
    410  1.1.1.4  christos =head2 Certificate Policies
    411  1.1.1.4  christos 
    412  1.1.1.4  christos This is a I<raw> extension that supports all of the defined fields of the
    413  1.1.1.4  christos certificate extension.
    414  1.1.1.4  christos 
    415  1.1.1.4  christos Policies without qualifiers are specified by giving the OID.
    416  1.1.1.4  christos Multiple policies are comma-separated. For example:
    417  1.1.1.4  christos 
    418  1.1.1.4  christos  certificatePolicies = 1.2.4.5, 1.1.3.4
    419  1.1.1.4  christos 
    420  1.1.1.4  christos To include policy qualifiers, use the "@section" syntax to point to a
    421  1.1.1.4  christos section that specifies all the information.
    422      1.1  christos 
    423      1.1  christos The section referred to must include the policy OID using the name
    424  1.1.1.4  christos B<policyIdentifier>. cPSuri qualifiers can be included using the syntax:
    425  1.1.1.4  christos 
    426  1.1.1.4  christos  CPS.nnn = value
    427      1.1  christos 
    428  1.1.1.4  christos where C<nnn> is a number.
    429      1.1  christos 
    430      1.1  christos userNotice qualifiers can be set using the syntax:
    431      1.1  christos 
    432  1.1.1.4  christos  userNotice.nnn = @notice
    433      1.1  christos 
    434      1.1  christos The value of the userNotice qualifier is specified in the relevant section.
    435  1.1.1.4  christos This section can include B<explicitText>, B<organization>, and B<noticeNumbers>
    436      1.1  christos options. explicitText and organization are text strings, noticeNumbers is a
    437      1.1  christos comma separated list of numbers. The organization and noticeNumbers options
    438  1.1.1.4  christos (if included) must BOTH be present. Some software might require
    439  1.1.1.4  christos the B<ia5org> option at the top level; this changes the encoding from
    440  1.1.1.4  christos Displaytext to IA5String.
    441      1.1  christos 
    442      1.1  christos Example:
    443      1.1  christos 
    444  1.1.1.4  christos  [extensions]
    445  1.1.1.4  christos  certificatePolicies = ia5org, 1.2.3.4, 1.5.6.7.8, @polsect
    446      1.1  christos 
    447      1.1  christos  [polsect]
    448      1.1  christos  policyIdentifier = 1.3.5.8
    449  1.1.1.4  christos  CPS.1 = "http://my.host.example.com/"
    450  1.1.1.4  christos  CPS.2 = "http://my.your.example.com/"
    451  1.1.1.4  christos  userNotice.1 = @notice
    452      1.1  christos 
    453      1.1  christos  [notice]
    454  1.1.1.4  christos  explicitText = "Explicit Text Here"
    455  1.1.1.4  christos  organization = "Organisation Name"
    456  1.1.1.4  christos  noticeNumbers = 1, 2, 3, 4
    457      1.1  christos 
    458  1.1.1.4  christos The character encoding of explicitText can be specified by prefixing the
    459  1.1.1.4  christos value with B<UTF8>, B<BMP>, or B<VISIBLE> followed by colon. For example:
    460      1.1  christos 
    461      1.1  christos  [notice]
    462  1.1.1.4  christos  explicitText = "UTF8:Explicit Text Here"
    463      1.1  christos 
    464      1.1  christos =head2 Policy Constraints
    465      1.1  christos 
    466      1.1  christos This is a multi-valued extension which consisting of the names
    467      1.1  christos B<requireExplicitPolicy> or B<inhibitPolicyMapping> and a non negative integer
    468      1.1  christos value. At least one component must be present.
    469      1.1  christos 
    470      1.1  christos Example:
    471      1.1  christos 
    472      1.1  christos  policyConstraints = requireExplicitPolicy:3
    473      1.1  christos 
    474      1.1  christos =head2 Inhibit Any Policy
    475      1.1  christos 
    476      1.1  christos This is a string extension whose value must be a non negative integer.
    477      1.1  christos 
    478      1.1  christos Example:
    479      1.1  christos 
    480      1.1  christos  inhibitAnyPolicy = 2
    481      1.1  christos 
    482      1.1  christos =head2 Name Constraints
    483      1.1  christos 
    484  1.1.1.4  christos This is a multi-valued extension. The name should
    485      1.1  christos begin with the word B<permitted> or B<excluded> followed by a B<;>. The rest of
    486  1.1.1.4  christos the name and the value follows the syntax of subjectAltName except
    487  1.1.1.4  christos B<email:copy>
    488      1.1  christos is not supported and the B<IP> form should consist of an IP addresses and
    489      1.1  christos subnet mask separated by a B</>.
    490      1.1  christos 
    491      1.1  christos Examples:
    492      1.1  christos 
    493  1.1.1.4  christos  nameConstraints = permitted;IP:192.168.0.0/255.255.0.0
    494      1.1  christos 
    495  1.1.1.4  christos  nameConstraints = permitted;email:.example.com
    496      1.1  christos 
    497  1.1.1.4  christos  nameConstraints = excluded;email:.com
    498      1.1  christos 
    499      1.1  christos =head2 OCSP No Check
    500      1.1  christos 
    501  1.1.1.4  christos This is a string extension. It is parsed, but ignored.
    502      1.1  christos 
    503      1.1  christos Example:
    504      1.1  christos 
    505      1.1  christos  noCheck = ignored
    506      1.1  christos 
    507      1.1  christos =head2 TLS Feature (aka Must Staple)
    508      1.1  christos 
    509      1.1  christos This is a multi-valued extension consisting of a list of TLS extension
    510      1.1  christos identifiers. Each identifier may be a number (0..65535) or a supported name.
    511      1.1  christos When a TLS client sends a listed extension, the TLS server is expected to
    512      1.1  christos include that extension in its reply.
    513      1.1  christos 
    514      1.1  christos The supported names are: B<status_request> and B<status_request_v2>.
    515      1.1  christos 
    516      1.1  christos Example:
    517      1.1  christos 
    518      1.1  christos  tlsfeature = status_request
    519      1.1  christos 
    520      1.1  christos =head1 DEPRECATED EXTENSIONS
    521      1.1  christos 
    522      1.1  christos The following extensions are non standard, Netscape specific and largely
    523      1.1  christos obsolete. Their use in new applications is discouraged.
    524      1.1  christos 
    525  1.1.1.4  christos =head2 Netscape String extensions
    526      1.1  christos 
    527      1.1  christos Netscape Comment (B<nsComment>) is a string extension containing a comment
    528      1.1  christos which will be displayed when the certificate is viewed in some browsers.
    529  1.1.1.4  christos Other extensions of this type are: B<nsBaseUrl>,
    530      1.1  christos B<nsRevocationUrl>, B<nsCaRevocationUrl>, B<nsRenewalUrl>, B<nsCaPolicyUrl>
    531      1.1  christos and B<nsSslServerName>.
    532      1.1  christos 
    533      1.1  christos =head2 Netscape Certificate Type
    534      1.1  christos 
    535      1.1  christos This is a multi-valued extensions which consists of a list of flags to be
    536      1.1  christos included. It was used to indicate the purposes for which a certificate could
    537      1.1  christos be used. The basicConstraints, keyUsage and extended key usage extensions are
    538      1.1  christos now used instead.
    539      1.1  christos 
    540      1.1  christos Acceptable values for nsCertType are: B<client>, B<server>, B<email>,
    541      1.1  christos B<objsign>, B<reserved>, B<sslCA>, B<emailCA>, B<objCA>.
    542      1.1  christos 
    543      1.1  christos =head1 ARBITRARY EXTENSIONS
    544      1.1  christos 
    545      1.1  christos If an extension is not supported by the OpenSSL code then it must be encoded
    546      1.1  christos using the arbitrary extension format. It is also possible to use the arbitrary
    547      1.1  christos format for supported extensions. Extreme care should be taken to ensure that
    548      1.1  christos the data is formatted correctly for the given extension type.
    549      1.1  christos 
    550      1.1  christos There are two ways to encode arbitrary extensions.
    551      1.1  christos 
    552      1.1  christos The first way is to use the word ASN1 followed by the extension content
    553      1.1  christos using the same syntax as L<ASN1_generate_nconf(3)>.
    554      1.1  christos For example:
    555      1.1  christos 
    556  1.1.1.4  christos  [extensions]
    557  1.1.1.4  christos  1.2.3.4 = critical, ASN1:UTF8String:Some random data
    558  1.1.1.4  christos  1.2.3.4.1 = ASN1:SEQUENCE:seq_sect
    559      1.1  christos 
    560      1.1  christos  [seq_sect]
    561      1.1  christos  field1 = UTF8:field1
    562      1.1  christos  field2 = UTF8:field2
    563      1.1  christos 
    564      1.1  christos It is also possible to use the word DER to include the raw encoded data in any
    565      1.1  christos extension.
    566      1.1  christos 
    567  1.1.1.4  christos  1.2.3.4 = critical, DER:01:02:03:04
    568  1.1.1.4  christos  1.2.3.4.1 = DER:01020304
    569      1.1  christos 
    570      1.1  christos The value following DER is a hex dump of the DER encoding of the extension
    571      1.1  christos Any extension can be placed in this form to override the default behaviour.
    572      1.1  christos For example:
    573      1.1  christos 
    574  1.1.1.4  christos  basicConstraints = critical, DER:00:01:02:03
    575      1.1  christos 
    576  1.1.1.2  christos =head1 WARNINGS
    577      1.1  christos 
    578      1.1  christos There is no guarantee that a specific implementation will process a given
    579      1.1  christos extension. It may therefore be sometimes possible to use certificates for
    580      1.1  christos purposes prohibited by their extensions because a specific application does
    581      1.1  christos not recognize or honour the values of the relevant extensions.
    582      1.1  christos 
    583      1.1  christos The DER and ASN1 options should be used with caution. It is possible to create
    584  1.1.1.4  christos invalid extensions if they are not used carefully.
    585      1.1  christos 
    586      1.1  christos =head1 SEE ALSO
    587      1.1  christos 
    588  1.1.1.4  christos L<openssl-req(1)>, L<openssl-ca(1)>, L<openssl-x509(1)>,
    589      1.1  christos L<ASN1_generate_nconf(3)>
    590      1.1  christos 
    591      1.1  christos =head1 COPYRIGHT
    592      1.1  christos 
    593  1.1.1.5  christos Copyright 2004-2023 The OpenSSL Project Authors. All Rights Reserved.
    594      1.1  christos 
    595  1.1.1.4  christos Licensed under the Apache License 2.0 (the "License").  You may not use
    596      1.1  christos this file except in compliance with the License.  You can obtain a copy
    597      1.1  christos in the file LICENSE in the source distribution or at
    598      1.1  christos L<https://www.openssl.org/source/license.html>.
    599      1.1  christos 
    600      1.1  christos =cut
    601