Regular expression added for to check valid password. Password generator
is corrected for all combination of passwords. imports are organized.

Signed-off-by: Sanjay Madnani <http://sanjaymadnani.wordpress.com/>