Podcast
Root Causes 266: End-to-end Encryption in the Apple Technology Stack
Hosted by
Jason Soroko
Fellow
Original broadcast date
January 4, 2023
Recent announcements from Apple lay out a set of expansions in the scope and capability of encryption throughout the Apple ecosystem. In this episode we detail the announced changes and some of their implications.
Podcast transcript
Lightly edited for flow and brevity.
TCTim CallanThis was actually a little bit ago – not a huge amount – but on December 7, 2022, I believe it was, Apple made a set of announcements essentially about how they are dealing moving forward with encryption in their ecosystem and I think we wanted to talk about those today.
So what’s going on, Tim, is Apple is expanding their end-to-end encryption to iCloud backups which is kind of a big deal for people who really want to keep their backups in the cloud but it also extends out to some of their apps like Notes and stuff like that though what it doesn’t extend to is email. That’s the big exception but I think what’s interesting about that particular announcement is the fact that you can now hold the keys – and let me tell you what I mean by that. Whenever we say we are talking about encryption we are talking about there is a key pair that was generated for you behind the scenes.
TCTim CallanYes. There must be a key pair somewhere or it doesn’t work. That’s correct.
It would have been sent over to their HSM in the cloud and what Apple is doing now, you can opt into this which is you will now be the sole possessor of the private key on one particular device. Your phone probably.
TCTim CallanOk. So what used to happen in the past was - let me just make sure I get this right – is they would generate a private key on my behalf. They would store it in an HSM. They presumably had a whole bunch of security around there to protect those private keys and we were taking it on faith that Apple was going to do a good job of protecting our private keys and wasn’t gonna misuse them in any way. Is that the old technology paradigm? Did I describe it correctly?
TCTim CallanWhich is probably how it will work for most people, but you are saying I can also elect to generate and maintain my own private key?
TCTim CallanBut it will be done locally?
TCTim CallanSo one implication of that, of course, is that decryption can only occur on that particular device. So part of the Apple ecosystem is that I migrate seamlessly between devices. I have a MacBook and I have an iPhone and I have an iPad and they’re all mine and all my stuff is in all of them. But if the private key is local to one device, presumably anything that I encrypt must be accessed through that device. Is that right?
TCTim CallanSo my private key will actually move to these other devices? It will basically sit in storage on those devices?
TCTim CallanSo that answers my next question or partially answers my next question which is what happens if I lose that device? So I encrypt everything with a private key that’s on my phone, it’s only on my phone and then I drop my phone off the side of the boat by accident. Does that mean that all my stuff is permanently encrypted and I’m out of luck?
So all the details of this I don’t have in my head yet because I haven’t actually physically played with it but these are all good questions.
TCTim CallanOk. So, maybe it’s premature to ask that. One presumes that a lot of brain power went into questions like these at Apple and that we should be able to get good answers when the time comes.
TCTim CallanWe all remember the famous story of law enforcement attempting – I think it was the FBI – attempting to compel Apple to unlock an iPhone and Apple refusing to do so and there was kind of a standoff and then ultimately it went away because the law enforcement body involved stated that they had found another way to unlock the phone but, yes, I can see that where lots of tech companies will guarantee that they are gonna protect your secrets up and to the point that they are forced by legal requirements such as subpoenas to do otherwise, at which point they will comply with the law. And if you can’t open the encrypted material because it’s just not possible mathematically then you can’t comply with the subpoena and you will not be contempt of court when you say sorry, I can’t do it. It’s just not possible. And so, under those circumstances, that makes great sense why they would offer that as an alternative.
Like that’s the way we are all living right now and it works fine for most of us. But, on the other hand, if you know why you need to possess your private key and not let anybody else have it well then you know why you are doing that.
TCTim CallanAnd there’s a spectrum on that. And some of it is just principle. Some people just feel that as a matter of principle the government shouldn’t be able to do this and some people are going to walk the walk on that, are going to vote with their feet and I think that’s important because if you can easily spot the people who have something to hide because they are the only people who have selected this then that itself becomes a privacy violation. And part of what you want is you want everything to look the same. It’s not good to have a difference between who looks like they are actively hiding things and who doesn’t look like they are actively hiding things. And so some people may do this just because but, I think certainly some people will feel that you could have something that isn’t anybody else’s business and it may not even be that doesn’t mean cause you think that it’s illegal or unethical, you just might think it’s nobody else’s business and under those circumstances, this is an option that cryptographically guarantees that it really will be nobody else’s business.
And it’s true in this case as well. So I want to cover off two other pieces of the announcement from December 7, Tim.
And they are kind of related. Especially this part which is the usage of hardware keys with iPhone and iPad. So it’s already obviously been available to use a hardware key like a YubiKey, as an example, with a MacBook but now, you will be able to use NFC-based and lightening port YubiKeys with your iPhone and iPad, Tim.
I think that kind of goes hand-in-hand with if you are now in the possession of your private keys and you don’t even want to trust just the way the phone is storing it either in the software or the enclave or where Apple is putting it, you can actually now put that into your YubiKey, as an example.
TCTim CallanAnd then maybe that gets to my question of what happens if you lose your phone. Because if it’s on your dongle and you lose your phone, it’s ok. You’ve got your dongle. I guess there’s another question of what if you lose your dongle.
So, essentially using FIDO technologies for authentication, which underlying is WebAuthn. Of course, they have the marketing term of security keys. That’s Apple’s marketing term for it but in reality it’s just FIDO WebAuthn, which of course, we have a previous podcast meaning about meaning certain websites that want to take advantage that passwordless authentication for their websites can now, the entire ecosystem is now in place from the hardware token through the operating system and the necessary SDKs that you can incorporate within iOS and within your website. So everything is now in place.
TCTim CallanAnd you are anticipating another question is was gonna have or maybe it’s a comment because it’s not like you have the insider story but I was gonna say, it seems to me that it’s unlikely that it’s a coincidence that the WebAuthn move and this move both happened in close proximity to each other. This feels like a single coordinated, integrated effort that is being rolled out in pieces.
And here’s the third one, Tim, just to mention it. So, basically, Apple is now claiming in the same December 7 release – sorry, not release, but news release – they claim that an iMessage, their new iMessage can alert you if state-sponsored spies are eavesdropping on you and I think really what that comes down to, Tim, is when you are iMessaging with someone that’s already an end-to-end encrypted communication using Apple’s words. Not something I’ve personally verified but it’s Apple’s words. So, there’s two issues with that. One is let’s say you and I were doing a PGP communication and we wanted to exchange our public keys with each other offline. Completely offline. Let’s say we met face-to-face and we wanted to be able to exchange each other’s public keys. With PGP, that’s just kind of how it works. With iMessage, it’s not something that you were ever able to do because you couldn’t just get that key information and pass it on. But apparently, Apple will be – and again, this is another thing I just haven’t had my hands on yet, but they are now claiming that that kind of PGP-like experience of passing the public key to verify who it is actually speaking to is a part of what they are offering and a second part of what they are offering here is let’s say that an unauthorized computer came into the possession of the Apple ID of the person you are speaking to. You as the other end of the iMessage party will be notified to that and, in fact, they had a screenshot of what that would look like on Apple’s blog on this topic. So, I thought that was interesting. They are giving you visibility to the state of security. Things like, hey was there an unauthorized computer that has successfully logged into the Apple ID account. So, they’re giving you that kind of capability now.
TCTim CallanI wonder, there’s a bunch of questions that come with that one. How do they know? Like if I go and purchase a new MacBook and then log in, is that going to trigger that? Presumably not because it’ll be attached to my Apple ID. Interesting. And also interesting in terms of will there be circumstances now or if Apple gets subpoenaed and somebody says we are gonna do, try to spy on this communication, can a court order Apple not to inform you of that? I mean I think we could probably assume that when we get that warning, it’s probably true. And that could be happening in lots of places. Maybe it’s the government of Turkey that’s doing that and Turkey has no jurisdiction out of Apple so they can go pound sand. But if it’s the NSA, is Apple still gonna be able to tell me?
TCTim CallanRight, if you are in the sole possession of the private key it doesn’t matter because once again just mathematically Apple cannot obey the court order. They simply can’t.
TCTim CallanAnd to your point, not that we expect them to be perfect, but Apple usually is pretty buttoned up on stuff like this. So, you don’t expect them to make rookie errors. You don’t expect any high school kid to be cracking this. Maybe it might turn out to be imperfect or flawed but you think those flaws are going to be subtle and Apple usually when they roll something like this out, it’s usually pretty well thought through.
Anyway, interesting announcement December 7 and it’s right up the ballpark of this particular podcast. So there you go.
TCTim CallanThere you go. So that’s important. A lot of people are out there using the Apple stack and if you are, this is a big thing to be aware of and these might be options that are interesting to you.