def request_authenticate(request, username, password):
 request.headers['Authorization'] = basic_auth_header(username, password)

def request_authenticate ( request , username , password ) : request . headers [ 'Authorization' ] = basic_auth_header ( username , password )
autenticate the given request using the http basic access authentication mechanism and the given username and password .