I
I
Ivan Ivanov2016-10-01 13:11:35
Denver
Ivan Ivanov, 2016-10-01 13:11:35

How to install a self-signed certificate on denwer?

How to install a self-signed certificate on denwer? I want to then add it to the trusted list so that chrome does not give an error.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
I
Ivan Ivanov, 2017-04-19
@romalu

Kapets, either I’m asking in the wrong place, or no one knows ... In general, I found the answer myself:
I have Denver on drive C, so
In the file
C:\WebServers\usr\local\apache\conf\httpd.conf we
write

<VirtualHost site.ru:443>
 SSLEngine on
 SSLCertificateFile C:\WebServers\usr\local\apache\certificate.crt
 SSLCertificateKeyFile C:\WebServers\usr\local\apache\certificate.key
 <Directory C:\WebServers\home\site.ru\www>
 AllowOverride All
 </Directory>
 DocumentRoot C:\WebServers\home\site.ru\www
 ServerName site.ru
 </VirtualHost>

Accordingly, you must first place the certificate itself and the key file in the C:\WebServers\usr\local\apache\ folder.
To generate the certificate, I used the command line in debian
openssl genrsa -out certificate.key 2048
then
openssl req -x509 -new -key certificate. key -days 10000 -out certificate.crt
and enter any data, even empty ones, the main thing is that the Common Name contains the address of your site (in the example site.ru). We copy the received key and certificate to the above folder, add the certificate to the trusted list (double click on the certificate file - install the certificate, then I chose where - in "Trusted Root Certification Authorities"), restart Denver. Profit)
P.s. don’t throw stones, how to make it easier I don’t know how to make self-signed certificates in Windows I don’t know, this is a ready-made solution that helped me, if you know how easier - welcome to the answers)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question