Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagebash
titleCreate Root CA Certificate
linenumberstrue
# stepGenerate 1Root Generate Certificate Authority (CA) Private Key
openssl ecparam -name prime256v1 -genkey -noout -out root-ca.key

# step 2: Generate CertificateRoot AuthorityCA Certificate
openssl req -new -x509 -sha256 -key root-ca.key -out root-ca.crt

You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter '.', the field will be left blank.
-----
Country Name (2 letter code) [XX]:DE
State or Province Name (full name) []:Berlin
Locality Name (eg, city) [Default City]:Berlin
Organization Name (eg, company) [Default Company Ltd]:SOS
Organizational Unit Name (eg, section) []:JS7
Common Name (eg, your name or your server's hostname) []:JS7 Deployment CA
Email Address []:


Explanation:

  • As a response to the second command the OpenSSL utility prompts for a number of specifications for the Root CA:
    • Country Name: a 2 letter country code is expected as stated for example with https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2
    • State or Province Name: the name of a state is expected
    • Locality Name:  the name of a city is expected
    • Organization Name: arbitrary input is allowed
    • Organizational Unit Name: arbitrary input is allowed
    • Common Name: an arbitrary name can be chosen as the name of the Root CA
    • Email Address: empty input is allowed

Anchor
server_certificate
server_certificate
Creating a Server Certificate

...