@q3k @jaseg typically there are flags you can set on a key, sometimes only at key creation time, that control exportability
The options tend to be “No export at all”, “Export only to HSMs from the same manufacturer (via key attestation from the receiving HSM)” and “No export at all”.
Typically there are also custody flags (i.e. you can know “Key was generated on this HSM”, “Key was imported from a same-manufacturer HSM with attestation” or “Key was imported yolo”, “Key has been exported with attestation”, “Key has been exported yolo”)
But like. I think quite often the keys have less strict controls set on them because nobody wants to end up stuck in a 30 year relationship with a HSM vendor.