The root cause of this attack is that the typical cryptocurrency wallet operational model involves the key leaving the device in plain text as part of the setup/backup process. Such a thing is impossible on any normal correctly configured HSM (while creating backups is possible by some sort of multi-step process where the secret key material never exists in plaintext outside the security boundary, how exactly that is done differs significantly between vendors).