Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

SSL - Redirection Loop

Hello,

I guess from the title some people can understand what the problem is.
So I am trying to force ssl using htaccess file with the following rule

RewriteEngine On
RewriteCond %{SERVER_PORT} 80
RewriteRule ^(.*)$ https://example.com/$1 [R=301,L]

I can access most the site with that but at some subfolders all I get is a redirection loop error.
I would do this the virtual host way but this is on a shared hosting enviroment.

Any ideas?

Thanks,
George

Comments

  • nerouxneroux Member

    Not that it would probably change anything in this case, but I'd rather go for the HTTPS flag than the port.

    RewriteCond %{HTTPS} on

    Anyhow, do the logs say anything? Any special URL structure? Can you post a link that doesnt work?

  • Yeah tried that as well. Didn't work though.

    No special URL Structure and according to host it should work based on their server's configuration.

    I prefer not to share the link cause its a colleagues site and not mine.

    I searched a bit and found numerous different opinions about cleaning cookies and system time and all that.
    None of these worked.

    I am thinking if its possible that the problem is with the SSL Certificate but I personally never saw that before.

  • nerouxneroux Member

    TH_George said: Yeah tried that as well. Didn't work though.

    Didnt expect it to change anything. Its just the better approach IMHO.

    TH_George said: I prefer not to share the link cause its a colleagues site and not mine.

    If you wish PM it.

    TH_George said: I searched a bit and found numerous different opinions about cleaning cookies and system time and all that. None of these worked.

    I am thinking if its possible that the problem is with the SSL Certificate but I personally never saw that before.

    To be honest, neither sounds too much related. But you never know of course. Without URL impossible to say.

  • Hey thanks for helping.

    Just got an email from the host saying it was a mis-configuration in their system. (BS I say..)

    Anyway now it works fine, although I am wondering what mistake they made.

    Thanks though.

  • AlexBarakovAlexBarakov Patron Provider, Veteran

    Observed similar thing with force re-write rule and force SSL option of WHMCS. It got stuck in infinite loop.

  • TH_GeorgeTH_George Member
    edited June 2014

    Thats the first place I looked for a solution but nothing worked.

    Actually all the info I got from there were correct and it should have worked just fine but the host had something wrong in their server configuration.

  • nerouxneroux Member

    Whats new in there?

  • @neroux said:
    Whats new in there?

    a lot of things that you don't know and won't know for your entire life ;)

Sign In or Register to comment.