osCommerce and osCMax shopping cart software forums

Shopping Cart Software

osCommerce with teeth!

 

Session problems using shared SSL

This is a discussion on Session problems using shared SSL within the osCMax v1.7 Installation forums, part of the osCMax v1.7 Forums category; When I login using the Webmakers login box or via the standard login page the login box correctly disappears and ...


Go Back   osCommerce and osCMax shopping cart software forums > osCMax v1.7 Forums > osCMax v1.7 Installation

Register FAQ Members List Calendar Mark Forums Read


Free community membership! Fast easy FREE membership
Closed Thread

 

LinkBack Thread Tools
  #1  
Old 07-06-2004, 03:17 PM
Member
 
Join Date: Aug 2003
Location: Southampton UK
Posts: 63
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
NickW
Default Session problems using shared SSL

When I login using the Webmakers login box or via the standard login page the login box correctly disappears and 'log-off' appears on the top menu bar, and the url has changed to that of the shared secure server. But as soon as I navigate elsewhere on the site it thinks I'm logged off.

I've had the osc standard version working ok with the same shared secure server and similar config settings. Settings as follows:

Administration > Configuration > Sessions:

Session Directory = /tmp
Force Cookie Use = False
Check SSL Session ID = True
Check User Agent = False
Check IP Address = False
Prevent Spider Sessions = True
Recreate Session = True

configure settings:

define('HTTP_SERVER', 'http://www.<domain>');
define('HTTPS_SERVER', 'https://dnslinux.co.uk/~<package name>');
define('ENABLE_SSL', true);
define('HTTP_COOKIE_DOMAIN', 'www.<domain>');
define('HTTPS_COOKIE_DOMAIN', 'www.<domain>');
define('HTTP_COOKIE_PATH', '/<catalog dir>/');
define('HTTPS_COOKIE_PATH', '/<catalog dir>/');
define('DIR_WS_HTTP_CATALOG', '/<catalog dir>/');
define('DIR_WS_HTTPS_CATALOG', '/<catalog dir>/');

define('USE_PCONNECT', 'false');
define('STORE_SESSIONS', 'mysql');

If I set ENABLE_SSL to false then the login works ok. Why should the login on the standard MS2 version work ok with shared SSL but MAX doesn't?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #2  
Old 07-07-2004, 05:29 AM
jpf's Avatar
jpf jpf is offline
Moderator

 
Join Date: Sep 2003
Posts: 1,558
Thanks: 1
Thanked 84 Times in 71 Posts
Rep Power: 10
jpf is a glorious beacon of lightjpf is a glorious beacon of lightjpf is a glorious beacon of lightjpf is a glorious beacon of lightjpf is a glorious beacon of light
Default

Set "force cookie use=true"
__________________
JPF - osCMax Fourm Moderator
Try out our osCMax at: Live Catalog Demo
Limited access Admin: Live Admin Demo
Feel free to add products they way you want and then purchase them -=+=- Sorry nothing will be billed or shipped!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #3  
Old 07-07-2004, 05:36 AM
Member
 
Join Date: Aug 2003
Location: Southampton UK
Posts: 63
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
NickW
Default

I don't think 'force cookies' will work with shared SSL? The osCommerce Knowledge Base document on Security and Privacy at http://www.oscommerce.info/kb/osComm...lementations/4 was helpful.

Quote:
As the cookie is set on the top level domain of the web server, the secured https server must also exist on the same domain.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #4  
Old 07-07-2004, 06:08 AM
michael_s's Avatar
osCMax Developer

 
Join Date: Jul 2002
Location: Phoenix, AZ
Posts: 10,326
Thanks: 68
Thanked 322 Times in 305 Posts
Rep Power: 10
michael_s has a reputation beyond reputemichael_s has a reputation beyond reputemichael_s has a reputation beyond reputemichael_s has a reputation beyond reputemichael_s has a reputation beyond reputemichael_s has a reputation beyond reputemichael_s has a reputation beyond reputemichael_s has a reputation beyond reputemichael_s has a reputation beyond reputemichael_s has a reputation beyond reputemichael_s has a reputation beyond repute
Default

Yes, force cookies will not work with shared ssl.

This is most likely a problem with the sessions settings in the admin.

The ssl core code in max and ms2 is identical, so look elsewhere for the problem, like the loginbox or your configuration files and make sure your sessions settings are identical.
__________________
Michael Sasek
osCMax Developer


  • osCMax Templates - Hundreds of premium quality templates. New designs every month!

  • xShop for osCMax - Windows Based osCMax administration. Improved workflow, security, speed and convenience.

  • osCMax Hosting - From basic hosting to High Availability, Load Balanced arrays, the most experienced osCMax host.

  • osCMax Template Tutorial - Learn how to make your own custom templates and how to use the powerful features of the osCMax template system.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #5  
Old 07-07-2004, 07:11 AM
jpf's Avatar
jpf jpf is offline
Moderator

 
Join Date: Sep 2003
Posts: 1,558
Thanks: 1
Thanked 84 Times in 71 Posts
Rep Power: 10
jpf is a glorious beacon of lightjpf is a glorious beacon of lightjpf is a glorious beacon of lightjpf is a glorious beacon of lightjpf is a glorious beacon of light
Default

Sorry did not see the shared SSL
__________________
JPF - osCMax Fourm Moderator
Try out our osCMax at: Live Catalog Demo
Limited access Admin: Live Admin Demo
Feel free to add products they way you want and then purchase them -=+=- Sorry nothing will be billed or shipped!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #6  
Old 07-07-2004, 07:46 AM
Member
 
Join Date: Aug 2003
Location: Southampton UK
Posts: 63
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
NickW
Default

I don't know if this was the problem but in configure.php I removed the www's in the settings for:

HTTP_SERVER
HTTP_COOKIE_DOMAIN
HTTPS_COOKIE_DOMAIN

( I had http://www.domain.co.uk now I have http://domain.co.uk) and it's working ok now.

Thanks.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #7  
Old 07-07-2004, 09:34 AM
Member
 
Join Date: Aug 2003
Location: Southampton UK
Posts: 63
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
NickW
Default

The catalogue is working but it asks for another login before going through the checkout, which is as it gets directed to https.

What's the recommended setup for the admin section regarding SSL? For a live standard ocs MS2 store I have changed the href to the orders page to be SSL. For this MAX installation I've removed the www's from the configure.php file and I've added the SSL parameter to the call on function tep_href_link in orders.php for the link on the 'edit' button, but as soon as it goes to https it asks me to login again and then loops back to the orders summary rather than the detail page.

Should therefore the whole of the admin section be directed to https?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #8  
Old 07-11-2004, 03:16 AM
Member
 
Join Date: Aug 2003
Location: Southampton UK
Posts: 63
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
NickW
Default

The difference between a standard ocs shop I run and the new one with oscMAX is that the login on the standard osc install is via an href link which connects to the shared SSL, where as the Webmakers login box I'm using with the MAX install is on the default homepage and I assumed was not loaded via https. However reading the code if I understand it correctly the loginbox is posting to the login page with an action to process via SSL.

The problem is I don't see why it is requiring a second login at the checkout?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #9  
Old 07-19-2004, 06:33 AM
Member
 
Join Date: Aug 2003
Location: Southampton UK
Posts: 63
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
NickW
Default

I think it's solved, think it was the cookie paths in the catalog configure.php, I've changed them to include 'http://' as follows:
define('HTTP_COOKIE_DOMAIN', 'http://<domain>.co.uk');
define('HTTPS_COOKIE_DOMAIN', 'http://<domain>.co.uk');
define('HTTP_COOKIE_PATH', '/');
define('HTTPS_COOKIE_PATH', '/');
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #10  
Old 07-24-2004, 06:39 AM
Member
 
Join Date: Aug 2003
Location: Southampton UK
Posts: 63
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
NickW
Default

Although the problem SSL is solved for the catalog, I still have an issue with the Admin section. When I login to the Admin section it automatically uses https and once the login details are transmitted the index page is back to http. When editing orders I want to be using https. For a standard version of osc ms2 I changed the code in the orders page to set the href to use SSL and it worked ok, but with osmax I find that the same amendment causes the system to return to the admin login page.

Can anyone please advise. I've checked the settings in configure.php and they appear to be ok (as standard there is no ref to cookie paths though).
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Closed Thread

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads

Thread Thread Starter Forum Replies Last Post
shared SSL Help Please! lil-raskals osCommerce 2.2 Modification Help 2 09-30-2004 09:30 PM
Session Problems stevenstevensteven osCommerce 2.2 Modification Help 0 12-19-2003 05:45 PM
Database Session tracking problems Anonymous osCMax v1.7 Discussion 1 12-03-2003 02:54 AM
SSL Errors, Session Cookie, Session Cache, NOVICE Problems? hanool osCommerce 2.2 Modification Help 1 09-07-2003 11:49 AM
Shared SSL Help Anonymous osCommerce 2.2 Installation Help 13 03-20-2003 01:42 AM


All times are GMT -8. The time now is 06:28 AM.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO
http://www.oscmax.com/forums/
Copyright 2008 osCMax