'The userid parsed from the ``Authorization`` request header.'

def unauthenticated_userid(self, request):

    credentials = extract_http_basic_credentials(request)
    if credentials:
        return credentials.username
