import hashlib


def get_sha1_file( filename ):
    """
    This module generates sha1sum for the given file
    Args:
        filename (str): Full path to the file
    Returns:
        sha1sum hash of the file
    """
    hash_size = 256
    sha1 = hashlib.sha1()
    with open( filename, 'rb' ) as f:
        while True:
            data = f.read( hash_size )
            if not data:
                break
            sha1.update( data )
    return "0x" + sha1.hexdigest()