1

The whole error

Misdirected Request

The client needs a new connection for this request as the requested host name does not match the Server Name Indication (SNI) in use for this connection.

Apache Server at stories.therelevancehouse.com Port 443

I have a blog page linked with my company website https://www.therelevancehouse.com/. When I try to go from this page to https://stories.therelevancehouse.com/ using the header navigation "STORIES" button, it shows the above-mentioned error. But if I refresh the page then it works. Also when I directly open https://stories.therelevancehouse.com/ and try to go back to the main page by clicking on the logo on the top left corner, it shows the same error.

ALi Raza Darr
  • 13
  • 1
  • 3

3 Answers3

0

I was able to bypass this problem by mutating location.href to navigate directly to the endpoint which returns the 302 redirect. instead of using an anchor tag (<a href=>) or making a get request. And yes I have one certificate with wildcard (e.g. *.mysite.com)

0

I got the same error. To fix it, you have to check for the ServerName value. In my case, the value on port 80 were the same as on the port 443, so I had something like this:

<VirtualHost website.fr:80>
    ServerName MyWebsite
</VirtualHost>
<VirtualHost website.fr:443>
    ServerName MyWebsite
</VirtualHost>

Now, I'm using :

<VirtualHost website.fr:80>
    ServerName "website80"
</VirtualHost>
<VirtualHost website.fr:443>
    ServerName "website443"
</VirtualHost>

Such as ServerNames are differents, it works fine.

Elikill58
  • 109
  • 4
-1

This link seems to indicate that you can request your SSL provider to set-up SNI for your multi-domain certificate to fix the error: https://webidextrous.com/how-to-solve-421-misdirected-request-errors/

  • This appears to be specific to GoDaddy, and doesn't account for most web servers already having SNI enabled correctly. For example any Apache HTTPD using name based virtual hosts along with mod_ssl will get SNI implicitly. (Name based virtual hosting depends on it.) – Adambean Apr 27 '22 at 14:47