Fixing SSL Errors routing to localhost

So over the course of the weekend, I was maintaining an application that essentially redirected all http traffic to https back to itself. Normally this wasn’t an issue but the application was being stubborn and tossing sslcert issues.

At first, I said, Ah ha! Must be a cert issue. Took the time, certs were ok.

Next, I said, oh must be a routing issue! Nope, I saw all the traffic coming and going. I saw NO traffic at all for this bad request. This had me thinking…what if it never needs to touch my network at all?

What was going on? Turns out the server was missing a self signed localhost ssl cert.

In short running:

openssl req -new -x509 -newkey rsa:2048 -keyout /etc/pki/tls/private/localhost.key -nodes -days 3650 -out /etc/pki/tls/certs/localhost.crt

fixed my issues.

With all this being said, there are some issues with running your own self signed certs, but normally by that time the actual machine has already been compromised. A good read is linked below! Happy Saturday all!

http://security.stackexchange.com/questions/35033/what-are-the-risks-of-a-localhost-signed-cerificate

One thought on “Fixing SSL Errors routing to localhost”

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.