Git Product home page Git Product logo

Comments (5)

dgouldin avatar dgouldin commented on May 14, 2024

I wasn't aware that the RFC was different from 1.0a. Thanks for pointing that out.

I think the correct answer is to namespace everything currently under oauthlib/ to oauthlib/oauth1_RFC5849/ but keeping the class names OAuthServer and OAuthClient. Then when we implement oauth2 it can be namespaced under oauthlib/oauth2_draft18/ or whatever.

@idangazit didn't want to change it right now, so I'll follow his lead on when is the best time to restructure.

from oauthlib.

ib-lundgren avatar ib-lundgren commented on May 14, 2024

Sounds good. Really like the structure of the OAuthLib now and think its advancing awesomely.

Noted another thing...

Currently resource owner key and resource owner secret is set to mandatory arguments to OAuthClient which might not be what we want. When obtaining a request/temporary token the client will usually have neither, the resource owner secret is most often obtained together with the "access token" in the last step of the authentication.

The oauth_token parameter may be set to an empty string so maybe that would be a good default value? Or None and not include it in params at all if not set. (http://tools.ietf.org/html/rfc5849#section-2.1)

The resource owner secret could safely be set to None without affecting the HMAC-SHA signature.

from oauthlib.

dgouldin avatar dgouldin commented on May 14, 2024

Changes required to the library should in theory be very straightforward. Simply point out where we're not adhering to the spec, and if you're correct, it's a bug, without exception. In the case where a paramater has a default if not specified or is not required, it should be represented as a keyword argument in the method used to fulfill that part of the spec, again without exception.

If you'd like to send a pull request for this particular change, I'd be happy to look it over and give you pointers if it's not pythonic, but I think you have the right idea. To satisfy the pedant in me, please open as a separate issue if you want to send a pull request.

from oauthlib.

ib-lundgren avatar ib-lundgren commented on May 14, 2024

Right, I'll do that in the future then =)

from oauthlib.

ib-lundgren avatar ib-lundgren commented on May 14, 2024

Closing since these changes have been made.

from oauthlib.

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.