Page 1 of 2 12 LastLast
Results 1 to 10 of 13

Thread: prevent csv entries from same IP?

  1. #1
    Join Date
    Jan 2009
    Posts
    3

    Default prevent csv entries from same IP?

    Hello,

    I like to use formmail with it's csv-file feature for online polls.
    Now I thought it would be useful to prevent multiple entries in the csv-file from the same IP address.

    Is this possible with formmail?

    I tought I read something about ip-check somewhere in the forum but I cannot find it anymore.

    TIA,
    masa

  2. #2
    Join Date
    Jul 2007
    Posts
    15

    Default Re: prevent csv entries from same IP?

    I am interested in this too! Can anyone help?? Thanks.

  3. #3
    Join Date
    Mar 2004
    Posts
    2,224

    Default Re: prevent csv entries from same IP?

    u can do this formmail's conditions feature

    to be effective u need to put the conditions in an INI file

    so, get it working first using just ur html form, and then move the conditions into an INI file using the how to guide (http://www.tectite.com/fmhowto/inifile.php)

    first, u derive a field to contain the users IP address (See http://www.tectite.com/fmhowto/derived.php):
    HTML Code:
    <input type="hidden" name="derive_fields" value="ipaddr = REMOTE_ADDR" />
    then u can check it against an ip address:

    HTML Code:
    <input type="hidden" name="conditions1" value="
     :@
     @TEST@ipaddr !~ /^123\.456\.789\.123$/@IP Blocked@" />
    and for multiple ip addrs:

    HTML Code:
    <input type="hidden" name="conditions1" value="
     :@
     @TEST@ipaddr !~ /^123\.456\.789\.123$/@IP Blocked@:
     @TEST@ipaddr !~ /^62\.34\.212\.46$/@IP Blocked@:
     @TEST@ipaddr !~ /^65\.32\.12\.198$/@IP Blocked@:
     " />
    and so on

  4. #4
    Join Date
    Feb 2007
    Posts
    162

    Default Re: prevent csv entries from same IP?

    Not just with this formmail script, but for any script, it's really never a good idea to rely on the IP address to limit a user. IP addresses can be spoofed, and can change as often as per each request (such as AOL users). Generating a new IP address for most people is as easy as unplugging their router for a few minutes.

    Your application may not be so critical, but if it is, you will most likely need to require users to authenticate.

  5. #5
    Join Date
    Mar 2004
    Posts
    2,224

    Default Re: prevent csv entries from same IP?

    Not just with this formmail script, but for any script, it's really never a good idea to rely on the IP address to limit a user.
    belgirl & masa: listen to this - chmod000 is right!

  6. #6
    Join Date
    Jul 2007
    Posts
    15

    Default Re: prevent csv entries from same IP?

    Thanks for the input. Sorry if this has already been asked, but what would be the best way to authenticate for Formmail?

  7. #7
    Join Date
    Mar 2004
    Posts
    2,224

    Default Re: prevent csv entries from same IP?

    hey chmod000:

    IP addresses can be spoofed
    i dont think they can be - the ip address (REMOTE_ADDR) is obtained from the tcp conntion of the client

    so, its always the real ip address

    wot did u mean?

  8. #8
    Join Date
    Mar 2004
    Posts
    2,224

    Default Re: prevent csv entries from same IP?

    Quote Originally Posted by belgirl View Post
    Thanks for the input. Sorry if this has already been asked, but what would be the best way to authenticate for Formmail?
    wot do u mean "authenticate for Formmail"?

  9. #9
    Join Date
    Jul 2007
    Posts
    15

    Default Re: prevent csv entries from same IP?

    Well CHMOD000 stated "Your application may not be so critical, but if it is, you will most likely need to require users to authenticate."

    I was wondering what was meant by that....?

  10. #10
    Join Date
    Mar 2004
    Posts
    2,224

    Default Re: prevent csv entries from same IP?

    chmod probly will reply, but i think he/she was talking in a general sense

    u could, for example, use ur web server to prevent access to ur forms(using .htaccess) except for certain people

    but that only makes sense if u have a fixed or known community of users

    if u have a general form on ur website then u want anyone to be able to fill it in...so authetnication doesnt make sense here

    since u want to block ip addresses, i guess ur looking for spam protection, right?

    well tectite's formmail has a lot of protection built in.

    u should check out the ATTACK_DETECTION settings here:
    http://www.tectite.com/fmdoc/index.php

    and they also have a new info page here:
    http://www.tectite.com/formmailantispam.php

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Is there a way of banning IP adresses?
    By Hawkslayer in forum Community Support
    Replies: 12
    Last Post: 02-Jan-2007, 02:04 PM
  2. Using Image Verification to prevent spam - no autoresponder required
    By info@marcel.co.za in forum Community Support
    Replies: 2
    Last Post: 28-Jun-2006, 05:20 AM
  3. Can prevent fmbadhandler from appending...
    By CWD in forum FormMail Subscription Support
    Replies: 1
    Last Post: 27-Jul-2005, 05:22 AM
  4. How to show remote Host and IP on html form
    By James in forum FormMail Subscription Support
    Replies: 2
    Last Post: 19-Jun-2005, 10:45 AM
  5. Store IP in CSV
    By JohnB in forum FormMail Subscription Support
    Replies: 50
    Last Post: 22-Feb-2005, 11:15 PM

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
  •