Git Product home page Git Product logo

Comments (9)

AnthonyDeroche avatar AnthonyDeroche commented on May 20, 2024

Hello,

The token should be correctly decoded if you transform the public exponent "n" of your jwks into a valid PEM RSA public key. To validate signature, I'm using libjwt (https://github.com/benmcollins/libjwt) using itself openssl.

Can you give me public keys in PEM format used to check validation and a JWT (even expired) delivered by AWS to try to help you more ? You can email me at anthony[at]deroche.me

Regarding the last question, I cannot support JWKS for the moment in my module, although it might be interesting to do so. The underlying library I'm using does not support JWKS itself. I will propose it on the tracker.

from mod_authnz_jwt.

andrewlear avatar andrewlear commented on May 20, 2024

Thanks. I emailed you the requested items. Did you receive them? Thanks.

from mod_authnz_jwt.

AnthonyDeroche avatar AnthonyDeroche commented on May 20, 2024

Hello, yes I received your email. I will take a look at this and I will keep you posted.

from mod_authnz_jwt.

AnthonyDeroche avatar AnthonyDeroche commented on May 20, 2024

I reproduced the bug, and it seems to be a bug of the underlying lib I'm using to decode tokens. I opened an issue on the repo of the lib. I will keep you posted as soon as I have more information.

from mod_authnz_jwt.

AnthonyDeroche avatar AnthonyDeroche commented on May 20, 2024

The bug has been fixed, you should be able to validate tokens using my module using a PEM public key. Be careful to use libjwt v1.7.3, I updated the README with the correct version.

from mod_authnz_jwt.

andrewlear avatar andrewlear commented on May 20, 2024

Thank you. I will put libjwt 1.7.3 into the lab and will update you with the findings.

from mod_authnz_jwt.

andrewlear avatar andrewlear commented on May 20, 2024

I have been able to confirm that if I utilize the correct key that the JWT will validate. However, a Cognito user pool utilizes 1 of 2 keys to sign the JWT. Is there a mechanism that I can utilize to specify both keys as 2 AuthJWTSignaturePublicKeyFile entries in the Apache config, or add both keys to 1 file and have the module iterate over both keys to validate the JWT?

If you require a new JWT, let me know and I can supply that via email. Thanks.

from mod_authnz_jwt.

andrewlear avatar andrewlear commented on May 20, 2024

I hate to be a bother with this, but are you actively working on this or can I have a friend of mine submit a pull request to work on this functionality? Thanks.

from mod_authnz_jwt.

AnthonyDeroche avatar AnthonyDeroche commented on May 20, 2024

I just saw your messages, I'm not working on this for now, you can submit a pull request!

from mod_authnz_jwt.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.