Return the given hash, with only the first ``show`` number shown. The
    rest are masked with ``char`` for security reasons.

def mask_hash(hash, show=6, char="*"):
    """
    Return the given hash, with only the first ``show`` number shown. The
    rest are masked with ``char`` for security reasons.
    """
    masked = hash[:show]
    masked += char * len(hash[show:])
    return masked