New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
jwt.exceptions.DecodeError: Not enough segments #405
Comments
having the same issue. did you ever figure out out? |
Any chance we can get a full reproduction? |
I had a similar issue and I realised that the jwt token wasn't being added as part of the request header. If you are using postman to make the requests, you could check if you are typing the token into the value section and not description. |
I'm having the same issue! ;-( |
Here some answer related to my problem: https://stackoverflow.com/questions/61436054/not-enough-segments-when-seding-a-get-message-with-bearer-token-authorization/61450588#61450588 |
It's been a while since we solved this problem. I'll need to go back a take a look at the source, but if I remember correctly it had something to do with the jwt not being correctly formatted. I'll post a more in-depth answer when I have time. |
pls get back to us on this. i'm having the same problem. |
The problem is stated here and determines that Flask-JWT-extended requires a custom decorator. You just need to use a previous version and it will work without the decorator. |
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days |
The new version of If you are using the latest version of |
Problem description
pyjwt yields said error message when trying to decode an RS256-decoded ID token returned from our OIDC/Oauth token endpoint.
The signed JWT token is encoded using the following header/body:
The token is then submitted to the token endpoint with the following payload:
Trying to decode the returned ID token with the code shown bellow triggers an exception within pyjwt.
Further notes
Trying to decode the ID token at jwt.io yields the expected outcome, and the ID token consists of three elements. Therefore I'm curious as to why pyjwt complains about there not being enough elements.
Any tips and pointers in the right direction would be much appreciated!
The text was updated successfully, but these errors were encountered: