I am following these guidelines to generate self-signed certificates with OpenSSL.
I am under Windows 10. My working directory is as follows:
PS E:\Certificats\predix\root\ca> ls
Directory: E:\Certificats\predix\root\ca
Mode LastWriteTime Length Name
---- ------------- ------ ----
d----- 9/1/2016 11:57 AM certs
d----- 9/1/2016 11:55 AM crl
d----- 9/1/2016 12:00 PM intermediate
d----- 9/1/2016 11:55 AM newcerts
d----- 9/1/2016 11:56 AM private
-a---- 9/1/2016 11:55 AM 2 index.txt
-a---- 9/1/2016 11:56 AM 4306 openssl.cnf
-a---- 9/1/2016 11:55 AM 14 serial
After several steps in the guideline, when I type
openssl ca -config openssl.cnf -extensions v3_intermediate_ca -days 3650 -notext -md s
I get the following error
Using configuration from openssl.cnf
Enter pass phrase for ./private/ca.key.pem:
unable to load number from ./serial
error while loading serial number
12944:error:0D066096:asn1 encoding routines:a2i_ASN1_INTEGER:short line:.\crypto\asn1\f_int.c:212:
PS E:\Certificats\predix\root\ca> openssl ca -config openssl.cnf -extensions v3_intermediate_ca -days 3650 -notext -md sha256 -in intermediate/csr/intermediate.csr.pem -out intermediate/certs/intermediate.cert.pem
Using configuration from openssl.cnf
telling me that it has some issue reading the serial file.
The content of serial is
1000
Does anyone have a fix for this ? The file exists and its pathname in the conf file is the correct...