Giter Club home page Giter Club logo

Comments (11)

awalias avatar awalias commented on May 24, 2024 4

fixed by #98

will be available in supabase dashboard for new projects this evening

for existing projects it will be shipped tomorrow

from auth.

Eduardogbg avatar Eduardogbg commented on May 24, 2024 3

I can create a PR for this, if it is of interest

from auth.

awalias avatar awalias commented on May 24, 2024 2

some initial work here: #96

from auth.

awalias avatar awalias commented on May 24, 2024 1

I started work on this but found that twitter doesn't use oauth 2.0 for accessing the user's email address:

image
from here

the flow is therefore different to what we use for the other providers: https://developer.twitter.com/en/docs/authentication/oauth-1-0a/obtaining-user-access-tokens

so I'm not sure how relevant our existing methods like

p.Exchange(oauth2.NoContext, code)

are in this approach

from auth.

dbredvick avatar dbredvick commented on May 24, 2024 1

Would love to have Twitter as an option for auth. Looks like the NextAuth folks had to go with OAuth 1.0A https://github.com/nextauthjs/next-auth/blob/main/src/providers/twitter.js

from auth.

awalias avatar awalias commented on May 24, 2024

would be amazing @Eduardogbg !

from auth.

Eduardogbg avatar Eduardogbg commented on May 24, 2024

Cool, I'll look into it!

from auth.

Eduardogbg avatar Eduardogbg commented on May 24, 2024

@awalias it seems like the OAuth 2 protocol is fundamentally different from the OAuth 1.0 and as so I don't think we'll be able to reuse much from the OAuth providers code. If I can create an external dependency on a OAuth 1.0 library it would be easier, but I also understand if that's not preferred.

Also, I'm afraid some of the interfaces named OAuth could be confusing, as they wouldn't be satisfied for the OAuth 1.0 providers. That can be solved either by refactoring them to more generic ones (but I'm not sure that's either possible or good idea) or by renaming them to be OAuth 2 specific.

from auth.

awalias avatar awalias commented on May 24, 2024

If I can create an external dependency on a OAuth 1.0 library it would be easier

I'm happy to proceed on the basis of ease of implementation, we can optimize later if needed

I'm afraid some of the interfaces named OAuth could be confusing

perhaps we can use TwitterOAuth or OAuth1_0a for anything twitter specific. And can always refactor if we require other OAuth 1.0 providers ?

from auth.

awalias avatar awalias commented on May 24, 2024

might be useful: https://github.com/markbates/goth/blob/19c3059c9ed44995940c8222a8eda10f6b604e01/examples/main.go#L75

from auth.

awalias avatar awalias commented on May 24, 2024

previous PR superseded by #95

from auth.

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.