Giter VIP home page Giter VIP logo

Comments (4)

nklomp avatar nklomp commented on May 25, 2024

Hi @ejossev Thanks for the bugreport.

Not entirely sure if I get it right, because IMO the current resolution logic does not contradict the spec. Your remark seems to be addressed in the else branch of the expression.

The if branch will only be triggered if we do get the OID4VCI metadata and only if it does not have a token_endpoint in it (something which isn't in the spec but seen in the wild) but does have the optional authorization_server value in it. This means it If that is the case we use the AS value to retrieve AS metadata and that should also provide the token endpoint. If we cannot resolve that well-known we raise an error, because now we have an OIDVCI issuer stating it has a separate AS at a specific location, but we could not retrieve its well-known metadata.

In all other cases we start fetching the OIDC and OAuth2 well-known metadata, see line 68. Then as a last step we double check whether we did find a token_endpoint, so first via OIDV4CI, then OIDC and then OAuth2. If that fails we throw an error, because we cannot find it.

I do believe we should also check for OIDC in case a separate AS is provided, and at one point it would be wise to stop support for a token_endpoint in the OID4VCI issuer metadata altogether. I also believe we need to change the logic a bit for Authorized code flows, because right now we are only interested in the token_endpoint and for the Authorized Flow we would also require either OAuth or OIDC metadata

edit:
Oh %$#%$#, sorry the else branch is at a different scope. Yeah that for sure isn't correct it seems. We will have a look at it

from oid4vci.

nklomp avatar nklomp commented on May 25, 2024

We will also split the OAuth2/OIDC metadata from the OID4VCI metadata, as that was fine and handy initially but will need to be done anyway for Authorized code flows

from oid4vci.

nklomp avatar nklomp commented on May 25, 2024

Thanks for reporting. The logic has been overhauled and now is both more flexible as wall as better in line with the spec. Will be released in the new version momentarily

from oid4vci.

ejossev avatar ejossev commented on May 25, 2024

Thanks, seems better now.

Have a nice day ;)

from oid4vci.

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.