Questions tagged [flask-oauthlib]
77 questions
1
vote
1 answer
401 Client Error: Unauthorized url. Flask python
I have a program that Authenticate with API and when logged in search by Id in contacts on this API.
logging in works fine but when I try to find contact this error happen:
401 Client Error: Unauthorized for…

Mahmoud Ferig
- 55
- 6
1
vote
1 answer
OIDC Provider Flask. Password Credentials Grant
Does anybody know wether authlib python library support the Resource Owner Password Credentials Grant flow for Flask OIDC Provider?
In the documentation only appear Code, Implicit and Hybrid…

Ignasi Mañé
- 43
- 1
- 10
1
vote
1 answer
A post call to add a new openTypeExtension to user data fails with "Resource not found for the segment 'extensions'"
I've modified sample_flask.py by adding a new action to the graphcall function. The new MSGRAPH.post call should create an openTypeExtension to the user. The code is as follows:
endpoint = 'me/extensions'
data = {
"@odata.type":…

L. Batavan
- 23
- 4
1
vote
3 answers
How to implement validate_redirect_uri in Grant class?
I am trying to implement a Oauth2 provider server in Python from https://github.com/lepture/flask-oauthlib/tree/master/tests/oauth2/server.py code base but stuck when trying to do some redirect uri validation customization for the Oauth2 grant…

Michael Zhou
- 11
- 2
1
vote
1 answer
Retrieve the organization name from Admin Directory API
I'm using https://flask-oauthlib.readthedocs.io/en/latest/ to deal with Google OAuth API. I'm able to connect and retrieve user data. But still facing issue to get user organization name.
According to the documentation…

Ali SAID OMAR
- 6,404
- 8
- 39
- 56
1
vote
0 answers
ERROR:flask_oidc: ERROR: Unable to get token info - ERROR:flask_oidc:'token_introspection_uri'
I have a Flask rest api that I'm calling from a Javascript client.
Trying to integrate Keycloak as an authentication server I had no success with flask (using flask_oidc) so I went for authenticating first from the javascript client (which works),…

magnoz
- 1,939
- 5
- 22
- 42
1
vote
0 answers
How to verify access_token for trusted resource server?
I have Authorization server and Resource server... When the client sends a request to the Resource server, my Resource server must send a request to the Authorization server to verify token that it's still valid.
But how to verify it using Authlib?…

Denis Sologub
- 7,277
- 11
- 56
- 123
1
vote
1 answer
Python oauth/flask, how to pass arguments from decorated function
I need to call the method of @oauth.token_handler internally from flask.
The signature is as follow:
@oauth.token_handler
def access_token(*args, **kwargs):
return None
So it calls internally the implementation of token_handler().
I try to…

Mr Bonjour
- 3,330
- 2
- 23
- 46
1
vote
1 answer
Flask authenticate with Sharepoint Online
I am trying to write a web service which uses some data from a Sharepoint Online site using the flask_oauthlib module.
I've set it up like this:
from flask import Flask, session
from . import settings
app =…

Tom
- 7,269
- 1
- 42
- 69
1
vote
1 answer
Error when accessing Google OAuth from Docker container : device_id and device_name are required for private IP
I have a dockerized flask app running from a docker-machine with IP 192.168.99.100 that is trying to access Google OAuth. However, I am getting the following error:
Error: invalid_request
device_id and device_name are required for private IP:
…

Ron
- 137
- 1
- 9
1
vote
1 answer
How to use flask-oauthlib with flask-login together?
For now, I'm trying to use flask-oauthlib with flask-login together.
flask-oauthlib provides a simple way to use oauth, but I want a login manager to automatically redirect all users who are not logged in to /login. In flask-login, I can use…

Sraw
- 18,892
- 11
- 54
- 87
1
vote
1 answer
Flask-oathlib: how to revoke a token
Reading the google docs (https://developers.google.com/identity/protocols/OAuth2WebServer#callinganapi), it says i can revoke token (and thus force a login with credentials) by calling credentials.revoke.
What would be the flask-oathlib way to do…

Sapsi
- 711
- 5
- 16
1
vote
0 answers
Flask-OAuthlib to implement OAuth implicit flow
Is it feasible to implement oauth provider implicit flow using Flask-OAuthlib?
I have been trying this for more than a week now. I can't share codes because of some internal company policy.
My issue is OAuthlib has everything predefined: from what…

gsverma
- 11
- 4
1
vote
1 answer
session disappears when request is sent from fetch
I'm trying to use Gmail API to access emails with Flask-Authlib. after user authorization, the server will put a access token in session, then it will direct to a react route /test. in the react component invoked by /test, it will send a GET request…

shangsunset
- 1,585
- 4
- 22
- 38
1
vote
1 answer
Flask-Dance Error: Scope has changed
I am using flask-dance to authenticate to Google's servers.
Config for flask-dance:
from flask.ext.dance.contrib.google import make_google_blueprint
google_blueprint = make_google_blueprint (
client_id=app.config['GOOGLE']['client_id'],
…

flamusdiu
- 1,722
- 2
- 14
- 31