def getCurrentUser(request): auth = request.authorization if not auth: return None token = auth.username return User.verify_auth_token(token)