Closed colinodell closed 5 years ago
I think I'll go ahead and implement the PR for this, at least using The Time-based One-Time Password algorithm (TOTP), RFC 6238, basically the same thing that's compatible with Google 2FA.
Once I begin in earnest, I'll update this issue. Of course, it'll be in my fork without any guarantee this project will actually merge it.
I think any reasonable PR which introduces 2FA would be welcome. Anything that is compatible with apps such as Google Authenticator (or Authy, preferably) would be good. Definitely not mobile text message based or such as we do not have the resources to work with that.
a TOTP implementation would support both Google Authenticator and Authy automatically, as they are both TOTP apps (and would also support other TOTP apps)
I've begun working on a TOTP implementation and hope to have that ready for review soon.
Would there be any interest in also allowing email-based 2FA and/or backup codes?
IMO, backup codes are indeed useful, to prevent locking someone off their account entirely if their phone with the TOTP app gets stolen (and they don't use a TOTP app supporting backup of the config like Authy does).
Are you planning to display the RFC 6238
key too, apart from embedding it into the QR code?
Apps like KeePassXC can be used to generate TOTP, but can not scan QR codes
I don't see why not. QR code should not be leading functionally speaking, it should be an additional feature. As you said, not all apps support QR code as input.
Good call! I have updated my PR to expose the key: https://github.com/composer/packagist/pull/1031#issuecomment-540543058
Umm guys, I lost my 2FA and also my backup code so that I cannot pass the 2FA screen. Is there any other way to log in ? Something like Reset Password
that sent to the email ?
@TheArKaID I disabled it for you, but please use contact@packagist.org for such support enquiries.
Would you consider implementing two-factor authentication to help protect accounts of package publishers? I don't have any specific implementation in mind - I just know that other package manager sites (like npm) allow 2FA and it seems like a good security measure.