when I perform the following
openssl s_client -connect 0.0.0.0:8006
I get the Server certificate as:
-----BEGIN CERTIFICATE-----
MIICSTCCAbKgAwIBAgIESfnb7zANBgkqhkiG9w0BAQUFADBpMQswCQYDVQQGEwJJ ….
[1] From which destination does the machine take the "CERTIFICATE" with running the command "openssl s_client -connect 0.0.0.0:8006" ? , how can I learn from that about the server key or how to create the server key?
[2] There is a command that creates new CRT and KEY that after it the MD5 shows they FIT: openssl req -new -x509 -nodes -out server.crt -keyout server.key
[3] The question:there is a command who can convert server.crt file to server.key file ? because I know the "CERTIFICATE" and need to find his KEY (server.key).
- my default server key PATH:…./Apache/Apache/conf/ssl.key/server.key
The certificate s_client is printing out is the server's public key. The PKI (known to http servers as the "SSL Certificate") works by matched pairs of keys, on public and the other private.
Public certificates (usually .CRT files) cannot be used to generate matching private keys (usually .KEY files); the system is specifically designed this way.
Your question is quite hard to understand, and you seem to have some misconceptions about PKI. Perhaps you could ask the question you're getting at; for instance, are you trying to configure a HTTPS server, or something similar?