Hi I'm doing site where unregistred people will vote on subjects. How to protect site from multiple votes from same user for same topic ? And how to check if someone votes for too much subjects (robots vote)? Site is in PHP and MySQL on shared hosting.
Create a table called rate_log and record the topic id and the users IP and you can just check against that.
Yes, I would do that, except that I would use a cookie too where possible because IP addresses change all the time...
Dont do it against IP, as then if more than one person from the same building [think university] try to vote it wont let them. Use cookies and make sure they have a referrer [to protect against bots]. And perhaps ensure that votes from the same IP are throttled so you can only vote once per hour from the same IP
If someone is hosted by for exampl AOL their ip changes with every request. If you have a HTML page with 10 images and a style sheet that is a total of 12 items. An AOL user could end up requesting each item with a different IP.
Do it with cookies and check against their IP, and if a referrer is supposed to be set, then do that as well.