Vorrei creare un certificato tsa per il mio servizio di timestamping.crea il certificato tsa (timestamping) con openssl - aggiungi un extendedKeyUsage in un certificato
prima cosa creare un certificato principale
openssl genrsa -out tsaroot.key 4096 -config openssl.cnf
openssl req -new -x509 -days 1826 -key tsaroot.key -out tsaroot.crt -config openssl.cnf
Poi creo il certificato tsa
openssl genrsa -des3 -out tsa.key 4096 -config openssl.cnf
openssl req -new -key tsa.key -out tsa.csr -config openssl.cnf
openssl x509 -req -days 730 -in tsa.csr -CA tsaroot.crt -CAkey tsaroot.key -set_serial 01 -out tsa.crt
openssl pkcs12 -export -out tsa.p12 -inkey tsa.key -in tsa.crt -chain -CAfile tsaroot.crt
Nel mio file openssl.cnf, aggiungo la seguente riga:
extendedKeyUsage = critical,timeStamping
Howerver, il certificato creato non sembra includere extendeKeyUsage (quando provo a leggerlo con bouncy ca stle ho ottenuto un "certificato deve avere un'estensione ExtendedKeyUsage". exception
Come posso generare un certificato tsa valido (con il valore extendedKeyUsage corretto incluso)?
Grazie