Open ghost opened 10 years ago
Hi @nahtnam - I haven't investigated this.. I'll try to get an opportunity to do this soon.
@xntrik That would be awesome! Thanks! :)
I'd like to do Yubikey too, like Issue #5
@xntrik are you interesting in something like a "plugin system" where TOTP codes, YubiKey, and possibly SMS could be added and enabled somewhat dynamically? Plugin might be the wrong work. The point being that an app developer could choose to expose one or more of a set of supported code types.
My, now old and messy, fork simply added a branching "verify" method that statically tried TOTP and YubiKey in sequence. Re-implementing that in a more separated and dynamic way would not be terribly hard. I will have to re-implement something equivalent soon and would like to do that in a way that is blessed and maybe even supported by this gem.
The good thing is that TOTP and YubiKey have distinctly different codes making it easy to detect which kind of code you are using. Adding a few other "plugins" and that might fall down if several of them are 6 digits for example.
The activation and setup of each type of code has less magic. You really need a separate activation flow for each type.
TOTP activation involves 2 steps. Showing the QR code and verifying with a code. YubiKey can be single-step. Focus a form field and press the button on the YubiKey and I get both the token id and can verify any subsequent presses are from the same token and are authentic.
As a side-note. I personally never implemented SMS as a primary factor. Since there is a per-SMS cost we wanted to see if any customer would ask for it. They didn't :smile: but most users don't enable MFA either.
Any progress for Mongoid 5 support?
Hey! Will this gem run well alongside of https://github.com/Houdini/two_factor_authentication ? <- Is a really good gem and I would love it if I could use this in conjunction of that.