osCommerce and osCMax shopping cart software forums

Shopping Cart Software

osCommerce with teeth!

 
 

secure admin, shared ssl, re-directed to login

This is a discussion on secure admin, shared ssl, re-directed to login within the osCMax v2 Installation issues forums, part of the osCMax v2.0 Forums category; Hi, I've got a problem with all the stores I've set up using a shared SSL cert and using a ...


Go Back   osCommerce and osCMax shopping cart software forums > osCMax v2.0 Forums > osCMax v2 Installation issues

Register FAQ Members List Calendar Mark Forums Read


Free community membership! Fast easy FREE membership
Closed Thread

 

LinkBack Thread Tools
  #1  
Old 12-01-2005, 09:25 AM
New Member
 
Join Date: Mar 2005
Posts: 18
Thanks: 2
Thanked 4 Times in 1 Post
Rep Power: 0
avibodha is on a distinguished road
Default secure admin, shared ssl, re-directed to login

Hi,

I've got a problem with all the stores I've set up using a shared SSL cert and using a secure admin area.

Using EasyPopulate, when I click any of the download options I'm booted back to login. Same with Attribute Manager once I select a product to edit, back to login. In Orders, if I change the top dropdown to show only Processed for example, same thing, booted back to log in.

I've looked at all the old posts, here and oscommerce, and haven't been able to find out what's happening.

* I did add all the files to the admin permissions
* The links on the left boxes are passing in oscAdminId correctly
* Most everything else works fine.
* Have Requires cookies off
* Only happens when admin is secured using SSL
* Safe mode is off

Here's the applicable part of my admin config:

define('HTTP_SERVER', 'https://hs42.order-vault.net/heritagecamps.org/');
// define('HTTP_SERVER', 'http://www.heritagecamps.org');
define('HTTP_CATALOG_SERVER', 'http://www.heritagecamps.org/');
define('HTTPS_SERVER', 'https://hs42.order-vault.net/heritagecamps.org/');
define('HTTPS_CATALOG_SERVER', 'https://hs42.order-vault.net/heritagecamps.org/');
define('ENABLE_SSL_CATALOG', 'true');

Does anyone have any ideas? Any suggestions of what to try? Thanks for any help...
---todd
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Sponsored Links
Advertisement
  #2  
Old 12-01-2005, 09:50 AM
michael_s's Avatar
osCMax Developer

 
Join Date: Jul 2002
Location: Phoenix, AZ
Posts: 10,532
Thanks: 76
Thanked 334 Times in 313 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 RE: secure admin, shared ssl, re-directed to login

Did you check this page:
http://oscdox.com/modules.php?op=mod...p;pagename=SSL

Config should look something like this:
Code:
  define('HTTP_SERVER', 'https://hs42.order-vault.net/heritagecamps.org'); // eg, http://localhost - should not be empty for productive servers
  define('HTTP_CATALOG_SERVER', 'http://www.heritagecamps.org');
  define('HTTPS_CATALOG_SERVER', 'https://hs42.order-vault.net/heritagecamps.org');
  define('ENABLE_SSL_CATALOG', 'true'); // secure webserver for catalog module
  define('DIR_FS_DOCUMENT_ROOT', '/correct/path/to/catalog/'); // where the pages are located on the server
  define('DIR_WS_ADMIN', '/catalog/admin/'); // absolute path required
  define('DIR_FS_ADMIN', '/correct/path/to admin//'); // absolute path required
Also make sure you store your sessions in the database:
Code:
define('STORE_SESSIONS', 'mysql');
__________________
Michael Sasek
osCMax Developer


  • osCMax Templates - Hundreds of premium quality templates designed for osCMax 2. Loyalty discounts up to 30% off!
    Each purchase supports the osCMax project with much needed funds!

  • 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. Default multi server configuration for exceptional performance!

  • 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!
  #3  
Old 12-01-2005, 10:56 AM
New Member
 
Join Date: Mar 2005
Posts: 18
Thanks: 2
Thanked 4 Times in 1 Post
Rep Power: 0
avibodha is on a distinguished road
Default

Hi Michael,

Thanks for the link and the fixes to my paths, didn't realize I had messed up the '/' at the end. Unfortunately that wasn't the problem.

I did review the link but it seemed out of date. FYI, the shared ssl info there for admin has the non-ssl setting for HTTP_SERVER, while yours and others suggest using the SSL setting for this. Also, it's my understanding that the admin doesn't use cookies but instead passes the oscAdminId in each link so the cookie settings are not needed. Is that true? Also, I don't find any references to DIR_WS_HTTP_CATALOG, so that may be from an older codebase.

*
I did find and fix the problem with EasyPopulate. It had hardcoded paths so the oscAdminId was not added to the links.

The lines at .832 should be replaced with these:

<a href="<?php echo tep_href_link("easypopulate.php","download=stream& amp;dltype=full"); ?>">Download <b>Complete</b> tab-delimited .txt file to edit</a><br>
<a href="<?php echo tep_href_link("easypopulate.php","download=stream& amp;dltype=priceqty"); ?>">Download <b>Model/Price/Qty</b> tab-delimited .txt file to edit</a><br>
<a href="<?php echo tep_href_link("easypopulate.php","download=stream& amp;dltype=category"); ?>">Download <b>Model/Category</b> tab-delimited .txt file to edit</a><br>
<a href="<?php echo tep_href_link("easypopulate.php","download=stream& amp;dltype=froogle"); ?>">Download <b>Froogle</b> tab-delimited .txt file</a><br>

Same for all the other links on the page...Works great now...

My other two problems are in Attribute manager once a product is chosen and then Edit is pressed and in Orders, changing the top right Status drop down. I'm guessing it's bad coding now, not a problem in my setup. What do you think?

thanks,
---todd
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #4  
Old 12-01-2005, 12:25 PM
New Member
 
Join Date: Mar 2005
Posts: 18
Thanks: 2
Thanked 4 Times in 1 Post
Rep Power: 0
avibodha is on a distinguished road
Default

Well, it turns out I was wrong about cookies, they are used in a shared SSL secure admin - if you do them right!

Here's what works:

define('HTTP_SERVER', 'https://secure-domain.com');
define('HTTPS_SERVER', 'https://secure-domain.com');
define('DIR_WS_ADMIN', '/~user/catalog/admin/');


The code in application_top.php:
Code:
ini_set('session.cookie_path', DIR_WS_ADMIN);
means that the cookie MUST be set to include your ~user path info for it to work!

Using this, there's no need to change EasyPopulate and now the Order Status change updates perfectly.

Only problem now is the Attribute Manager, Edit product still not working...
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #5  
Old 12-01-2005, 05:47 PM
New Member
 
Join Date: Mar 2005
Posts: 18
Thanks: 2
Thanked 4 Times in 1 Post
Rep Power: 0
avibodha is on a distinguished road
Default

Here's the problem with Attribute Manager:

The form is using $PHP_SELF for the action.

My server is returning /~admin233/catalog/admin/server_info.php from phpinfo, instead of /mydomain.com/catalog/admin/server_info.php.

So, the Cookie Path is set to /mydomain.com/catalog/admin/ and PHP_SELF returns /~somethingelse/catalog/admin which means that the cookie is not allowed and so we're back at the login page.

Not sure why PHP_SELF isn't returning the correct path...must be something about virtual servers...or maybe related to SSL?

The short-term fix is to use basename() on it for now...everywhere things don't work...

Does anyone else have a PHP_SELF not matching the file system path on a shared server in SSL in admin?

Hope this helps someone else too,
---todd
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #6  
Old 07-03-2006, 12:46 PM
Cisco's Avatar
Member
 
Join Date: Feb 2003
Posts: 85
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
Cisco
Default

DO you have to a SSL Cert. to make sure that your SSL or HTTPS is working?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Sponsored Links
Advertisement
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
Affiliate link secure non-secure kwiznoz osCMax v2 Installation issues 6 08-28-2005 01:08 PM
Admin Login Problem - my customer can't login, I can pram0310 osCMax v1.7 Installation 2 10-29-2004 10:46 AM
Secure admin backend.. Help and/or ideas pleassee edgecrush3r osCMax v1.7 Installation 3 07-31-2004 12:52 AM
Well crap... admin login not allowing login-no errors tauras911 osCMax v1.7 Installation 2 07-06-2004 11:12 PM
Need Images to Display in Secure Admin Walter osCommerce 2.2 Modification Help 0 11-09-2003 03:53 PM


All times are GMT -8. The time now is 05:09 PM.


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