Fixed major security flaws and added a minimum passwd length