jeudi 26 février 2015

Acceptably secure solution for users to log in with a short unique code only (no username)



I am creating a website whereby users are given an account by invitation only, and are sent a unique code by post. Users can then log in (at least the first time) by entering the code only.


The goal of this is for it to be extremely easy to understand and use by non tech-savvy people.




  • User accounts will contain name, email, maybe address if the user wants to add it. No other sensitive information.




  • The site itself would not be of interest to anyone other than those invited, and will not be indexed by search engines.




If you imagine the users are receiving a piece of mail in the post which says something along the lines of:



Please visit www.example.com
Log in with your unique code:

A6XH3


As for the code, it must be extremely easy to remember and enter.




  • I was planning four or five upper case alphanumeric characters - e.g. A6XH3 - because I don't want anyone to have to enter a long hash or complicated string. I think 6 characters is the limit that I would deem acceptable for people to enter in this format.




  • An alternative idea I had was to use two/three easy to spell words, such as [adjective] [noun] which would be more fun and seem less "techy" to the users - e.g. pretty blue flower - which would be more in keeping with the spirit of the site.




Caveat


Website administrators must be able to see all the users' codes in plain text, so they can mail them out in the first place and/or offer support to anyone unable to log in. They may also need to generate a new code for some reason, and tell the person directly.


Questions




  1. Is this secure enough for the context? i.e. The only people who know about the site are those invited, and there is no real motive for anyone else to try to force their way in.




  2. Would you use either of my methods of unique code generation, and if not what would you suggest as a better solution?




  3. Is there another way I could allow a simple login without compromising security or simplicity of use without a username?




Note: I am using PHP/MySQL if it is relevant.





Aucun commentaire:

Enregistrer un commentaire