walter-clayton / covidantivirus

0 stars 0 forks source link

making the website HTTPS #1

Open walter-clayton opened 4 years ago

walter-clayton commented 4 years ago

certChecker

walter-clayton commented 4 years ago

the domain name doesn't seem to be directing to Heroku now. The only problem is that it doesnt load. I might have to put the SSL on Heroku. Here is the link for instructions

walter-clayton commented 4 years ago

Generate a private key with these instructions Download OpenSSL from here

walter-clayton commented 4 years ago

image

walter-clayton commented 4 years ago

image C:\Program Files\OpenSSL-Win64\bin>openssl req -new -newkey rsa:2048 -nodes -keyout server.key -out server_csr.txt Can't load ./.rnd into RNG 12772:error:2406F079:random number generator:RAND_load_file:Cannot open file:crypto\rand\randfile.c:98:Filename=./.rnd Generating a RSA private key .........+++++ ..............+++++ writing new private key to 'server.key' req: Can't open "server.key" for writing, Permission denied Cannot write random bytes: 12772:error:24070079:random number generator:RAND_write_file:Cannot open file:crypto\rand\randfile.c:233:Filename=./.rnd

walter-clayton commented 4 years ago

Found this to find a solution but did not work

image

walter-clayton commented 4 years ago

Installed the Win64 OpenSSL v1.1.1f Light | 3MB installer then I realised I made a mistake in my previous set up I did not include the appropriate path. So now I will try it image

walter-clayton commented 4 years ago

Still can't get it to work. I'm gonna uninstall it all and start again. image

walter-clayton commented 4 years ago

Can't load ./.rnd into RNG openssl

walter-clayton commented 4 years ago

I realised I made a mistake again with the path image

walter-clayton commented 4 years ago

tried this and this didnt work

walter-clayton commented 4 years ago

Finally got it to work nicely This was indeed an issue with Windows admin image gave permissions

walter-clayton commented 4 years ago

image So it seems that I have generated a private key, back to the heroku docs

walter-clayton commented 4 years ago

Now back to Heroku. I have written a server.key private key image

walter-clayton commented 4 years ago

I am now going to generate a CSR from the previous code I did earlier except this time I am doing it in the working repository. https://www.namecheap.com/support/knowledgebase/article.aspx/10161/14/generating-a-csr-on-windows-using-openssl

walter-clayton commented 4 years ago

image doesn't seem to find the signing key.

image I'll need to find the key matching to the certificate.

walter-clayton commented 4 years ago

Apparently there are a few sites that host free SSL certificates. After reading extensively on the topic, you can only host the SSL with the custom domain by paying the $7/month hobby package. Click here or this one or this Godaddy/Heroku specific guide for the guide. OR use a free heroku add-on called Let’s Encrypt that provides free SSL certificate Alternatively, if your website is static, you can use Netlify to host your custom domain with the SSL. Click here Or you can also use Github pages

walter-clayton commented 4 years ago

Cloudflare can provide free SSL