lib/algorithms/hashing_algs.py
def sha3_384(string, salt=None, front=False, back=False, **placeholder):
    """
      Create a SHA3 384 hash from a given string

      > :param string: string to hash
      > :return: SHA3 384 hash

      Example:
        >>> sha3_384("test")
        e516dabb23b6e30026863543282780a3ae0dccf05551cf0295178d7ff0f1b41eecb9db3ff219007c4e097260d58621bd
    """
    if type(string) is unicode:
        string = lib.settings.force_encoding(string)
    obj = sha3.sha3_384()
    if salt is not None and front and not back:
        obj.update(salt + string)
    elif salt is not None and back and not front:
        obj.update(string + salt)
    else:
        obj.update(string)
    return obj.hexdigest()

      Create a SHA3 384 hash from a given string

      > :param string: string to hash
      > :return: SHA3 384 hash

      Example:
        >>> sha3_384("test")
        e516dabb23b6e30026863543282780a3ae0dccf05551cf0295178d7ff0f1b41eecb9db3ff219007c4e097260d58621bd
    
Create a SHA3 384 hash from a given string
> :param string: string to hash
> :return: SHA3 384 hash
Create a SHA3 384 hash from a given string > : param string : string to hash > : return : SHA3 384 hash
def sha3_384(string, salt=None, front=False, back=False, **placeholder):
    if type(string) is unicode:
        string = lib.settings.force_encoding(string)
    obj = sha3.sha3_384()
    if salt is not None and front and not back:
        obj.update(salt + string)
    elif salt is not None and back and not front:
        obj.update(string + salt)
    else:
        obj.update(string)
    return obj.hexdigest()
def sha3_384 ( string , salt = None , front = False , back = False , ** placeholder ) : if type ( string ) is unicode : string = lib . settings . force_encoding ( string ) obj = sha3 . sha3_384 ( ) if salt is not None and front and not back : obj . update ( salt + string ) elif salt is not None and back and not front : obj . update ( string + salt ) else : obj . update ( string ) return obj . hexdigest ( )
Create a SHA3 384 hash from a given string
> :param string: string to hash
> :return: SHA3 384 hash
Create a SHA3 384 hash from a given string > : param string : string to hash > : return : SHA3 384 hash
"""
      Create a SHA3 384 hash from a given string

      > :param string: string to hash
      > :return: SHA3 384 hash

      Example:
        >>> sha3_384("test")
        e516dabb23b6e30026863543282780a3ae0dccf05551cf0295178d7ff0f1b41eecb9db3ff219007c4e097260d58621bd
    """
string
salt
front
back
examples
None