Code Monkey home page Code Monkey logo

Comments (4)

kevinchalet avatar kevinchalet commented on June 4, 2024

Hi,

There are multiple issues with your snippet:

  • You're sending both authorization request parameters (e.g response_type) and token request parameters (e.g client_secret or grant_type) as part of the same request to the authorization endpoint, which is completely invalid.
  • You're using basic authentication against the authorization endpoint, which makes no sense.
  • You're using multiple client authentication methods - i.e sending the secret via both the Authorization header and as part of the request form - which is illegal.

Consider using a real OAuth 2.0/OpenID Connect client stack instead of trying to implement that yourself. The OpenIddict client is an excellent choice for interactive flows like the code flow. You can find a lot of samples in the dedicated repo: https://github.com/openiddict/openiddict-samples

from openiddict-core.

kevinchalet avatar kevinchalet commented on June 4, 2024

Doing some housecleaning, but feel free to reopen if you need additional details πŸ˜ƒ

from openiddict-core.

LinneyDew avatar LinneyDew commented on June 4, 2024

from openiddict-core.

kevinchalet avatar kevinchalet commented on June 4, 2024

Hey,

Thanks for checking back in. I meant to reply to you last week but I was up to my neck in alligators.

No worries πŸ‘πŸ»

Unfortunately, my client wants to do some special processing so we need to partially roll our own solution.

The OpenIddict client has a very powerful events model that allows customizing each aspect of the request processing.
Out of curiosity, can you tell me more about that special processing?

Thanks for your response and thanks for the OpenIDDict libraries. And thank you for your quick responses.

Thanks for your kind words.

from openiddict-core.

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.