Home >Backend Development >PHP Tutorial >Analysis of the Principle of Preventing Repeated Voting in PHP_PHP Tutorial
At the beginning, I used the verification code, but others manually swiped the tickets, and even the website spent hundreds of dollars to buy a verification code recognition program
Restrict the IP address and change the IP by unplugging and plugging the network cable. You can buy an automatic IP changer for 2 yuan on Taobao and automatically dial up again to access the Internet
cookies? Just clean it up
session? The page is disconnected when it is closed
mac address? You can change it in the device manager
User hard drive serial number? Use software to cheat
Only registered users can vote? Unless you have many registered users
Hard to guard against. . .
Recommend ip+verification code+session
Verification codes can be fun
Netizen 2
The following is a method I used on a voting website to prevent vote fraud, but it was still being spammed
Verification code (I don’t know how his ticket machine broke through this level)
session verification (don’t know yet)
Generate random number
IP verification (can be disguised)
Voting source (can be disguised)
Make the verification code Chinese, or a random number, and let it do calculations, etc. This should be able to prevent the machine. If the machine cannot prevent it, then there is something wrong with your code
Final summary:
The problem of ticket swiping has always existed. We can only try to minimize the ways to swipe tickets. It is impossible to prevent others from swiping tickets. Even if you add registration, people can register n numbers! If you think about it, even if it is a real vote, there will still be vote-pulling. To prevent others from swiping votes, you have to control the voting crowd!