Results 1 to 8 of 8
  1. #1
    Join Date
    Sep 2013
    Location
    Texas
    Posts
    304
    Plugin Contributions
    0

    Default [Not a ZC bug] Problems using '3 AND 4' comments during checkout

    Existing installation & Fresh OUT OF THE BOX install.
    Buy and item and at step "Step 1 of 3 - Delivery Information" in the "Special Instructions or Comments About Your Order" box enter any 2 numeric values with an "and" or "or" between them, click continue "Check Out" and you get this catastrophic failure.

    Forbidden
    You don't have permission to access /zctest/index.php on this server.
    Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

    EXAMPLE entries:
    3 and 4
    7 or 9

    You may test at this site:
    www.pcsnnets.com/zctest

    Name:  fail 01.jpg
Views: 119
Size:  93.3 KB

    Thanks, Linuxguy2
    Last edited by linuxguy2; 1 Aug 2015 at 03:43 AM. Reason: Typo

  2. #2
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: Step 1 of 3 - Delivery Information

    That's not a Zen Cart bug. It's mod_security (or other security rules) your hosting company has enabled in Apache to filter out common malicious SQL injection attempts.

    If you want to prevent that from triggering, work with your hosting company to customize the rules specific to your site.
    .

    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.

  3. #3
    Join Date
    Sep 2013
    Location
    Texas
    Posts
    304
    Plugin Contributions
    0

    Default Re: [Not a ZC bug] Step 1 of 3 - Delivery Information

    Hi,

    Can you explain to me why does it ONLY fail if I enter "3 and 4" but if I enter "3and4" it accepts the entry?
    Do not enter the "

    It also fails when making entries on the next checkout pages

    Have you tested it?
    I'm not sure my why but it looks like my site is down for the moment.
    Please try this on ANY 1.5.1 site and I believe it will fail.
    Last edited by linuxguy2; 1 Aug 2015 at 04:08 AM. Reason: Additional info

  4. #4
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: [Not a ZC bug] Step 1 of 3 - Delivery Information

    Because "3and4" does not contain any SQL keywords like "AND" or "OR" with spaces around them to make them actual keywords.
    .

    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.

  5. #5
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: [Not a ZC bug] Step 1 of 3 - Delivery Information

    The problem doesn't happen if mod_security isn't installed. (or any equivalent trapping tool)
    .

    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.

  6. #6
    Join Date
    Sep 2013
    Location
    Texas
    Posts
    304
    Plugin Contributions
    0

    Default Re: [Not a ZC bug] Step 1 of 3 - Delivery Information

    Thanks, I did not make the connection between the failure and SQL keywords AND OR.
    I just figured it was a mathematical operator of some kind.
    This thing has been driving me nuts for two days.

    THANK YOU!

  7. #7
    Join Date
    Sep 2013
    Location
    Texas
    Posts
    304
    Plugin Contributions
    0

    Default Re: [Not a ZC bug] Step 1 of 3 - Delivery Information

    I hate to be a nag about this but this makes no sense. I'm sure my Hosting provider isn't the only one with mod_security enabled.
    People enter numbers with the words AND or OR between them in comment boxes all the time.
    Is it possible ZC could do something to prevent this?

  8. #8
    Join Date
    Sep 2013
    Location
    Texas
    Posts
    304
    Plugin Contributions
    0

    Default Re: [Not a ZC bug] Step 1 of 3 - Delivery Information

    My hosting provider (Host Tornado) allows each domain to control their mod_security setting.
    Meanwhile I was thinking:
    To allow mod_security to be turned on one could parse the comments field and in my case add a . before commonly used SQL keywords words ( and or ) when used between numeric values and no one would be the wiser.
    Do you know if there is there a way to do this with an .htaccess file to allow just (and or) to pass thru when used between numeric values?

    Beings you don't consider this to be a bug do you think this thread should be moved to some other category?
    I'd like to see how others have dealt with this issue.


    Thanks for your time
    Last edited by linuxguy2; 2 Aug 2015 at 02:30 PM. Reason: correction

 

 

Similar Threads

  1. v151 Problems with Checkout when using Paypal and Cheques/Money Orders
    By elvisstuff in forum General Questions
    Replies: 6
    Last Post: 8 Jul 2013, 06:16 AM
  2. Switching languages during checkout bug?
    By Lagrange in forum Addon Language Packs
    Replies: 0
    Last Post: 8 Jul 2008, 08:49 PM
  3. Problems during checkout
    By artanius in forum Managing Customers and Orders
    Replies: 6
    Last Post: 21 Apr 2008, 11:34 AM
  4. 'comments' not being passed to next page during checkout
    By warstormer in forum General Questions
    Replies: 10
    Last Post: 4 Oct 2007, 11:52 AM
  5. Replies: 1
    Last Post: 2 Oct 2007, 06:38 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