Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Error 310 (net::ERR_TOO_MANY_REDIRECTS) with SSL active on frontend
 
bri_tribouillet
Jr. Member
 
Total Posts:  2
Joined:  2013-01-19
 

Hey there,

I’m new to magento (but already got some experience in PHP/MySQl and some framework)

Anyway i installed Magento without any problem, i manage to install an SSL certificate that is working well for my admin side.

But I can’t access to frontend pages that require https.

Ex : https://www.noeka.fr/customer/account/

i get an error Error 310 (net::ERR_TOO_MANY_REDIRECTS).

Well i submit a ticket to my hosting (gandi.net) and here what they replied :

“It seems there is a redirection made in that place as you can see :
curl --capath /etc/ssl/certs/ -k -i https://www.noeka.fr:443/customer/account/

HTTP/1.1 302 Moved Temporarily
Content-Type: text/html; charset=iso-8859-1
Content-Length: 361
Connection: keep-alive
Server: Apache/2.4.3
X-Powered-By: PHP/5.4.4-10
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Set-Cookie: frontend=e9j3s12593j99q7j66usn1q9k0; expires=Mon, 04-Feb-2013 12:16:04 GMT; path=/; domain=www.noeka.fr; HttpOnly
Location: https://www.noeka.fr/customer/account/
Date: Mon, 04 Feb 2013 11:16:04 GMT
Via: 1.1 varnish
Accept-Ranges: bytes
Age: 0

<!DOCTYPE HTML PUBLIC “-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>302 Moved Temporarily</title>
</head><body>
<h1>Moved Temporarily</h1>
<p>The document has moved <a href="https://www.noeka.fr/customer/account/">here</a>.</p>
<p>Additionally, a 302 Found
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>

I let you check this since it’s not a problem from our side”

well i still don’t get it how to solve the problem.

all what i can do is desactivate the SSL for the frontend then i can access it, but i really need to activate it. What else i can do?

Image Attachments
Screen Shot 2013-02-07 at 7.34.03 PM.png
 
Magento Community Magento Community
Magento Community
Magento Community
 
bri_tribouillet
Jr. Member
 
Total Posts:  2
Joined:  2013-01-19
 

i finally found a solution, i added this in index.php :

$_SERVER[’HTTPS’] = ‘on’;

but is it secure to do that? anybody got a better solution?

Best regards,

Bri

 
Magento Community Magento Community
Magento Community
Magento Community
 
Thierry S.
Sr. Member
 
Total Posts:  94
Joined:  2008-03-19
Paris
 

I do have the same issue. The solution you are suggesting is working, however it change most of the unsecure link and ressources to secure links.

Magento code to check HTTPS

app/code/local/Mage/Core/Model/Config.php

$secure = (!empty($_SERVER[\’HTTPS\’]) && ($_SERVER[\’HTTPS\’]!=\’off\’)) || $_SERVER[\’SERVER_PORT\’]==\’443\’;

Gandi (gandi.net hosting provider ) cluster:

HTTP: SERVER_PORT 80 only
HTTPS : SERVER_PORT 443 + HTTPS on

Apparently magento is hosted on a back-end server with php-fpm running.

Any help or thoughts where to check/look at would be appreciate.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top