Site maintenance: Sun 15 Nov, from 20:00 UTC, about 4–6 hours. Details

This cutover relies on some testing that is still incomplete so may be cancelled at short notice

SSL issues

Locked

Started by dante2010 on 2 Aug 2006, 3:29 AM · Views: 2,937

Results 1 to 20 of 20
This thread is locked. New replies are disabled.
2 Aug 2006, 3:29 AM
#1
dante2010 avatar

dante2010

New Zenner

Join Date:
Jun 2006
Posts:
28
Plugin Contributions:
0

SSL issues

Hi,

When you are using SSL with the cart, what files need to be copied into the secure folder on the server? I uploaded the entire zencart dir to my secure dir, but when I click the goto checkout button it says it's looking for (and can't find)

The requested URL /mysite/store2/zc_install/index.php was not found on this server.

The link on the checkout button is actually:

https://secure2secure.com/mysite/store2/index.php?main_page=checkout_shipping

EDITED: Never, ever post the zen_id or zenAdminID (session id) in a forum, email, newsgroup, newsletter, advertisement, etc. etc. etc. or you will be doomed ... :eek:

2 Aug 2006, 3:34 AM
#2
merlinpa1969 avatar

merlinpa1969

Totally Zenned

Join Date:
Mar 2004
Posts:
13,031
Plugin Contributions:
4

Re: SSL issues

Hi Dante, you were correct in adding ALL the files to the secure server
you will need to modify the includes/configure.php and the
admin/includes/configure.php on the secure server,

in the very last line you will see a line that ends in /cache

somewhere in this line you will see something like httpdocs
you will need to change this part to the name of the secure folder.

Zen cart PCI compliant Hosting

3 Aug 2006, 12:55 AM
#3
dante2010 avatar

dante2010

New Zenner

Join Date:
Jun 2006
Posts:
28
Plugin Contributions:
0

Re: SSL issues

I did that.

It still wants to goto the same URL tho.

https://secure2secure.com/ian/store2/zc_install/index.php

If you go there you'll see the error I am receiving.

My config files are setup as:

includes/configure.php

// Define the webserver and path parameters
  // HTTP_SERVER is your Main webserver: eg, http://www.yourdomain.com
  // HTTPS_SERVER is your Secure webserver: eg, https://www.yourdomain.com
  define('HTTP_SERVER', 'http://factoryshoe.ianarmstrong.com');
  define('HTTPS_SERVER', 'https://secure2secure.com/ian');

  // Use secure webserver for checkout procedure?
  define('ENABLE_SSL', 'true');

admin/includes/configure.php

define('HTTP_SERVER', 'http://factoryshoe.ianarmstrong.com');
  define('HTTPS_SERVER', 'https://secure2secure.com/ian');
  define('HTTP_CATALOG_SERVER', 'http://factoryshoe.ianarmstrong.com');
  define('HTTPS_CATALOG_SERVER', 'https://secure2secure.com/ian');

  // Use secure webserver for catalog module and/or admin areas?
  define('ENABLE_SSL_CATALOG', 'true');
  define('ENABLE_SSL_ADMIN', 'false');

On secure side - includes/configure.php

// Define the webserver and path parameters
  // HTTP_SERVER is your Main webserver: eg, http://www.yourdomain.com
  // HTTPS_SERVER is your Secure webserver: eg, https://www.yourdomain.com
  define('HTTP_SERVER', 'http://factoryshoe.ianarmstrong.com');
  define('HTTPS_SERVER', 'https://secure2secure.com/ian');

  // Use secure webserver for checkout procedure?
  define('ENABLE_SSL', 'true');

.
.
.
 define('SQL_CACHE_METHOD', 'none'); 
  define('DIR_FS_SQL_CACHE', '/home/secure2/ian/public_html/factoryshoe/store2/cache');

admin/includes/configure.php

 define('HTTP_SERVER', 'http://factoryshoe.ianarmstrong.com');
  define('HTTPS_SERVER', 'https://secure2secure.com/ian');
  define('HTTP_CATALOG_SERVER', 'http://factoryshoe.ianarmstrong.com');
   define('HTTPS_CATALOG_SERVER', 'https://secure2secure.com/ian');

  // Use secure webserver for catalog module and/or admin areas?
  define('ENABLE_SSL_CATALOG', 'false');
  define('ENABLE_SSL_ADMIN', 'false');

.
.
.

 define('SQL_CACHE_METHOD', 'none'); 
  define('DIR_FS_SQL_CACHE', '/home/secure2/ian/public_html/factoryshoe/store2/cache');
3 Aug 2006, 1:04 AM
#4
styledata avatar

styledata

Zen Follower

Join Date:
Feb 2006
Posts:
290
Plugin Contributions:
0

Re: SSL issues

You can also check with your hosting provider to see if your domain can be setup to share the same folder for http and https. Simplifies things tremendously, if it is availab.e

Give us your best shot!
http://www.photoimprints.com

3 Aug 2006, 1:22 AM
#5
dante2010 avatar

dante2010

New Zenner

Join Date:
Jun 2006
Posts:
28
Plugin Contributions:
0

Re: SSL issues

I don't think I'll be able to do that. I have to use a shared cert and their setup is that I have to ftp info a totally diff server to access the secure side.

3 Aug 2006, 1:57 AM
#6
merlinpa1969 avatar

merlinpa1969

Totally Zenned

Join Date:
Mar 2004
Posts:
13,031
Plugin Contributions:
4

Re: SSL issues

Ok you changed those thats Kool,

now look at the VERY bottom of the config files

you will see a list that looks like this
/your/server/path/here/to/cache

you need to make the path changes for the Secure server, your host should be able to give you these absolute paths,

If you dont want to go through the headache of having to make ALL changes to any files and upgrads/ insert moduels and all 2x you might want to take a look at the certified hosts,

that setup is definitly NOT e commerce SSL friendly

Zen cart PCI compliant Hosting

3 Aug 2006, 2:14 AM
#7
dante2010 avatar

dante2010

New Zenner

Join Date:
Jun 2006
Posts:
28
Plugin Contributions:
0

Re: SSL issues

Ok I've changed them to:

define('DIR_FS_SQL_CACHE', '/home/secure2/public_html/ian/store2/cache');

.. which is the absolute path to my store files on the secure server.

Still getting the same error tho.

3 Aug 2006, 2:34 AM
#8
merlinpa1969 avatar

merlinpa1969

Totally Zenned

Join Date:
Mar 2004
Posts:
13,031
Plugin Contributions:
4

Re: SSL issues

there are several of these in each config file
You need to modify the ones in the secure folder

Zen cart PCI compliant Hosting

3 Aug 2006, 1:26 PM
#9
dante2010 avatar

dante2010

New Zenner

Join Date:
Jun 2006
Posts:
28
Plugin Contributions:
0

Re: SSL issues

There are several places in each config file that you have to change the "cache" path? I only see one line in each config file that relates to the cache directory... Am I misunderstanding what you mean?

I have changed the ones on the secure server.

3 Aug 2006, 1:59 PM
#10
merlinpa1969 avatar

merlinpa1969

Totally Zenned

Join Date:
Mar 2004
Posts:
13,031
Plugin Contributions:
4

Re: SSL issues

there are other lines that look like that,
they are all server paths,
they wont all have cache at the end.
lol
this is the trouble with this kind of setup, it is confusing and a pain in the ......... to maintain

Zen cart PCI compliant Hosting

3 Aug 2006, 9:43 PM
#11
dante2010 avatar

dante2010

New Zenner

Join Date:
Jun 2006
Posts:
28
Plugin Contributions:
0

Re: SSL issues

Yes I see why this method is a pain in the butt.. but unfortunatly I think i will need to be stuck with it.

So I changed all the other absolute paths in my 2 configure.php files on the secure server. I am still getting the same error tho.

Do I need to have the /zc_install dir on the secure side? I ask because I initally didn't upload it because you remove it after installation, but the error I was getting was because it couldn't find that dir at all. Should I remove the /zc_install dir from the secure side?

3 Aug 2006, 9:47 PM
#12
merlinpa1969 avatar

merlinpa1969

Totally Zenned

Join Date:
Mar 2004
Posts:
13,031
Plugin Contributions:
4

Re: SSL issues

do you have access to a different database?
if so upload the installer,
run the installer
and then change the database information in the secure server

Zen cart PCI compliant Hosting

3 Aug 2006, 9:50 PM
#13
dante2010 avatar

dante2010

New Zenner

Join Date:
Jun 2006
Posts:
28
Plugin Contributions:
0

Re: SSL issues

Ok well I deleted teh /zc_install dir and I got rid of that pesky errror.

Now I am getting the following screen:

http://factoryshoe.ianarmstrong.com/store2/nddbc.html

.. which I assume means it can't get a connection from the secure server to the DB on my regular server ?

3 Aug 2006, 11:12 PM
#14
merlinpa1969 avatar

merlinpa1969

Totally Zenned

Join Date:
Mar 2004
Posts:
13,031
Plugin Contributions:
4

Re: SSL issues

you will have to make sure that you use the actual server address for the database in the config files rather than localhost, ( since it is on a seperate server )

I know that you are much more patient than me.
I think I would scrap the $7 or $10 bux I paid and head to where the grass is green and the servers are actually setup to be usable....

Zen cart PCI compliant Hosting

4 Aug 2006, 3:54 AM
#15
dante2010 avatar

dante2010

New Zenner

Join Date:
Jun 2006
Posts:
28
Plugin Contributions:
0

Re: SSL issues

Well it's not a matter of me moving to where the grass is greener. It's being setup for a client and they are adamant with staying on the server they are currently with. I might be able to get them to buy their own SSL cert so I don't have to go through all this mess.. but until I know for sure I need to get as much done as possible.

So I was messing around some more and set the "define('ENABLE_SSL', 'TRUE');" back to false so I could play around with the order process. Problem is, now when I set them back to TRUE I am never redirected to the secure server. Should it not redirect right before the stage where you are prompted to enter credit card info??

4 Aug 2006, 4:01 AM
#16
merlinpa1969 avatar

merlinpa1969

Totally Zenned

Join Date:
Mar 2004
Posts:
13,031
Plugin Contributions:
4

Re: SSL issues

you should be directed to the https during create account,
login
any page that has checkout or account in it

Zen cart PCI compliant Hosting

5 Aug 2006, 2:44 AM
#17
dante2010 avatar

dante2010

New Zenner

Join Date:
Jun 2006
Posts:
28
Plugin Contributions:
0

Re: SSL issues

Well I do not know what I screwed up then. I've changed back all the define('ENABLE_SSL', 'TRUE'); lines to true on my non secure server. Yet it will not direct me to the secure server at any point during the transaction process.

5 Aug 2006, 6:17 AM
#18
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,511
Plugin Contributions:
176

Re: SSL issues

'TRUE' should be 'true'

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

13 Aug 2006, 2:54 PM
#19
theodin avatar

theodin

New Zenner

Join Date:
Sep 2005
Posts:
26
Plugin Contributions:
0

Re: SSL issues

Merlinpa,

When you said, "you should be directed to the https during create account, login, and any page that has checkout or account in it" does that mean it will revert back to http and lose the logged on status?

My symptoms are that the https switches off as you state, but then, the login box re-appears to the left of the page. This is despite being able to click a link to "my account" (ie /store/index.php?main_page=account) subsequently being immediately returned to the logged in state without having to log on again. I originally thought this was a bug, as i expected to stay in my SSL session for the remainder of my time browsing the shop.

I'm going to have a crack at editing Linda McGraths login box sidebox contribution to determine if the user is actually logged on, and then maybe display the appropriate things.

If anyone has anything interesting please advise, otherwise i'll post my code if i have any success.

Note: Try adding something to your cart, then browsing for more items afterwards. The navigation bar at the top then displays, "Home, Log In, Shopping Cart, Checkout" despite still being logged in from earlier in my session.

Thanks!!

13 Aug 2006, 6:54 PM
#20
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,511
Plugin Contributions:
176

Re: SSL issues

theodin:

My symptoms are that the https switches off as you state, but then, the login box re-appears to the left of the page. This is despite being able to click a link to "my account" (ie /store/index.php?main_page=account) subsequently being immediately returned to the logged in state without having to log on again. I originally thought this was a bug, as i expected to stay in my SSL session for the remainder of my time browsing the shop.

Note: Try adding something to your cart, then browsing for more items afterwards. The navigation bar at the top then displays, "Home, Log In, Shopping Cart, Checkout" despite still being logged in from earlier in my session.
theodin,
These symptoms are NOT typical of a working Zen Cart shop.
There is something odd with your configuration which is causing this.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.