Skip to content

Commit 97dc760

Browse files
atlas-formclaude
andcommitted
fix: add missing OpenSSL certificate extensions to init_pki.sh
- Add usr_cert section for client certificates with proper extensions - Add server_cert section for server certificates with proper extensions - Resolves external deployment issue: "Error checking extension section usr_cert" - Ensures PKI initialization creates complete OpenSSL configuration - Makes deployments self-contained without manual configuration files Fixes external server certificate signing by providing all required extension sections that the certificate signing process expects. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent e10ac1a commit 97dc760

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

crates/capsula-pki-server/init_pki.sh

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,24 @@ subjectKeyIdentifier = hash
118118
authorityKeyIdentifier = keyid:always,issuer
119119
basicConstraints = critical, CA:true, pathlen:0
120120
keyUsage = critical, digitalSignature, cRLSign, keyCertSign
121+
122+
[ usr_cert ]
123+
basicConstraints = CA:FALSE
124+
nsCertType = client, email
125+
nsComment = "OpenSSL Generated Client Certificate"
126+
subjectKeyIdentifier = hash
127+
authorityKeyIdentifier = keyid,issuer
128+
keyUsage = critical, nonRepudiation, digitalSignature, keyEncipherment
129+
extendedKeyUsage = clientAuth, emailProtection
130+
131+
[ server_cert ]
132+
basicConstraints = CA:FALSE
133+
nsCertType = server
134+
nsComment = "OpenSSL Generated Server Certificate"
135+
subjectKeyIdentifier = hash
136+
authorityKeyIdentifier = keyid,issuer:always
137+
keyUsage = critical, digitalSignature, keyEncipherment
138+
extendedKeyUsage = serverAuth
121139
EOF
122140

123141
log "Intermediate CA configuration created"

0 commit comments

Comments
 (0)