Results 1 to 4 of 4
  1. #1
    Join Date
    May 2008
    Location
    South Australia
    Posts
    86
    Plugin Contributions
    1

    red flag easy spam exploitation of "tell a friend" feature?

    Ok, firstly i love the cart and have been a fan and developer of it for some time.

    Problem: disabling "tell a friend" from the admin section merely hides the buttons to access the form.

    anyone with the most basic understanding of zencart and url's can easily find or have bookmarked the url to access it:

    index.php?main_page=tell_a_friend&products_id=57

    so there was no way for me to stop a spammer who had been using scripting to send 1000's of email a day through my customers site via this function/form but to,

    Quick fix: edit the modules header php file to throw error always, and comment out modules template html.

    Proper fix:
    make the setting in the admin section which hides the buttons/sideboxes to access the forms actually disable the function/form which sends the emails.

    thanks guys,

    Hayden.

  2. #2
    Join Date
    Jan 2004
    Posts
    66,443
    Plugin Contributions
    279

    Default Re: easy spam exploitation of "tell a friend" feature !!

    In the meantime, v1.3.9 introduced throttling to minimize the ability to "send 1000's of email a day".
    .

    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
    Mar 2010
    Location
    UK
    Posts
    445
    Plugin Contributions
    0

    Default Re: easy spam exploitation of "tell a friend" feature !!

    I am going to take a look to see if there is a simple way to alter the script so that the function when disabled in Admin can return a proper HTTP/1.1 404 Not Found header and error message on any and all access attempts.

    For the moment, a simple .htacess fix can be implemented using:
    Code:
    # ErrorDocument 404
    ErrorDocument 404 /index.php?main_page=page_not_found
    
    # Rewrite requests for 'tell a friend' to a non-existent internal path
    # The rewrite triggers Apache to send a 404 header and 404 error page.
    RewriteCond %{QUERY_STRING} main_page=tell_a_friend
    RewriteRule ^(index.php)?$ /path-does-not-exist [L]
    Rewrites must always be listed after any and all redirects.

  4. #4
    Join Date
    Jan 2004
    Posts
    66,443
    Plugin Contributions
    279

    Default Re: easy spam exploitation of "tell a friend" feature !!

    If you just delete or rename the /includes/modules/pages/tell_a_friend/ folder, that will automatically trigger the built-in Not-Found functionality, which will redirect to the main_page=page_not_found if you've got it configured to do that in Admin->Configuration->My Store.
    No need to touch .htaccess
    .

    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. How to remove the "tell a friend" feature ?
    By athooya in forum General Questions
    Replies: 4
    Last Post: 20 Apr 2010, 01:19 PM
  2. Replies: 2
    Last Post: 11 Feb 2010, 09:13 PM
  3. Modify "add to cart" "write a review" "tell a friend"
    By Marlake in forum Templates, Stylesheets, Page Layout
    Replies: 18
    Last Post: 10 May 2008, 12:05 PM

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