The former can be forced (e.g. I must provide my safe key) and the latter cannot (e.g. I don't have to reveal my password).
The line gets blurry: keyed lock vs combination lock, password vs SSH key.
Surely you don't need to participate in the activity? They are just allowed to take and use it, I assume?
You must unlock your door, and you must unlock your safe, if it is within the scope of the warrant.
https://www.quora.com/Can-a-search-warrant-compel-me-to-unlo...
Things that you ARE (such as fingerprints, DNA, hair color, photo, sample) can be compelled by a court order (e.g. a warrant) because they aren't the contents of your mind but physical aspects of your existence.
That's why the use of a strong passphrase that isn't tied to a biometric is important if you're worried about this sort of thing.
They can certainly open the safe. They just can't compel you to TESTIFY to something.
The contents of your mind are sacrosanct. If they can compel you to divulge a combination, then they can also discern that you had access to that safe by virtue of possession of the combination. Not allowed by our laws.
I imagine it gets murky around things like SSH keys, which are technically a kind of password, but too big for a human to remember - and therefore must be "instantiated" in a physical device somewhere.
A likely interpretation might be: an SSH key without a keyphrase is like a physical key, and you must hand it over, while a key with a keyphrase is like a combination lock, where you must hand it over but you are not required to state the keyphrase.
Not all authentication methods are equal it appears. Fingerprint, facial recognition, other bio-metrics aren't considered the same as if you need to "speak" your password to someone. In other words, they can make you scan your finger or look into a camera, but they can't force you to tell them your password.