Saving SecKeyRef device generated public/private key pair on disk
问题 I've generated an RSA symmetric key pair on a device using SecKeyGeneratePair() on a device. I have SecKeyRef struct pointers for each key. So, how do I save a SecKeyRef to disk? Or even transmit it (I also imagine there are issues with correct encoding too)? Apple's 'Certificate, Key, and Trust Services' Guide notes You can send your public key to anyone, who can then use it to encrypt data. I'd like to save the private key especially; so I can use it on deployed devices to decrypt data