I'm looking for something either like this security white paper for iOS except for OS X or even better, some kind of security audit report from an independent expert. After reading through documentation like the Keychain Services Programming Guide I'm even more confused about what is vulnerable to an adversarial attack on an unencrypted backup of an OS X System.
Last time I checked, the user's login keychain under OS X was about as secure as the password. I recall some issue that shrank the actual secrecy of the key to something like 111 bits (foggy memory, please feel free to correct me) due to some issue with how the password is converted to a key, but that was a long time ago and hopefully that's been fixed.
On the other hand, I've been told the System Keychain is inherently less secure because any administrator can access it and an intruder has many options for becoming an administrator besides guessing a single user's password.
In particular, I'm worried about storing passwords used in automated scripts in the System Keychain as the system files are backed up and stored off-site without further encryption. Documents and other user data are encrypted before being taken off-site, but I have a nagging suspicion that there's a path I'm overlooking that recovers those keys once the System Keychain is compromised (due to our procedures, not necessarily any cryptographic flaws). So I want to have a thorough understanding of how the System Keychain is simultaneously secured yet accessible to any administrator.
How are the keys architected such that any administrative user can unlock the System Keychain?
Are there cryptographic restrictions that limit what an administrative user can do with information in the System Keychain in any way?
Given an unencrypted system backup without
/Users
, how would you gain access to the keys in the System Keychain?
I'm interested in OS X 10.5 Leopard and later versions, but specifically limited to desktop or laptop Macs without a T2 chip or secure enclave. Apple's Spring 2020 Platform Security Whitepaper explains pretty well that the critical keys encrypting keychain data are stored on the T2 chip and the T2 chip itself manages and applies ACLs which restrict access to the decryption functionality. So on those computers, as with all iOS devices, the keychain database is tied to the hardware and cannot be used on a different device.