Added password generating function