Password policy check improvement