(password, uppercase=True)
return retVal.upper() if uppercase else retVal.lower()
Reference(s):
        http://csl.sublevel3.org/mysql-password-function/

    >>> mysql_passwd(password='testpass', uppercase=True)
    '*00E247AC5F9AF26AE0194B41E1E769DEE1429A29'
Reference(s):
        http://csl.sublevel3.org/mysql-password-function/
Reference ( s ) : http : // csl . sublevel3 . org / mysql - password - function /
def mysql_passwd(password, uppercase=True):
    """
    Reference(s):
        http://csl.sublevel3.org/mysql-password-function/

    >>> mysql_passwd(password='testpass', uppercase=True)
    '*00E247AC5F9AF26AE0194B41E1E769DEE1429A29'
    """

    retVal = "*%s" % sha1(sha1(password).digest()).hexdigest()

    return retVal.upper() if uppercase else retVal.lower()
def mysql_passwd ( password , uppercase = True ) : retVal = "*%s" % sha1 ( sha1 ( password ) . digest ( ) ) . hexdigest ( ) return retVal . upper ( ) if uppercase else retVal . lower ( )