News for hackers. Stuff that matters.
Re:Compromised Microsoft Key: More Impactful Than We Thought by jsiepkes on Saturday July 22, 2023 @12:38AM (#36823315)
I highly doubt this key was on a HSM. I keep being amazed by news about keys being stolen which seemingly should have been on a HSM.
Re:Compromised Microsoft Key: More Impactful Than We Thought by callalex on Saturday July 22, 2023 @12:48AM (#36823379)
HSM?
Re:Compromised Microsoft Key: More Impactful Than We Thought by 0xC0ncord on Saturday July 22, 2023 @12:49AM (#36823391)
A hardware security module (HSM) is a physical computing device that safeguards and manages secrets (most importantly digital keys), performs encryption and decryption functions for digital signatures, strong authentication and other cryptographic functions. These modules traditionally come in the form of a plug-in card or an external device that attaches directly to a computer or network server. A hardware security module contains one or more secure cryptoprocessor chips.

https://en.wikipedia.org/wiki/Hardware_security_module

Re:Compromised Microsoft Key: More Impactful Than We Thought by whartung on Saturday July 22, 2023 @12:54AM (#36823411)
Hardware Security Module.

A tamper resistant piece of hardware that does key management as well as encryption services. Essentially once a key is installed (or generated) it never sees the light of day again.

Re:Compromised Microsoft Key: More Impactful Than We Thought by jshmrsn on Saturday July 22, 2023 @12:50AM (#36823397)
Looked it up, appears to be Hardware Security Module.
Re:Compromised Microsoft Key: More Impactful Than We Thought by taspeotis on Saturday July 22, 2023 @12:58AM (#36823425)
Hardware Security Module
Re:Compromised Microsoft Key: More Impactful Than We Thought by pieterr on Saturday July 22, 2023 @12:50AM (#36823395)
Hardware Security Module (HSM).
Re:Compromised Microsoft Key: More Impactful Than We Thought by CalmStorm on Saturday July 22, 2023 @01:03AM (#36823447)
One of the most popular HSM is Thales Luna Network HSM, which can perform 20,000 ECC operations per second [1]. Even with the size of Azure AD, Microsoft may not need a lot of HSMs for signing purpose. HSMs are not particularly easy to manage though, maybe that is one of reasons they are not used as much as they should be.

[1] https://cpl.thalesgroup.com/encryption/hardware-security-mod...

Re:Compromised Microsoft Key: More Impactful Than We Thought by kune on Saturday July 22, 2023 @01:07AM (#36823474)
There are two scenarios: First: Microsoft uses the JWT signing keys in memory and the attacker were able to get access to it by injecting code or get access to the memory image of such a process. Second: Microsoft actually uses HSMs but has to distribute the keys geographically and the attackers were able to get access to the key this way.

The first scenario is more likely, but you cannot exclude the second as well.

Re:Compromised Microsoft Key: More Impactful Than We Thought by 8191 on Saturday July 22, 2023 @01:51AM (#36823665)
As for each purpose several keys exist, according to the article, geographic key distribution wouldn’t be necessary anyway.
Re:Compromised Microsoft Key: More Impactful Than We Thought by wahern on Saturday July 22, 2023 @01:08AM (#36823480)
Keys on an HSM are difficult to use by a team. Network attached HSMs are a thing but they have poor integration with the toolchains developers often use. Recently I was able to write my own ideal tool to help bridge the gap between toolchains and hardware secure enclaves: https://keymux.com
Re:Compromised Microsoft Key: More Impactful Than We Thought by mike_d on Saturday July 22, 2023 @01:32AM (#36823573)
Keys like this should never be used by a team. They should never touch a developer or devops workstation. They exist in prod only inside of an HSM.

High performance HSMs capable of handling 10k+ transactions/second are well within the price range of a well funded startup.

Re:Compromised Microsoft Key: More Impactful Than We Thought by wahern on Saturday July 22, 2023 @01:53AM (#36823677)
> Keys like this should never be used by a team. They should never touch a developer or devops workstation.

That's the point of KeyMux: keys never leave a secure enclave. In fact, KeyMux has no logic to load private keys or to perform key operations in-memory, except in the context of ephemeral TLS. The TLS layer does support using HSM keys for mTLS authentication, so you can use a security token for peer mTLS authentication to a network attached HSM.

That's the whole point--you can use all the tools built and commonly used with in-memory keys, but using enclaved keys, instead.

A follow-on idea I'd like to spend time on, if I have the chance, is to write modules for Vault and/or some KMIP implementation that integrate with the app so that authorization for key operations on a networked-attached key store require the consent of multiple parties (with that consent using local secure enclave-based authentication, of course). So, for example, if you're going to roll a release, one developer or an automated pipeline submits the request but the signing awaits confirmation from other team members.

Re:Compromised Microsoft Key: More Impactful Than We Thought by tatersolid on Sunday July 23, 2023 @07:30AM (#36834397)
> High performance HSMs capable of handling 10k+ transactions/second are well within the price range of a well funded startup.

Microsoft knows this, and even offers HSMs as a cloud service.

HSMs simply don’t scale up to something the size of azure AD. Even if you could use 10K+ of them in a global cluster, copying keys between HSMs inherently exposes the master keys anyway. And how do you secure access to the HSMs, with another secret shared on every validation server? Turtles all the way down.

Re:Compromised Microsoft Key: More Impactful Than We Thought by viralpoetry on Monday July 24, 2023 @03:32AM (#36844222)
> copying keys between HSMs inherently exposes the master keys anyway

that's not true, even with their BYOK you export the key from one HSM under a shared key and then import it to another device

Re:Compromised Microsoft Key: More Impactful Than We Thought by withinboredom on Saturday July 22, 2023 @06:02AM (#36824919)
I was pretty excited but then saw it was apple-only. I don't see support for TPM 2.0 coming soon, but instead things like smart cards.
Re:Compromised Microsoft Key: More Impactful Than We Thought by wahern on Saturday July 22, 2023 @02:33PM (#36828543)
I had to draw a line so I could actually release something. But Windows and Linux support is definitely a target. In fact, the core software was originally developed on both macOS and Linux with PC/SC smart cards (both PIV and OpenPGP) and Vault as key stores, but without any GUI components--everything compiled into a set of PKCS#11 (for OpenSSH, OpenSSL ENGINE, etc) and PC/SC modules (for GnuPG). And I stayed away from macOS and Linux APIs as much as possible to ease a Windows port.

But friends and coworkers I explained and showed the idea to didn't get it conceptually (e.g. people have the idea of key rotation drilled into their head as if that's the alternative to HSMs, instead of it being a mitigation for a fundamentally broken key management ecosystem), plus most people just wanted something they could point SSH_AUTH_SOCK at, so there needed to be a daemon/menubar/taskbar service. Ultimately the hard part was modeling and building a GUI around the concept, so it would be easier to understand and use. To get something out the door I targeted my daily desktop environment, macOS. It's using Yue as the GUI toolkit, which supports Linux/Gtk, macOS, and Windows.

I took a year off of work to finally get the idea out of my head, which I had been mulling over for many years. But now I find myself in the middle of a downturn in the software engineering job market (anybody hiring or interested in investing?), so while I have work in progress to round out the macOS app features, Linux and Windows (which is really where the commercial viability exists, I think), will need to wait until I have some cashflow.

I'd like to eventually release the Linux work as open source. But FWIW if someone has a specific use case in mind and is willing to fund development, I could very quickly build and release a [non-GUI] Linux package. PKCS#11 and PC/SC Linux modules still build in the tree, and adding a TPM key store adapter along side the other internal adapters would be relatively simple.

Re:Compromised Microsoft Key: More Impactful Than We Thought by withinboredom on Saturday July 22, 2023 @02:39PM (#36828610)
Oh yeah. The MacOS is something magic you’ve worked out. I use my yubikey for ssh keys and I was never able to figure out how to get macOS to work for other processes (like IntelliJ) unless it was started from a shell. Then one day IntelliJ changed how that works and it hasn’t worked since.

Anyway, this is really cool. I use Windows, Linux, and Mac every day for work and having a consistent method of doing this kind of stuff sounds amazing. Keep up the good work.