7 ms·
Testing FIDO U2F security keys
- tptacek 9y agoYou'd assume that a device as sensitive as a hardware security key would get extensive testing from the vendor, from 3rd parties contracted to the vendor, and from random unauthorized 3rd parties testing out of personal or public interest. But in fact there are almost certainly commercial hardware security keys that receive no testing at all at the level AGL is working at --- which, while impressive and super interesting, isn't as low-level as serious third party specialized crypto validation goes. My takeaway from this is: buy the most popular U2F key (which happens to be Yubico's). This isn't a place where you want to shop around for interesting alternative brands. Nobody pays me to say this and I have no relationship with Yubico of any sort.
- voltagex_ 9y agoI tend to agree, but this is Hacker News - how does a new player break into the market in this case?
- dlgeek 9y agoDue your due diligence. Get third-party validation from someone with a good reputation you can trade on. Proudly flaunt that validation on your website, marketing material, etc., rather than hiding it behind some NDA for big customers only.
- jlgaddis 9y agoI know that some people feel that it isn't worth the paper it's printed on but I looked for FIPS 140-2 validated devices when I was looking for smart cards (for storing the private keys of CAs in an internal PKI). I'm not aware of any U2F keys that have been FIPS-validated (I realize that it is a very expensive and long process), though. Yubico's web site [0] says that validation is in process (for some of their devices) but it has said that for as long as I can remember. I like and recommend the Yubikeys as well (not that my opinion is worth anything) and, other than that one "PIN bypass" issue in the OpenPGP applet on some NEOs [1] (which was inherited from upstream), I don't recall hearing of any issues with them. There may be better devices out there but I'm sure there are much worse ones that you could buy (as AGL just showed us) and I'm quite happy with my (~7!) Yubikeys. ETA: "The YubiKey ... meets the highest level of assurance (LOA) requirements, based on NIST Electronic Authentication Guideline SP 800-63-2 ..." [2]. [0]: https://www.yubico.com/products/yubikey-hardware/compare-yubikeys/ https://www.yubico.com/products/yubikey-hardware/compare-yub... [1]: https://developers.yubico.com/ykneo-openpgp/SecurityAdvisory%202015-04-14.html https://developers.yubico.com/ykneo-openpgp/SecurityAdvisory... [2]: https://www.yubico.com/wp-content/uploads/2016/06/Yubico_WhitePaper_Achieving_LOA3and4_with_YubiKeys.pdf https://www.yubico.com/wp-content/uploads/2016/06/Yubico_Whi...
- dsl 9y agoI'd recommend watching this [1] talk once the videos go online. It paints a pretty nasty picture of all the things you can screw up and still end up FIPS validated. 1. https://www.blackhat.com/us-17/briefings/schedule/index.html#attacking-encrypted-usb-keys-the-hardware-way-7443 https://www.blackhat.com/us-17/briefings/schedule/index.html...
- jlgaddis 9y agoOh, I'm well aware that FIPS -- or any other certification program, actually -- isn't a panacea. There were issues found with the RNG in some country's national ID cards (smart cards) as well; the RNG had also achieved FIPS 140-2 validation. All things being equal, though, I would still be inclined to have a little more trust in something that has been through the process than I would in, say, the homebrew RNG [0?] used by Honest Achmed's Used Cars and Certificates. [0]: https://xkcd.com/221/ https://xkcd.com/221/
- deleted 9y ago[deleted]
- jlgaddis 9y ago> Honest Achmed's FYI, I was making a reference to a "bug" from 6.5 years ago: https://bugzilla.mozilla.org/show_bug.cgi?id=647959 https://bugzilla.mozilla.org/show_bug.cgi?id=647959 (another HN'er thought this was a "little racist")
- Xylakant 9y agoFWIW: I'm absolutely certainly guilty of the same mistake, but referencing a racist stereotype that somebody else (jokingly) used doesn't make it not racist (1). It's easy to fall into the trap and me, too, considered Honest Achmed a good joke at the time, but I don't, any more. (the joke is still good, but the names picked are not) (1) unless you use the reference to put it into context, or discuss it, ...
- tptacek 9y agoValidation in this space is nosebleed expensive. The "usual suspect" security assessment firms don't do this kind of work (or have no business doing it).
- arghwhat 9y agoWell, for starters, remember to zero your damn memory before using it so you don't leak old content...
- deleted 9y ago[deleted]
- csomar 9y agoWouldn't that make Bitcoin Hardware wallets the most secure then? They don't have the same software support and documentation as Yubico but they are targeted heavily by hackers. The two popular options are: Trezor and Ledger. Both supports FIDO U2F and have a large user base.
- TorKlingberg 9y agoDoes the FIDO U2F feature on them get targeted by hackers?
- csomar 9y agoMy understanding is that it depends on the secure components that secure the private key and sign the messages. So hacking FIDO means hacking the crypto private key or the wallet.
- m-p-3 9y agoTIL they also support U2F. Interesting.
- jlgaddis 9y agoRelated (but slightly OT) question: has anyone ran into any issues when using either 1) a single Yubikey for both U2F and SSH authentication or 2) multiple Yubikeys simultaneously on the same machine (i.e., one for U2F, one for SSH)? For SSH authentication, I use Yubikeys (and only Yubikeys) everywhere: my workstation at home (I WFH 99% of the time), my primary laptop, and a "backup" laptop. Each of these machines has its own "dedicated" Yubikey that I use to authenticate to remote SSH servers (a "Nano" that is left plugged in 24/7). I also use these (with challenge/response) to unlock encrypted LUKS volumes (containing ZFS pools) at boot, FWIW. I would like to begin using U2F (AFAICT, U2F support should be coming to Firefox soon, if it hasn't already; running FF57 Developer Edition here), preferably with these same Yubikeys I am already using for SSH. If there are any issues, however, I'm fine with using a separate Yubikey just for the U2F side of things (I have a few U2F-only Yubikeys laying around as well). Basically, I want it to be as easy/convenient as possible and, before I begin to attempt this, I'm just curious if anyone else is already doing this and, if so, what their experiences were and any issues they may have encountered. In theory, it should all just work but, in reality, well, who knows. TIA!
- jlgaddis 9y agoI'm replying to myself here but to anyone else interested, you can now -- unofficially, as of v57 -- use a U2F-enabled YubiKey in Firefox. See the details on Mozilla's Wiki [0] (short version: in "about:config", enable "security.webauth.{u2f,webauthn}") and visit Yubico's online demo [1] to test it out. [0]: https://wiki.mozilla.org/Security/CryptoEngineering#Using_U2F_.2F_WebAuthn https://wiki.mozilla.org/Security/CryptoEngineering#Using_U2... [1]: https://demo.yubico.com/u2f https://demo.yubico.com/u2f
- posixplz 9y agoU2F should work with your Yubikeys, irrespective of your slot 1/2 configurations. U2F does not depend on slot provisioning. Unlike your slot/gpg keys, U2F authenticators are unique to each individual hardware component and cannot be replicated between Yubikeys.
- jlgaddis 9y ago
- dpeckett 9y agoA while back I looked into building my own hardware two factor key. I wanted to experiment with the technology. I've since backed off the idea due to several serious challenges with designing secure hardware for this purpose. * By necessity there's a pretty large attack surface, you've likely got a vendor specific bluetooth stack and coprocessor. The same goes for wired solutions with hardware USB peripherals (though atleast significantly less complex). Being sure the hardware peripheral doesn't have any major memory safety issues is a complete bear to test, and that's not even touching on sidechannel analysis. * Running public key crypto on microcontroller (excluding specific hardware crypto support) is a little more novel than a desktop machine, the leading libraries are no where near as extensively battle tested. And there's architectural concerns about sidechannel attacks and often the lack of any memory protection units (bigger chips solve these issues, but power budget concerns are tricky). * And given all software has bugs, how do you update the firmware? Signed firmware patches as part of driver update? Who's to say somebody hasn't already owned your bootloader. I think the solution to all this, is to abandon the idea of additional hardware, what if your smartphone could act as a two factor hardware token over Bluetooth? The big problem is pairing really, and how to make this an easy process for users, I never figured that out. On the other hand I did come up with a scheme that would allow usb based hardware tokens to work without additional drivers / software and on all current major operating systems and browsers. I really ought to work on it, but as above I don't trust embedded hardware (embedded hardware is such an antithesis to, move fast and break things).
- bri3d 9y agoHow'd your scheme work? I suspect HN wants to know ;) A lot of hardware just acts as HID keyboard, but that only works one direction unless you use a side channel like visual (QR code like TOTP and/or camera like the Bloomberg unit). I think the Bloomberg auth units are some of the most advanced examples of this - they're protected against almost any imaginable physical attack, too (freezing memory state, power sidechannels, xray/delidding to dump mask ROM, etc.) But they have a lot of money to spend on it...
- dpeckett 9y agoBroadly based on abusing USB ethernet and browser origin policies. Relies on the fact browsers are used to treating the network layer as a hostile environment.
- _Codemonkeyism 9y agoSlightly OT, what do people use for U2F, Google Mail and Firefox?
- jlgaddis 9y agoHere's a list of sites that support 2FA, via hardware tokens and other methods: https://twofactorauth.org https://twofactorauth.org
- EwanToo 9y agoYubico do a short (but I think that's realistic) list of sites that specifically support u2f https://www.yubico.com/solutions/#FIDO-U2F https://www.yubico.com/solutions/#FIDO-U2F
- _Codemonkeyism 9y agoThanks I have a Yubico key and use it with Gmail on Chrome, to better phrase my question: How do I use it with FF? (my main browser).
- danieldk 9y agoOn Firefox Nightly, it works without extensions, but you have to set security.webauth.u2f to true in about:config. It only worked with some sites that I tried, for others you probably have to fake the user agent.
- daenney 9y agoYeah... The Google Cloud Console and Google Accounts do that for one. I can't set up or use my U2F key in anything but Chrome. Hangouts similarly barfs when you're using Firefox because they believe the WebRTC support is missing (instead of checking). Works fine with GitHub though :).
- nyolfen 9y agolastpass supports yubikeys as 2fa, but you have to have a subscription to premium for it to be enforced. i let mine lapse for a while and it simply stopped making me use my yubikey. i'm not really sure what was going on behind the scenes but it made me a little less confident in the particular aspect of lastpass.
- jnwatson 9y agoI cannot fathom that folks still can't parse DER correctly. It really isn't complicated.
- Legogris 9y agoI'd be very interested to see the author review how the cryptocurrency hardware wallets Ledger[0] and Trezor[1] compare - they also have U2F functionality. I use my hardware wallet for U2F and I am guessing they are becoming more widely used for consumer users. [0]: https://www.ledgerwallet.com/ https://www.ledgerwallet.com/ [1]: https://trezor.io/ https://trezor.io/
- cyphar 9y agoEEVblog did a video about the Trezor[1]. [1]: https://youtube.com/watch?v=BzxGoJdd8a4 https://youtube.com/watch?v=BzxGoJdd8a4
- csomar 9y agoI'm using the Ledger for U2F and it is easy enough. For SSH and GPG, not really. The software for SSH and GPG is made by a third-party. It is not well tested and the documentation is lacking. However, I hope it improves in the future. The Ledger wallet can do: 1. FIDO/U2F 2. SSH/GPG 3. Password Management 4. Wallet for Bitcoin, Ethereum and a bunch of other altcoins. So, yes, I think it is worth the deal.
- hasa 9y agoFIDO U2F is just enterprise stuff. My mom will never own one to log in to Facebook. So the market is very difficult for newcomers. That's why we see lots of low quality products which come and go.
- mtgx 9y agoMaybe not Facebook, but if the government does it right, she'll use something like that in place of her SSN to be able to use social services, get credit, vote, etc.
- hultner 9y agoSweden got a system a bit like this called BankID. BankID isn't operated by the government but rather by the system critical banks however it's really ubiquitous today and supported by most government sites, banks and other high security web systems. BankID comes both as hardware keys with smartcards or as a mobile application where you use a local key to sign a request.
- r3bl 9y agoBut she will enter the info from the SMS that Facebook sends to her? I mean, comparing U2F keys with the alternative 2FA methods (like SMS and Google Authenticator), it sure seems simpler to just tap the USB key instead of taking out your phone, unlocking it, seeing the message, and writing the code from the message. They're convenient as hell.
- wakkaflokka 9y agoI'd really like to buy a U2F token, but need to find one that let's me use it mobile (Android) as well as on desktop. I know that Yubico offers an NFC-enabled on, but it doesn't support 4096-bit keys if I understand correctly.
- te0006 9y agoThe Fidesmo dual-interface smartcard might fit the bill: http://shop.fidesmo.com/product/fidesmo-card-dual-interface http://shop.fidesmo.com/product/fidesmo-card-dual-interface You would need to buy and install the U2F applet ("card app") onto it. There are other applets available for PGP and for Bitcoin wallets, which can co-exist on the same card AFAIR. Not sure about supported key lengths. I'm not affiliated with Fidesmo or the applet vendors. Any opinions on this product from the HN crowd? E.g., what do you think about the security implications of their user-installable applet model?