import hmac
import hashlib


def generate_hash(secret, message):
    """Generate a hash given a secret and a message.

    Parameters
    ----------
    secret: string
        The secret to use.

    message: string
        The message to hash.

    Return
    ------
    String
       Return a computed hash
    """
    return hmac.new(
        secret.encode("utf-8"), msg=message, digestmod=hashlib.sha256
    ).hexdigest()