human
What is a the Python program you requested given the following:
Complete the below
def auth_basic(check, realm='private', text='Access    denied'):

    ''''Callback decorator to require HTTP auth (basic).
    TODO: Add route(check_auth=...) parameter.'
    '''
assistant
#Here is the Python program you requested.
    def decorator(func):
        def wrapper(*a, **ka):
            (user, password) = (request.auth or (None, None))
            if ((user is None) or (not check(user, password))):
                response.headers['WWW-Authenticate'] = ('Basic    realm="%s"' % realm)
                return HTTPError(401, text)
            return func(*a, **ka)
        return wrapper
    return decorator