When trying to navigate to a specific website (amazon.com in my case) I always get the "NET::ERR_CERT_COMMON_NAME_INVALID" error in Chrome (and equivalent errors in Safari/other browsers). When clicking to see the cert I can see that it's trying to associate it with the wrong website (register.be.xfinity.com instead of amazon.com) - see screenshot:

enter image description here

The background story is that my internet access modem was temporarily disabled and always routed all access to that xfinity "activation" website and I guess at some point I clicked approve to update the cert from that fake website. I tried removing the cert from keychain and adding it back (importing exported one and marking it as trusted) but it didn't help.

How can I fix the issue? Help!

Thanks!


Try changing your DNS.

Go to System Prefferences -> Network -> Advanced -> DNS

Then write down every DNS entry in case something goes wrong, and remove every DNS entry from the list.

Add at least two DNS servers. My favorite are Cisco (1.1.1.1) and IBM (9.9.9.9).

Click Ok, then Apply.

Try visiting the website.