Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for two-factor github auth #15

Closed
EricWittmann opened this issue Oct 15, 2016 · 1 comment
Closed

Add support for two-factor github auth #15

EricWittmann opened this issue Oct 15, 2016 · 1 comment

Comments

@EricWittmann
Copy link
Member

If users have enabled two factor auth in github, then basic auth will fail. Documentation found here:

https://developer.github.com/v3/auth/#working-with-two-factor-authentication

@msavy
Copy link

msavy commented Oct 15, 2016

HubPress is a JS-based blogging platform for GH which I’ve been trying out lately for my personal blog. They handle this exact problem, so might be worth checking out their solution.

The pattern is that you log in with your normal username/password, and then it bumps you back to the logon page to try again with an additional token field.

Example:

image

(Correct credentials but require 2FA):

image

A little message (not shown) briefly shows up saying 2FA is required.

Seems a reasonably nice pattern, but perhaps could be improved on.

Edit: See also https://github.com/HubPress/hubpress-plugin-github/blob/master/src/githubPlugin.js https://github.com/HubPress/dev.hubpress.io

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants