def password_data(username, password):
 return {'username': username, 'password': hashlib.sha1(password.encode('utf-8')).hexdigest(), 'passwordMd5': hashlib.md5(password.encode('utf-8')).hexdigest()}

def password_data ( username , password ) : return { 'username' : username , 'password' : hashlib . sha1 ( password . encode ( 'utf-8' ) ) . hexdigest ( ) , 'passwordMd5' : hashlib . md5 ( password . encode ( 'utf-8' ) ) . hexdigest ( ) }
returns a dict with username and its encoded password .