-
Notifications
You must be signed in to change notification settings - Fork 3
/
openssl_timestamping_cas.cnf
178 lines (157 loc) · 6.03 KB
/
openssl_timestamping_cas.cnf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
# Copyright © 2017 Alessandro Menti
#
# This file is licensed under the terms and conditions of the MIT license.
# See the LICENSE file for more details.
# OpenSSL configuration file for time stamping CAs.
oid_file = additional_oids
[ca]
default_ca = timestamping_ca
[req]
default_bits = 4096
default_md = sha256
string_mask = utf8only
prompt = no
# Change the distinguished name section to use depending on the subordinate CA
# you generate.
distinguished_name = timestamping_distinguished_name
# Edit the following sections as needed. Note that not all optional fields are
# populated here: check the DN profiles to know the admissible ones.
[timestamping_distinguished_name]
countryName = "IT"
postalCode = "12345"
stateOrProvinceName = "AA"
localityName = "Locality"
organizationName = "My CA"
commonName = "My CA Time Stamping Service"
[timestamping-extendedvalidation_distinguished_name]
countryName = "IT"
postalCode = "12345"
stateOrProvinceName = "AA"
localityName = "Locality"
jurisdictionCountryName = "IT"
serialNumber = "12345678"
businessCategory = "Private Organization"
organizationName = "My CA"
commonName = "My CA Extended Validation Time Stamping Service"
# ----------------------------------------------------------------------------
[timestamping_ca]
dir = ./timestamping
database = $dir/index
serial = $dir/serial
crlnumber = $dir/crlserial
certificate = $dir/timestampingca.cer
private_key = $dir/timestampingca.pvk
new_certs_dir = $dir/newcerts
# Choose SHA-256 as the hash algorithm.
default_md = sha256
# Make certificates valid for 4050 days (~135 months) and CRLs valid for seven
# days.
# Remember that keypairs must be used at most for 15 months
default_days = 4050
default_crl_days = 7
# To ease key rollover, allow certificates to have the same Subject DN and be
# valid at the same time.
unique_subject = no
# Only add the DN components/extensions we specify here to the issued
# certificates.
preserve = no
copy_extensions = none
email_in_dn = no
policy = timestamping_dn_policy
# Show (almost all) details when signing a certificate request.
name_opt = ca_default
cert_opt = ca_default
x509_extensions = timestamping_certificate_extensions
crl_extensions = timestamping_crl_extensions
# Extensions for time stamping certificates.
[timestamping_certificate_extensions]
basicConstraints = critical,CA:FALSE
keyUsage = critical,digitalSignature
extendedKeyUsage = critical,timeStamping
subjectKeyIdentifier = hash
authorityKeyIdentifier = keyid:always
# Replace the URLs here
authorityInfoAccess = OCSP;URI:http://myca.example.com/ocsp/timestampingca,caIssuers;URI:http://myca.example.com/repository/timestampingca.cer
crlDistributionPoints = URI:http://myca.example.com/repository/timestampingca.crl
# If you are following the validation practices mandated by the CA/Browser
# Forum, add "cabCSGuidelines" to the line below.
certificatePolicies = @polsect
[timestamping_dn_policy]
commonName = supplied
organizationalUnitName = optional
organizationName = supplied # must contain the legal name
streetAddress = optional
localityName = supplied
stateOrProvinceName = optional
postalCode = optional
countryName = supplied
[timestamping_crl_extensions]
# Replace the URL here
authorityInfoAccess = caIssuers;URI:http://myca.example.com/repository/timestampingca.cer
authorityKeyIdentifier = keyid:always
# ----------------------------------------------------------------------------
[timestamping-extendedvalidation_ca]
dir = ./timestamping-extendedvalidation
database = $dir/index
serial = $dir/serial
crlnumber = $dir/crlserial
certificate = $dir/timestamping-extendedvalidationca.cer
private_key = $dir/timestamping-extendedvalidationca.pvk
new_certs_dir = $dir/newcerts
# Choose SHA-256 as the hash algorithm.
default_md = sha256
# Make certificates valid for 4050 days (~135 months) and CRLs valid for seven
# days.
# Remember that keypairs must be used at most for 15 months
default_days = 4050
default_crl_days = 7
# To ease key rollover, allow certificates to have the same Subject DN and be
# valid at the same time.
unique_subject = no
# Only add the DN components/extensions we specify here to the issued
# certificates.
preserve = no
copy_extensions = none
email_in_dn = no
policy = timestamping-extendedvalidation_dn_policy
# Show (almost all) details when signing a certificate request.
name_opt = ca_default
cert_opt = ca_default
x509_extensions = timestamping-extendedvalidation_certificate_extensions
crl_extensions = timestamping-extendedvalidation_crl_extensions
# Extensions for time stamping certificates.
[timestamping-extendedvalidation_certificate_extensions]
basicConstraints = critical,CA:FALSE
keyUsage = critical,digitalSignature
extendedKeyUsage = critical,timeStamping
subjectKeyIdentifier = hash
authorityKeyIdentifier = keyid:always
# Replace the URLs here
authorityInfoAccess = OCSP;URI:http://myca.example.com/ocsp/timestamping-extendedvalidationca,caIssuers;URI:http://myca.example.com/repository/timestamping-extendedvalidationca.cer
crlDistributionPoints = URI:http://myca.example.com/repository/timestamping-extendedvalidationca.crl
# If you are following the validation practices mandated by the CA/Browser
# Forum, add "cabEVGuidelines" to the line below.
certificatePolicies = @polsect
[timestamping-extendedvalidation_dn_policy]
commonName = supplied
organizationName = supplied
businessCategory = supplied
serialNumber = supplied
jurisdictionLocalityName = optional
jurisdictionStateOrProvinceName = optional
jurisdictionCountryName = supplied
streetAddress = optional
localityName = supplied
stateOrProvinceName = supplied
postalCode = optional
countryName = supplied
[timestamping-extendedvalidation_crl_extensions]
# Replace the URL here
authorityInfoAccess = caIssuers;URI:http://myca.example.com/repository/timestamping-extendedvalidationca.cer
authorityKeyIdentifier = keyid:always
# ----------------------------------------------------------------------------
[polsect]
# Replace myCPSOID with the OID associated to your CPS.
policyIdentifier = 1.2.3.4
# Replace the following URL with the one pointing to your CPS.
CPS.1 = "http://myca.example.com/repository/cps.pdf"