2 # OpenSSL example configuration file.
3 # This is mostly being used for generation of certificate requests.
6 # This definition stops the following lines choking if HOME isn't
9 RANDFILE = $ENV::HOME/.rnd
10 oid_file = $ENV::HOME/.oid
11 oid_section = new_oids
13 # To use this configuration file with the "-extfile" option of the
14 # "openssl x509" utility, name here the section containing the
15 # X.509v3 extensions to use:
17 # (Alternatively, use a configuration file that has only
18 # X.509v3 extensions in its main [= default] section.)
22 # We can add new OIDs in here for use by 'ca' and 'req'.
23 # Add a simple OID like this:
25 # Or use config file substitution like this:
26 # testoid2=${testoid1}.5.6
28 ####################################################################
30 default_ca = CA_default # The default ca section
32 ####################################################################
35 dir = ./demoCA # Where everything is kept
36 certs = $dir/certs # Where the issued certs are kept
37 crl_dir = $dir/crl # Where the issued crl are kept
38 database = $dir/index.txt # database index file.
39 new_certs_dir = $dir/newcerts # default place for new certs.
41 certificate = $dir/cacert.pem # The CA certificate
42 serial = $dir/serial # The current serial number
43 crl = $dir/crl.pem # The current CRL
44 private_key = $dir/private/cakey.pem# The private key
45 RANDFILE = $dir/private/.rand # private random number file
47 x509_extensions = usr_cert # The extentions to add to the cert
49 # Extensions to add to a CRL. Note: Netscape communicator chokes on V2 CRLs
50 # so this is commented out by default to leave a V1 CRL.
51 # crl_extensions = crl_ext
53 default_days = 365 # how long to certify for
54 default_crl_days= 30 # how long before next CRL
55 default_md = md5 # which md to use.
56 preserve = no # keep passed DN ordering
58 # A few difference way of specifying how similar the request should look
59 # For type CA, the listed attributes must be the same, and the optional
60 # and supplied fields are just that :-)
66 stateOrProvinceName = match
67 organizationName = match
68 organizationalUnitName = optional
70 emailAddress = optional
72 # For the 'anything' policy
73 # At this point in time, you must list all acceptable 'object'
76 countryName = optional
77 stateOrProvinceName = optional
78 localityName = optional
79 organizationName = optional
80 organizationalUnitName = optional
82 emailAddress = optional
84 ####################################################################
87 default_keyfile = privkey.pem
88 distinguished_name = req_distinguished_name
89 attributes = req_attributes
90 x509_extensions = v3_ca # The extentions to add to the self signed cert
92 # Passwords for private keys if not present they will be prompted for
93 # input_password = secret
94 # output_password = secret
96 # This sets the permitted types in a DirectoryString. There are several
98 # default: PrintableString, T61String, BMPString.
99 # pkix : PrintableString, BMPString.
100 # utf8only: only UTF8Strings.
101 # nobmp : PrintableString, T61String (no BMPStrings).
102 # MASK:XXXX a literal mask value.
103 # WARNING: current versions of Netscape crash on BMPStrings or UTF8Strings
104 # so use this option with caution!
105 dirstring_type = nobmp
107 # req_extensions = v3_req # The extensions to add to a certificate request
109 [ req_distinguished_name ]
110 countryName = Country Name (2 letter code)
111 countryName_default = AU
115 stateOrProvinceName = State or Province Name (full name)
116 stateOrProvinceName_default = Some-State
118 localityName = Locality Name (eg, city)
120 0.organizationName = Organization Name (eg, company)
121 0.organizationName_default = Internet Widgits Pty Ltd
123 # we can do this but it is not needed normally :-)
124 #1.organizationName = Second Organization Name (eg, company)
125 #1.organizationName_default = World Wide Web Pty Ltd
127 organizationalUnitName = Organizational Unit Name (eg, section)
128 #organizationalUnitName_default =
130 commonName = Common Name (eg, YOUR name)
133 emailAddress = Email Address
134 emailAddress_max = 40
136 # SET-ex3 = SET extension number 3
139 challengePassword = A challenge password
140 challengePassword_min = 4
141 challengePassword_max = 20
143 unstructuredName = An optional company name
147 # These extensions are added when 'ca' signs a request.
149 # This goes against PKIX guidelines but some CAs do it and some software
150 # requires this to avoid interpreting an end user certificate as a CA.
152 basicConstraints=CA:FALSE
154 # Here are some examples of the usage of nsCertType. If it is omitted
155 # the certificate can be used for anything *except* object signing.
157 # This is OK for an SSL server.
158 # nsCertType = server
160 # For an object signing certificate this would be used.
161 # nsCertType = objsign
163 # For normal client use this is typical
164 # nsCertType = client, email
166 # and for everything including object signing:
167 # nsCertType = client, email, objsign
169 # This is typical in keyUsage for a client certificate.
170 # keyUsage = nonRepudiation, digitalSignature, keyEncipherment
172 # This will be displayed in Netscape's comment listbox.
173 nsComment = "OpenSSL Generated Certificate"
175 # PKIX recommendations harmless if included in all certificates.
176 subjectKeyIdentifier=hash
177 authorityKeyIdentifier=keyid,issuer:always
179 # This stuff is for subjectAltName and issuerAltname.
180 # Import the email address.
181 # subjectAltName=email:copy
183 # Copy subject details
184 # issuerAltName=issuer:copy
186 #nsCaRevocationUrl = http://www.domain.dom/ca-crl.pem
195 # Extensions to add to a certificate request
197 basicConstraints = CA:FALSE
198 keyUsage = nonRepudiation, digitalSignature, keyEncipherment
203 # Extensions for a typical CA
206 # PKIX recommendation.
208 subjectKeyIdentifier=hash
210 authorityKeyIdentifier=keyid:always,issuer:always
212 # This is what PKIX recommends but some broken software chokes on critical
214 #basicConstraints = critical,CA:true
215 # So we do this instead.
216 basicConstraints = CA:true
218 # Key usage: this is typical for a CA certificate. However since it will
219 # prevent it being used as an test self-signed certificate it is best
220 # left out by default.
221 # keyUsage = cRLSign, keyCertSign
223 # Some might want this also
224 # nsCertType = sslCA, emailCA
226 # Include email address in subject alt name: another PKIX recommendation
227 # subjectAltName=email:copy
228 # Copy issuer details
229 # issuerAltName=issuer:copy
231 # DER hex encoding of an extension: beware experts only!
233 # Where 'obj' is a standard or added object
234 # You can even override a supported extension:
235 # basicConstraints= critical, DER:30:03:01:01:FF
240 # Only issuerAltName and authorityKeyIdentifier make any sense in a CRL.
242 # issuerAltName=issuer:copy
243 authorityKeyIdentifier=keyid:always,issuer:always