Closed BorjaEst closed 10 months ago
For those wondering why this behavior, it looks like this behavior is due to the lack of token. If you try the following it passes:
$ curl -H "Authorization: Bearer random_string" localhost:5000/info
No userinfo
Note that random_string
is an actual RANDOM string, not intended to be a token. The validation is disabled so the authentication pass.
Now the question is if this is the desired behavior (where I am out of topic so I am closing the issue).
Works thanks to #75
See the following code example with flask (but probably extensible to all frameworks).
Then if you
GET
the endpoint info:It shows the error was raised and we get
Unauthenticated
where acording to the docs it should return the defined response ("No userinfo" in this case).