Jump to content

  • You cannot start a new topic
  • You cannot reply to this topic

Redirect loop with ssl Rate Topic   - - - - -

 
  • clayhenry
  • Junior Member
  • Members
  • Join Date: 07-Feb 10
  • 13 posts

Posted 07 February 2010 - 06:57 PM #1

I did a clean install of CS cart, hoping this will fix the issue...but no.

Any pages accessed through https is thrown into a redirect loop
(or firefox message: The page isn't redirecting properly)

eg.
http://quessentials.com/dev/index.php -- works fine

https://quessentials.com/dev/index.php -- goes into a loop

I have never had the store working properly under ssl

The ssl certificate is working correctly on the server. is there something I am missing?

 
  • indy0077
  • Senior Member
  • Banned
  • Join Date: 03-Nov 09
  • 1431 posts

Posted 07 February 2010 - 07:08 PM #2

Did you configure your config.local.php properly? Your https URL is missing your subfolder /dev/

// Host and directory where software is installed on no-secure server
$config['http_host'] = 'quessentials.com/dev';
$config['http_path'] = '/dev';

// Host and directory where software is installed on secure server
$config['https_host'] = 'quessentials.com/dev';
$config['https_path'] = '/dev';

Bye
.
CS-Cart Professional €160.00 | CS-Cart Multi-Vendor €625.00 | CS-Cart Hosting | SSL Certificates
.
CS-Cart Optimized Servers *** USA & UK VPS Servers

 
  • The Tool
  • Been Here Way Too Long Member
  • Members
  • Join Date: 30-Mar 07
  • 3917 posts

Posted 07 February 2010 - 07:15 PM #3

Your home page isn't supposed to be secure. If you have checked the 3 first items in "Settings", the only thing that will be secure is admin, checkout, or any page that contains customer information.

Just a quick scan you don't have SSL for checkout.

 
  • clayhenry
  • Junior Member
  • Members
  • Join Date: 07-Feb 10
  • 13 posts

Posted 07 February 2010 - 07:42 PM #4

Thanks for the quick reply.

Tool Outfitters, you are 100% correct. I have secured the checkout and it does the same thing.


indy0077, I have updated my config just like you have it. Now, i can't access anything.

I have also tried:

$config['http_host'] = 'quessentials.com';
$config['http_path'] = '/dev';

$config['https_host'] = 'quessentials.com/dev';
$config['https_path'] = '';

and other combinations, same problem...

 
  • indy0077
  • Senior Member
  • Banned
  • Join Date: 03-Nov 09
  • 1431 posts

Posted 07 February 2010 - 07:52 PM #5

How did you do that you have unsecure site in /dev/ and secure in root?:

$config['http_host'] = 'quessentials.com';
$config['http_path'] = '/dev';

$config['https_host'] = 'quessentials.com/dev';
$config['https_path'] = '';

Then try this one, but I'm not sure what is your real instal directory:

// Host and directory where software is installed on no-secure server
$config['http_host'] = 'quessentials.com/dev/';
$config['http_path'] = '/dev';

// Host and directory where software is installed on secure server
$config['https_host'] = 'quessentials.com/dev/';

Just play with the slahses...

$config['https_path'] = '/dev';

Here is the commented code of config.local.php:

* Example:
* Your url is http://www.yourcompany.com/store/cart
* $config['http_host'] = 'www.yourcompany.com';
* $config['http_path'] = '/store/cart';
*
* Your secure url is https://secure.yourc...secure_dir/cart
* $config['https_host'] = 'secure.yourcompany.com';
* $config['https_path'] = '/secure_dir/cart';
*
*


.
CS-Cart Professional €160.00 | CS-Cart Multi-Vendor €625.00 | CS-Cart Hosting | SSL Certificates
.
CS-Cart Optimized Servers *** USA & UK VPS Servers

 
  • clayhenry
  • Junior Member
  • Members
  • Join Date: 07-Feb 10
  • 13 posts

Posted 07 February 2010 - 08:16 PM #6

thanks indy0077.

none of the combinations work, I've been at it for 2 days now. I would hope its just a config issue but it seems like it might be something else.

 
  • indy0077
  • Senior Member
  • Banned
  • Join Date: 03-Nov 09
  • 1431 posts

Posted 07 February 2010 - 08:23 PM #7

If you switch off the secure function in the admin is the site working properly?
How looks your htaccess file?

EDIT: Clear your cache in /var and all folders in /var/compiled/

Because if I hover your links e.g. "View Cart" it shows a http:// URL not https://
.
CS-Cart Professional €160.00 | CS-Cart Multi-Vendor €625.00 | CS-Cart Hosting | SSL Certificates
.
CS-Cart Optimized Servers *** USA & UK VPS Servers

 
  • clayhenry
  • Junior Member
  • Members
  • Join Date: 07-Feb 10
  • 13 posts

Posted 07 February 2010 - 08:25 PM #8

yes, if its turned off and does not go through https, it works fine.


.htaccess:

DirectoryIndex index.php

<IfModule mod_rewrite.c>
RewriteEngine on
# Some hostings require RewriteBase to be uncommented
# Example:
# Your store url is http://www.yourcompany.com/store/cart
# So "RewriteBase" should be:
# RewriteBase /store/cart
RewriteBase /dev
RewriteCond %{REQUEST_FILENAME} !\.(png|gif|ico|swf|jpe?g|js|css)$
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . index.php?sef_rewrite=1 [L,QSA]

RewriteCond %{REQUEST_FILENAME} .*\/catalog\/.*
RewriteCond %{REQUEST_FILENAME} -d
RewriteCond %{REQUEST_FILENAME}/index.html !-f
RewriteRule . index.php?sef_rewrite=1 [L,QSA]

</IfModule>

 
  • indy0077
  • Senior Member
  • Banned
  • Join Date: 03-Nov 09
  • 1431 posts

Posted 07 February 2010 - 08:32 PM #9

htaccess is OK.

Is your SSL issued for www or without www?
.
CS-Cart Professional €160.00 | CS-Cart Multi-Vendor €625.00 | CS-Cart Hosting | SSL Certificates
.
CS-Cart Optimized Servers *** USA & UK VPS Servers

 
  • clayhenry
  • Junior Member
  • Members
  • Join Date: 07-Feb 10
  • 13 posts

Posted 07 February 2010 - 08:35 PM #10

SSL is issued as www.quessentials.com

I also did my http_host and https_host as www.quessentials.com

 
  • indy0077
  • Senior Member
  • Banned
  • Join Date: 03-Nov 09
  • 1431 posts

Posted 07 February 2010 - 09:05 PM #11

The redirect loop error looks like this:
Page A sends you to Page B which sends you to Page A

That means, if you request your https URL it will send you again to the http URL.
.
CS-Cart Professional €160.00 | CS-Cart Multi-Vendor €625.00 | CS-Cart Hosting | SSL Certificates
.
CS-Cart Optimized Servers *** USA & UK VPS Servers

 
  • clayhenry
  • Junior Member
  • Members
  • Join Date: 07-Feb 10
  • 13 posts

Posted 07 February 2010 - 09:34 PM #12

Yes, i understand that but it only happens within the cs cart application...

How would this be happening if both http_host and https_host go to www.quessentials.com/dev
Where is the loop created??

 
  • indy0077
  • Senior Member
  • Banned
  • Join Date: 03-Nov 09
  • 1431 posts

Posted 07 February 2010 - 09:57 PM #13

Yes, i understand that but it only happens within the cs cart application...

How would this be happening if both http_host and https_host go to www.quessentials.com/dev
Where is the loop created??

I think I know what's your problem. You have created a subdomain dev.quessentials.com and then also a new subfolder called /dev/. It can't work.
.
CS-Cart Professional €160.00 | CS-Cart Multi-Vendor €625.00 | CS-Cart Hosting | SSL Certificates
.
CS-Cart Optimized Servers *** USA & UK VPS Servers

 
  • indy0077
  • Senior Member
  • Banned
  • Join Date: 03-Nov 09
  • 1431 posts

Posted 07 February 2010 - 10:03 PM #14

Try to change the installation folder and change your config.local.php:

// Host and directory where software is installed on no-secure server
$config['http_host'] = 'www.quessentials.com';
$config['http_path'] = '/newfolder';

// Host and directory where software is installed on secure server
$config['https_host'] = 'www.quessentials.com';
$config['https_path'] = '/newfolder';


.
CS-Cart Professional €160.00 | CS-Cart Multi-Vendor €625.00 | CS-Cart Hosting | SSL Certificates
.
CS-Cart Optimized Servers *** USA & UK VPS Servers

 
  • The Tool
  • Been Here Way Too Long Member
  • Members
  • Join Date: 30-Mar 07
  • 3917 posts

Posted 07 February 2010 - 11:21 PM #15

From what I can tell, it's the "www" that is missing in all of the previously tried configs and you stated that the cert was for www:

// Host and directory where software is installed on no-secure server
$config['http_host'] = 'www.quessentials.com';
$config['http_path'] = '/dev';

// Host and directory where software is installed on secure server
$config['https_host'] = 'www.quessentials.com';
$config['https_path'] = '/dev';


 
  • clayhenry
  • Junior Member
  • Members
  • Join Date: 07-Feb 10
  • 13 posts

Posted 08 February 2010 - 12:57 AM #16

Thanks for all your help.

I have tried www in the config as well. no go.

I have also removed dev.quessentials.com subdomain, all its files, dns entries and db.

Changed quessentials.com/dev to quessentials.com/testing

It has not changed the situation.

 
  • indy0077
  • Senior Member
  • Banned
  • Join Date: 03-Nov 09
  • 1431 posts

Posted 08 February 2010 - 01:11 AM #17

... and this one?

// Host and directory where cs-cart is installed on usual server
$config['http_host'] = $_SERVER['HTTP_HOST'];
$config['http_path'] = '/your_cscart_directory';

// Host and directory where cs-cart is installed on secure server
$config['https_host'] = $_SERVER['HTTPS_HOST'];
$config['https_path'] = '/your_cscart_directory';


But if nothing helps, I would ask your hosting provider, it can be a php- or https settings problem in the server or php configuration.
.
CS-Cart Professional €160.00 | CS-Cart Multi-Vendor €625.00 | CS-Cart Hosting | SSL Certificates
.
CS-Cart Optimized Servers *** USA & UK VPS Servers

 
  • indy0077
  • Senior Member
  • Banned
  • Join Date: 03-Nov 09
  • 1431 posts

Posted 08 February 2010 - 01:24 AM #18

At least you can try to put this to your htaccess file:

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


.
CS-Cart Professional €160.00 | CS-Cart Multi-Vendor €625.00 | CS-Cart Hosting | SSL Certificates
.
CS-Cart Optimized Servers *** USA & UK VPS Servers

 
  • clayhenry
  • Junior Member
  • Members
  • Join Date: 07-Feb 10
  • 13 posts

Posted 08 February 2010 - 02:00 AM #19

nope. none of it worked. I have moved the cart down to root.

I have also spoke to the server admin, everything is as it should be on their end.:(

 
  • indy0077
  • Senior Member
  • Banned
  • Join Date: 03-Nov 09
  • 1431 posts

Posted 08 February 2010 - 02:29 AM #20

Here you can see our demo CS-Cart installed in a subfolder. The SSL works fine:

http://www.martfox.c...scsub/index.php

The problem might be in the apache settings, your files or your configuration.

No CS-Cart.
.
CS-Cart Professional €160.00 | CS-Cart Multi-Vendor €625.00 | CS-Cart Hosting | SSL Certificates
.
CS-Cart Optimized Servers *** USA & UK VPS Servers