node.js - how to "dont vote twice" mechanism -
i thinking of creating voting app. general idea
- browse gallery
- an awesome pic grabs attention
- hit vote button underneath it
- code magic happens
- vote counted
- at date, vote buttons become non-active , app counts votes
this web app, means html5-css3-express.js-redis framework, or similar.
how can ensure user cannot vote same pic twice? making him sign up? huge procedure voting app, dont think? plus, guess need captcha
thing avoid unwanted, mass sign up.
but if use coockies of html5 local storage api, stopping same user clear his/her coockies , vote same pic again , again?
what best method?
thanks alot
the secure way using accounts keep track of has voted. accounts easy implement in application , don't need hold account data if use service passport.js. you'll have database set makes easy keep account data well.
the other method keep track of ip addresses has issues (say, if user uses proxy). ip address cover clients on network means if 1 person votes on image, others unable afterwards.
Comments
Post a Comment