AWS now supports U2F/Yubikeys
aws.amazon.com
aws.amazon.com
It stores your secrets in plain text on the phone without any secure enclave. If your backup password is sniffed or there is a flaw in Authy or your mobile OS sandboxing fails you are toast.
I use Authy to manage my 2FA codes, but I rarely ever use the desktop app. I stick to my phone to keep a physical separation between my logins and my 2FA app.
I also started storing my backup codes as a base64 encoded gpg password encrypted text file in my password manager. If I ever lose my 2FA codes I can still get into my accounts in a emergency while also protecting myself from a password manager hack.
It's annoying, but as I said, I'm not willing to take the risk.
Convenience is the enemy of security. I think you're making a good choice though. It's a minor inconvenience for increased security and peace of mind.
If my 1Password vault is breached, I am pretty much in a world of trouble as it is.
I have to remember three passwords (oh no!) and feel safer for it. It could all be in my head, though.
If someone gets into your 1Password it’s all over anyway.
That said, I pay for the standalone app and store my vault myself. I have no actual reason not to trust AgileBits hosting it, but they must be a huge target and I’m not taking my chances.
I used to be a Keychain + Authy user but moved everything to 1Password.
With Yubico's authenticator, you store the secrets ontp your Yubikey. This means you can reset your phone and still be able to use the same TOTP shared secrets. Or if that matters, ask a friend to install the app and use your Yubikeys to get the TOTP.
You now have a backup login, it just has a different username too.
Maybe techie personal users have more than one, but I only carry one device (a yubikey) for work, someone at work can reset my MFA if I lose it.
I'd be surprised if "most" people have a backup device/codes.
It’s also helpful when you use a key that lives in a machine to not have to remove it. If you lose the machine, use another key to sign in and disavow the lost key.
If I have one key and someone takes it, I know it immediately.
If I have 2 keys and someone steals my spare, then I might not realize it for quite some time.
With AWS you are the company, and you should be allowed to set your own policy, and decide things like whether you trust yourself enough to store a backup key in a safe or something similar.
Suggesting Amazon should treat you like some employee of theirs is silly.
But for personal accounts, solo founders, travellers etc this is a no-go.
Really? I'd expect someone who's paying $50 for a yubikey to spend another $100 to have a backup key, a key for their laptop, and one for their desktop. Add another one for your keychain if you are using it on your phone (if your phone supports it).
Right now I do something similar, but I have to keep a list of which accounts I need to add to key 2, and the key is offsite, so I have a several week period during which an account only has one key associated with it.
Now, personally I wouldn't want the phishable Authenticator as fallback, but it's definitely better than SMS for example.
You will notice your key missing, then you can disable that key with your backup key. With only a password, it becomes a lot harder to notice someone stole your pw.
With 4 U2F keys, people who stole 1 of your U2F keys gain that one factor for only the services that you tied to that keys.
AWS EKS is a good example for anyone who has had a play already.
We eyed on switching from kops to EKS. But immediately stepped down after experiencing so many issues.
Why?!?! :(
LastPass for example
If all they managed to do was trick me into entering my master password on a dummy login page, the sort of phish that U2F is designed to protect against, U2F would still keep me protected while OTP wouldn't.
EDIT: "Fallback" is to have root account remove your IAM user 2FA. If root account 2FA is lost they have a few alternative verification options like email or phone call. [1]
1: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credenti...
With TOTP, you could still use API keys to interact with the API. Is that also true of U2F?
AWS makes it super quick and easy to remove lost 2FA devices using the root account, so it doesn't really matter as much as losing your 2FA for a crypto exchange or whatever where it's going to take at least a week or two to reset. Just keep TOTP on the root account, since you shouldn't be logging into that on a regular basis anyway.
https://github.com/coinbase/assume-role
edit: and apparently it doesn't work with this... :'(
- Requiring the attestation cert and not accepting a self-signed one—which U2F devices will magically not work? I don’t know, but apparently it’s strictly Yubikeys now.
- Still not convinced anyone seriously uses the console except for root accounts, where AWS forces you to.
- Only one U2F key? Bad. Only one U2F key and overall only one MFA method at all, disabling MFA where it matters most? Baffling.
- The legacy U2F API instead of just using WebAuthn already?
This is one of those things where I keep thinking I should just open source the SAML thing that safely gets an assertion to your CLI where you can assume-role with it, but who knows when AWS is going to decide to reimplement your project.
Atleast Krypton doesnt' work, neither do Titan keys it seems.
I would consider they did that on purpose in some kind of deal with yubico. But given the general level of 'buring-pile-of-failure' AWS manages to produce around the console, it is probably just that they didn't know
It makes no security sense to check attestation if your second factor is optional. How could a non-Yubico second factor make things worse compared to not using one? It couldn't. If you really, really care then store the attestations so that when fifty customers claim their U2F was broken into you can show that they all have Crap Co. FIDO tokens and point the finger at Crap Co. that's the absolute most that makes any sense with attestation.
Now, if second factor is _mandatory_ then it could make sense to decide OK, we trust Mattel, Apple and LexCorp but not HP, Tyrell Corp, or Weyland-Yutani. It's anticipated that banks (in fifty years when they hear about this new-fangled FIDO technology) would want that, giving customers their own tokens with their own attestation certs. But for an outfit like AWS this option makes no sense, so the correct design is to Never Ask, and if some higher-up insists on asking, just store the answer (including "No, fuck off") with the user's account and press on anyway.
For the access keys, you should look into things like aws-vault, which wrap the STS so that your shell is only ever handling temporary session-bound keys.
Thanks for the tip.
At first I thought that I hadn't enabled right. After checking the setting again, I found the problem--I had plugged the Yubico Key in upside-down.
https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_us...
1: https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credenti... ("You can enable one MFA device (of any kind) per root user or IAM user.")
I have a Yubikey for my LastPass. I lived with a single key for over a year. I finally got two more. I'm not sure why I made myself so nervous / stressed those 12+ months.
[1] https://blog.trezor.io/secure-two-factor-authentication-with... [2] https://trezor.io/passwords/
In my case all AWS accounts have a root user that has MFA enabled and that secret key is stored in a password vault. When a root user login is needed the key is plugged into an OTP application, tasks are performed and then the key is removed from the application.
I do however miss MFA when using the AWS CLI. A lot of my clients require MFA enabled when assuming a role in their account.
https://fidoalliance.org/specs/fido-u2f-v1.2-ps-20170411/fid...
The link to "see information about supported configurations" is 404: https://docs.aws.amazon.com/iam/mfa-u2f-config
Hopefully this practice remains limited. I really don't want haul a bag of different security keys around with me to access all of my services.
What are the pros/cons?
Not using a U2F key makes you susceptible to phishing attacks.
U2F credentials are tied to a particular domain, and so do not rely on the user making sure they are on the correct website. As such, they are not susceptible to typical credential phishing attacks.
This is assuming an owned machine. Not the easiest attack but still possible. Obviously things like Google Authenticator (while good) are even more susceptible to MITM phishing.
Best practice for a user would be to use a good password manager (so you can use long, unique, secure passwords) and MFA. The second part of that is something that can actually be enforced within an organization.
As far as Yubikey vs software TOTP, etc, it's a bit theoretical. AFAIK, none of the auth apps have had compromises, but it's a lot easier to imagine someone out there figuring out a 0-day attack on a piece of software running on random Android and iOS devices than on hardware like a Yubikey. In theory, the way something like Yubikey works, the actual "secret" involved is stored on the device, and all the computation involving it happens on the device itself, carried out by hard-coded firmware.
As a user, I also really like that the Yubikey (higher end models at least) can store GPG keys and perform those operations securely. So I can set up GPG auth for SSH to servers, and sign my git commits using my Yubikey and know that my private key won't be exposed even if, eg, there's a trojan installed on my workstation. (obviously anything done while working on a trojaned machine is suspect, but the key itself never leaves the hardware, so they can't get that).
It probably supports U2F, without all the privacy invasion of Google.