blob: 220220909ccec2b8f72924e35f34e1e46c182679 [file] [log] [blame]
Brian Waters13d96012017-12-08 16:53:31 -06001# Note: for this file to be working, an environment var CA_ROOT_DIR = directory
2# must be defined and pointing to the CA top-level directory.
3
4HOME = .
5RANDFILE = $ENV::HOME/.rnd
6
7oid_section = new_oids
8
9[ new_oids ]
10
11
12####################################################################
13[ req ]
14default_bits = 1024
15# default_keyfile = privkey.pem
16string_mask = utf8only
17
18distinguished_name = req_distinguished_name
19attributes = req_attributes
20req_extensions = v3_req # overwrite with -reqexts
21x509_extensions = ca_cert # overwrite with -extensions; used for self-signed keys only
22
23[ req_distinguished_name ]
24countryName = Country Name (2 letter code)
25countryName_default = JP
26countryName_min = 2
27countryName_max = 2
28stateOrProvinceName = State or Province Name (full name)
29stateOrProvinceName_default = Tokyo
30localityName = Locality Name (eg, city)
31localityName_default = Koganei
320.organizationName = Organization Name (eg, company)
330.organizationName_default = WIDE
341.organizationName = Second Organization Name (eg, company)
351.organizationName_default = NICT
36organizationalUnitName = Organizational Unit Name (eg, section)
37organizationalUnitName_default = AAA WG testbed
38
39[ req_attributes ]
40challengePassword = A challenge password
41challengePassword_min = 0
42challengePassword_max = 20
43unstructuredName = An optional company name
44
45[ v3_req ]
46# Extensions to add to a certificate request
47basicConstraints = CA:FALSE
48keyUsage = nonRepudiation, digitalSignature, keyEncipherment
49
50[ v3_req_ca ]
51# Extensions to add to a certificate request for CA
52basicConstraints = CA:TRUE
53
54
55####################################################################
56[ ca ]
57default_ca = CA_default # The default ca section
58
59[ CA_default ]
60
61dir = $ENV::CA_ROOT_DIR # Where everything is kept
62certs = $dir/public # Where the issued certs are kept
63crl_dir = $dir/public # Where the issued crl are kept
64database = $dir/index.txt # database index file.
65#unique_subject = no # Set to 'no' to allow creation of
66 # several ctificates with same subject.
67new_certs_dir = $dir/public # default place for new certs.
68
69certificate = $dir/public/cacert.pem # The CA certificate
70serial = $dir/serial # The current serial number
71crlnumber = $dir/crlnumber # the current crl number
72crl = $dir/public/local.pem # The current CRL
73private_key = $dir/private/cakey.pem # The private key
74x509_extensions = usr_cert # The extentions to add to the cert
75 # overwrite with -extensions
76name_opt = ca_default # Subject Name options
77cert_opt = ca_default # Certificate field options
78crl_extensions = crl_ext
79
80default_days = 3650 # how long to certify for
81default_crl_days= 365 # how long before next CRL
82default_md = sha1 # which md to use.
83preserve = no # keep passed DN ordering
84
85# We accept to sign anything, but a real deployment would limit to proper domain etc...
86policy = policy_anything
87
88[ policy_anything ]
89countryName = optional
90stateOrProvinceName = optional
91localityName = optional
92organizationName = optional
93organizationalUnitName = optional
94commonName = supplied
95emailAddress = optional
96
97[ usr_cert ]
98basicConstraints=CA:FALSE
99# This is typical in keyUsage for a client certificate.
100keyUsage = nonRepudiation, digitalSignature, keyEncipherment
101subjectKeyIdentifier=hash
102authorityKeyIdentifier=keyid,issuer
103
104[ ca_cert ]
105# Extensions for a typical CA
106subjectKeyIdentifier=hash
107authorityKeyIdentifier=keyid:always,issuer:always
108basicConstraints = critical,CA:true # Remove "critical," in case of problems
109keyUsage = cRLSign, keyCertSign
110# subjectAltName=email:copy
111# Copy issuer details
112# issuerAltName=issuer:copy
113
114[ crl_ext ]
115# CRL extensions.
116# Only issuerAltName and authorityKeyIdentifier make any sense in a CRL.
117# issuerAltName=issuer:copy
118authorityKeyIdentifier=keyid:always,issuer:always
119
120