Return a tuple (message signature, HTTP header message signature).

def http_signature(message, key_id, signature):
    """Return a tuple (message signature, HTTP header message signature)."""
    template = ('Signature keyId="%(keyId)s",algorithm="hmac-sha256",'
                'headers="%(headers)s",signature="%(signature)s"')
    headers = ['(request-target)', 'host', 'accept', 'date']
    return template % {
        'keyId': key_id,
        'signature': signature,
        'headers': ' '.join(headers),
    }