Comments (1)
Hello, I'm going to close this issue, as I found a workaround that would combine this library with charmander
without needing to change any library. Here there is the code that I used. The trick was to change the backend, from Signed JWT backends/jws
to backends/token
. That way, the backend doesn't try to verify the signature itself, but gives the opportunity to add a function to the the authentication:
(defn my-authfn
[request token]
(log/trace
(second
(re-find (re-pattern (str "^" "Token" " (.+)$"))
(http/-get-header request "authorization"))))
(log/trace (:uid (charm/validate-token "<YOUR-PROJECT-HERE>" token)))
(:uid (charm/validate-token "<YOUR-PROJECT-HERE>" token)))
(def backend
(backends/token
{:authfn my-authfn}))
In case it could help anybody, do not use https://github.com/magnetcoop/buddy-auth.jwt-oidc library: It might seem that it works, as it allows you to add a URI where to download a JWKS file but firebase's https://www.googleapis.com/robot/v1/metadata/x509/[email protected] file is not in that format. It took me a lot of time and debug to find out why it wasn't working, but at least it gave me the clue on how to get to this workaround that is actually working.
from buddy-auth.
Related Issues (20)
- Wording, spelling, grammar HOT 6
- Rate Limiting? HOT 1
- Not possible to modify content-type? HOT 1
- Allow for successful authorization of requests that already contain :identity HOT 1
- Document available options HOT 2
- Default token name for JWS should be Bearer? HOT 2
- Adding a transformation function to jwt/jws backends. HOT 1
- "No implementation of method: :-to-bytes of protocol:" error using jws-backend with RSA key HOT 8
- Bad Request and 'missing-required-key' in response with JWS-backend, RSA key HOT 3
- Able to skip auth for OPTIONS requests? HOT 1
- Delay the decision of which secret to use HOT 2
- http-basic doc need amending HOT 1
- Support async handlers HOT 5
- Regarding fn->multi macro HOT 5
- buddy.auth.backends.token/handle-unauthorized-default violates RFC 7235 section 4.1. WWW-Authenticate
- Authorization: Bearer XXX as well a Token? HOT 1
- Authorization scheme for HTTP Basic Authentication should be case insensitive
- wrap-authorization ignores 'raised' unauthorized exceptions in async mode
- New maintaner HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from buddy-auth.