I copied /System/Library/OpenSSL/openssl.cnf to my home folder so I could set default values for certificate creation. How do I set up OpenSSL to use my config file instead of the regular one? I could add a statement to my ~/.bashrc file. I've done web searches and searched the openssl.org website but could not find the answer. One post on Stack Overflow mentioned a parameter -config but was not referenced in a command.
Asked
Active
Viewed 4.5k times
10
1 Answers
11
It would depend on what commands you're running.
If you run req or ca they would support a -config parameter. Which would also be visible if you run openssl req -? or openssl ca -?.
If you want to make it the actual default without exclusively specifying it you should check Correct location of openssl.cnf file.
From the above link for the options of the req command:
-config filename
this allows an alternative configuration file to be specified, this overrides the compile time filename or any specified in the OPENSSL_CONF environment variable.