00:00:00.000-->00:00:05.000 >>So I’m Micky that's Jesse at the end that’s Oleks. Um, we are gonna start running by the 00:00:09.583-->00:00:15.708 slides, if the screen goes black, please scream so we know because there is a problem with 00:00:15.708-->00:00:22.583 the cable. I’m going to put a little bit of emphasis on this, Oleks tells me that the first 00:00:22.583-->00:00:28.417 two slides and the last two slides are the most important in our talk,and you don't mess with 00:00:28.417-->00:00:34.875 the Ukrainian. So, um in high level we are going to talk about, what we did, how we 00:00:34.875-->00:00:36.875 started, cover the vulnerabilities we found, and I’m guessing most of you are 00:00:36.875-->00:00:40.417 here to hear about the remote vulnerability, we will cover that too. So, we don't have time 00:00:40.417-->00:00:45.417 to do introductions, thats us. A little bit of a background, we did a lot of things last year, 00:00:56.125-->00:01:01.125 so, we faked the Def Con black badges, we did DMA attacks over the year using y-gig, we also 00:01:03.417-->00:01:08.417 hacked the wimo, and we did some radio infotainment stuff, just for fun. Now, we wanted to get 00:01:11.208-->00:01:18.125 into automotive right, so, we dutched a little bit of the radio, but that's it, that’s all 00:01:18.125-->00:01:23.125 we know, so what do we do? This is what we know about cars, there's autonomous cars, there’s 00:01:27.000-->00:01:32.417 connected cars that talk to themselves, to all the other cars, and to specific cars, and 00:01:32.417-->00:01:37.417 all this drive by wire stuff and we have no idea how it works. [silence]. Hold on, it’s stuck. 00:01:40.375-->00:01:45.375 There we go. Thats our budget. We really don’t know what to quantify right? You start, like 00:01:50.333-->00:01:55.333 ok, how do I hack cars? So we already knew from doing the radio, ransomware POC how much a 00:01:58.708-->00:02:05.333 radio cost. We know it cost like around fifteen hundred dollars new, half the price when it’s 00:02:05.333-->00:02:10.333 refurbished. So we get a sense of cost. Where do we go from there right? We go to the 00:02:13.875-->00:02:19.708 wrecking yard. So allow me to introduce the Hillsborough Wrecking Yard in Oregon. It’s 00:02:19.708-->00:02:24.708 very ordered and sorted, very nicely. Funny story about that, um, when you walk down a 00:02:32.625-->00:02:37.833 wrecking yard, with one of the owners and you tell them, you have a really nice junk yard, 00:02:37.833-->00:02:42.833 they get offended. [laughing]. So try not to do that, if you do this. When we got in there we 00:02:46.875-->00:02:51.875 said hi, we need whatever car you have that’s 2015 and above. So we start walking around the 00:02:55.500-->00:03:00.500 wrecking yard, and we see a Ford F-150, that’s the size of a Fiat 500. Were like ok, that’s a cool 00:03:03.083-->00:03:09.458 car but we need parts that we can use, not parts of parts. So we see another Acura, another 00:03:09.458-->00:03:16.417 Honda, and a couple of other cars that are compressed, were like, maybe, and then we walk by 00:03:16.417-->00:03:21.417 this. We’re like, that’s a nice car. Um, it’s almost completely pristine, except the dent, on 00:03:24.000-->00:03:29.000 the front [laughing]. They did have the motor out for sale in the front of the shop, but ah, 00:03:31.458-->00:03:36.458 yeah, it did have a little bit of a fender issue. Um, so we did a cut, and a paste, no formating 00:03:42.750-->00:03:47.750 in the back of my car. A little bit of car section there, got it back to our lab, did a trip to 00:03:50.417-->00:03:55.417 the hardware store, and Lowes and behold we have somewhat of a front of a car, I don't know if 00:03:57.583-->00:04:02.583 I’d call that a third of a car. And then the challenge was to get it functional. So, we hooked 00:04:05.625-->00:04:12.250 up a desktop power supply to it right, cars run on twelve volts, that thing puts out twelve 00:04:12.250-->00:04:17.250 volts. Yolo, ah, it worked. [laughing]. It kinda worked, the car was still complaining about 00:04:20.500-->00:04:25.500 us moving. We needed to find the handbrake, which was interesting [laughing]. Um, there’s no 00:04:29.250-->00:04:33.083 handbrake, well, there is a handbrake,it’s not a mechanical handbrake, it’s a different 00:04:33.083-->00:04:38.083 story. Once we got all the electrical running, we had to get the connection working, so, 00:04:40.208-->00:04:45.208 this specific car is a Nissan Leaf, it has, um, the back end for Nissan, is called 00:04:47.208-->00:04:52.208 Nissanconnect also known as car wings. It’s a whole website that allows you to control some of 00:04:54.875-->00:04:59.875 the car's functions remotely. Like, AC, charging on and off, I don’t own a leaf, but that’s 00:05:02.792-->00:05:07.792 what I hear. So, we decided to try and get that connected so, we need to switch the owners. We 00:05:13.542-->00:05:19.250 call Nissan, we say hey we opened an account on your website, we want to associate 00:05:19.250-->00:05:24.250 this vin with our account. They, say ok, show us proof of ownership. So we go to the 00:05:27.000-->00:05:32.000 wrecking yard, we ask the guy hey, can you give us like the title for the direct car. And, 00:05:37.125-->00:05:42.125 that’s his exact expression, [laughing]. Like, wrecking yard folks they're not amused by 00:05:46.625-->00:05:51.625 anyone. Ah, so we can’t move the title, what can we do? Bill of sale, do anything else? Ok, 00:05:57.917-->00:06:04.542 well, let’s try a hail mary, get a receipt from the wrecking yard, send it to Nissan, and, we 00:06:04.542-->00:06:09.542 got it. So they connected us on the back end, we had a third of a car, almost functional. Now 00:06:12.583-->00:06:17.625 once we had that, we had to decide what do we go after, right? So, we look at the radio 00:06:17.625-->00:06:22.625 just the IVI, this is the high level diagram for the, what’s it called? The, [off mic whisper] 00:06:25.167-->00:06:31.500 what’s the vender? The Clarion based IVI in the car, as you can see there is a lot of stuff 00:06:31.500-->00:06:36.500 going on. Ok, let’s put that aside for a second, let’s look at it. Its running windows 00:06:40.083-->00:06:45.083 automotive seven, ok, a little bit of googling, a little bit of snooping, its close source needs 00:06:47.375-->00:06:52.375 license, but that’s too boring, right?. You want to hack the car, but not like this. 00:06:54.542-->00:06:59.542 [laughing]. Ok maybe there is something else let’s keep looking. So, the radio has a 00:07:01.917-->00:07:06.917 diagnostics mode, you do a three, two, one, and it puts the radio in diagnostics mode. So, 00:07:09.708-->00:07:14.708 we put ours in it, and were like ok, put an SD card in, dumped debug log and we get the 00:07:17.458-->00:07:22.458 navigation debug data, contacts, waypoints, SRAM dump, and flash dumps. Hum? Ok? Moving to the 00:07:28.583-->00:07:33.583 web vulnerability, we took the data from the debug logs and, we run strings on it. So we find 00:07:35.917-->00:07:40.917 this URL on it, like that’s interesting, what’s that? No one owns it. We look at each other 00:07:43.625-->00:07:48.625 like, haha, let’s buy it. [laughing]. So we buy it. Let’s put a honey pot on it, on all 00:07:51.500-->00:07:56.500 ports let’s see what’s knockin. First knock comes from Japan, I- and- ah- the IP blog comes from 00:08:02.708-->00:08:08.292 Nissan motor corporation. Like ok, at the time, Jesse, and I were presenting in Pacsac, so we 00:08:08.292-->00:08:13.292 were in Japan, like ok, let’s go to Nissan crossing and take a selfie. [laughing]. After that 00:08:16.083-->00:08:21.083 we waited a little bit, not too long though, couple weeks maybe, and, we get another one. And you 00:08:23.500-->00:08:28.500 look it, it’s like, ok it says user agent Nissan car wings, something something, huh? That 00:08:33.083-->00:08:38.083 looks like compressed data, let’s just uncompress it. Ok, once we un compress it, we see 00:08:41.292-->00:08:46.292 some interesting stuff. So me and Jesse look at each other and we go like, [laughing], is that 00:08:48.750-->00:08:53.750 a car connecting to our server? And now Jesse. >> So if we take a closer look at the information 00:09:00.625-->00:09:06.500 that we actually got here, it includes some information like, navigation ID, DCMID, but then 00:09:06.500-->00:09:12.917 it also has like complete telephone number, including area code, SIM ID, the vin of the 00:09:12.917-->00:09:19.000 vehicle itself, and then user ID and passwords for the car wing site. It has a couple more 00:09:19.000-->00:09:25.917 version numbers, but then it also has GPS coordinates of the car itself, including the 00:09:25.917-->00:09:30.917 direction the car is pointing and the speed it’s traveling at. [laughing] And it also has the 00:09:33.125-->00:09:38.083 particular cell network that its roaming on that life with a smiley there, is the cell 00:09:38.083-->00:09:43.500 network that it’s on, and we’ll talk about that a little bit later. Um so, that’s cool, we 00:09:43.500-->00:09:49.417 can actually map, like take all the check in-ins that we've gotten for a particular car, and 00:09:49.417-->00:09:54.000 map everywhere that it's been. This one looked funny so we, took a little bit of a closer 00:09:54.000-->00:09:59.000 look at this one, and ah, it didn't make sense. Like, some of the cars you could clearly see 00:10:04.167-->00:10:08.875 the person lives here, it's checking in all the time at somebody's driveway so, we 00:10:08.875-->00:10:15.250 didn't want to show you that one anyway but, this one looks funny even beyond that. And the day we 00:10:15.250-->00:10:20.250 looked at this particular trace, you’ll take a look down here at the bottom, it had checked in, 00:10:22.500-->00:10:26.750 in the center of the Delaware River [laughing] and we were like, this, it doesn’t make 00:10:26.750-->00:10:31.458 sense, we like looked up news reports is there a car in the river? Was there a car accident? 00:10:31.458-->00:10:37.917 Are we getting incorrect GPS coordinates? Right next to this spot there is actually a little 00:10:37.917-->00:10:44.500 industrial area with kinda tall metal buildings, so maybe the signal was bad. It still seemed 00:10:44.500-->00:10:49.583 funny, so we were also like do we need to call somebody? Do we call up and say there might be a 00:10:49.583-->00:10:54.417 car in the river, go look, I can’t really tell you how I found out [laughing]. This car 00:10:54.417-->00:10:59.417 did start checking in elsewhere a few hours later. But for a few hours there we were like holy 00:11:01.750-->00:11:06.750 crap, what do we do? To look a little bit closer at this one, we just took the VIN and googled 00:11:09.208-->00:11:14.208 it and found this, it’s a shipment record, it looks like Russian, but it’s actually 00:11:16.750-->00:11:21.750 Ukrainian and if you throw it into google translate, it basically is a shipment record 00:11:23.833-->00:11:28.833 saying that it’s being imported into the Ukraine. And it talks about motor vehicle for use on 00:11:32.208-->00:11:39.125 public roads so, we thought this is getting even weirder. So we looked up car facts for this 00:11:39.125-->00:11:44.125 vehicle and it was sold in 2015, like not even a month later after seven hundred miles total 00:11:47.333-->00:11:52.333 loss, like, declared a total loss written off, uh, it was then purchased with a rebuilt 00:11:55.875-->00:12:00.875 title and exported to Poland in 2016 so, for some reason we have a vehicle, that, the other 00:12:03.375-->00:12:08.375 thing, the cellular network that I pointed out before with the smiley after it, that’s a 00:12:11.958-->00:12:17.042 network provider that only operates in Belarus in the Ukraine. So we have a vehicle 00:12:17.042-->00:12:23.917 that’s totaled in the US, was exported to Poland, is driving around, well at least the radio 00:12:23.917-->00:12:28.917 is driving around sending us check in’s, on a Ukrainian network cell provider. Thats 00:12:33.125-->00:12:37.458 kind of weird, we don't know why it’s sending coordinates from Philadelphia, maybe the map in 00:12:37.458-->00:12:43.667 the device is set up for one area and doesn't know how to process that and sends us 00:12:43.667-->00:12:47.542 coordinates that are offset by some amount, that's weird we don't know why that's happening 00:12:47.542-->00:12:54.125 still so. But why is this happening at all? And it turns out that all of these vehicles 00:12:54.125-->00:12:59.125 ship with a sim card for Jasper Wireless connected car cloud according to Wikipedia, eleven 00:13:02.083-->00:13:08.417 different automotive manufacturers use this service which basically, they have a sim 00:13:08.417-->00:13:14.083 card for Jasper that roams on all the different networks and sends the data back to Jasper 00:13:14.083-->00:13:19.750 where it is transmitted via a VPN to the automotive manufactures back end server, 00:13:19.750-->00:13:26.583 but if the owner, or someone else has taken the sim and replaced it with their own sim, 00:13:26.583-->00:13:32.833 it bypasses all that hard coded routing and just goes out the real internet, so, that's why 00:13:32.833-->00:13:39.208 it's ending up coming to our server so, this is interesting and cool, but, it's not a common 00:13:39.208-->00:13:45.542 thing, we have seen posts on various web forums about people replacing the sim for various 00:13:45.542-->00:13:50.833 reasons. We know this is happening to a number of people, but maybe we can find something 00:13:50.833-->00:13:55.833 more interesting. [silence]. >> Moving from the car to the whole web angle, to a different 00:14:01.667-->00:14:06.667 aspect, let's look at the telematics. Um, what is the telematics? It is the module 00:14:14.083-->00:14:20.000 that connects the car to the internet. It's basically the cell modem in your car. In this 00:14:20.000-->00:14:25.000 case it's a continental made TCU, We found, we, got one with the car, but, [whisper] well 00:14:28.167-->00:14:33.167 what was left of the car. And we wanted more because we’re kinda hackers, we want to tear it 00:14:36.458-->00:14:41.167 apart and look at it. So, we go on ebay, and we find like 20 for twelve bucks. We’re like 00:14:41.167-->00:14:43.167 ok,cool. So a little bit more information about this telematics unit. Its using 2G 00:14:43.167-->00:14:45.167 networks, yeah, [laughing]. Only 2G, It sits on the can bus, this is the speck for it. It's 00:14:45.167-->00:14:50.542 connected to all kinds of devices on the can bus , we’ll get to it later, and a little 00:14:50.542-->00:14:55.542 bit deeper. But, let’s look under the hood. The top of the telematics unit um, is very 00:15:16.625-->00:15:20.833 simple. You can see the sim card on the right, and you can see at the bottom there is a USB 00:15:20.833-->00:15:27.583 footprint on the PCB, they gave us a good indication if you can, [whisper] I don't know if I can 00:15:27.583-->00:15:33.667 show it. If you can see from the bottom footprint there's a thick line going to the right and up, 00:15:33.667-->00:15:38.500 those are the traces for the USB to go to the top right connector. So, we now know 00:15:38.500-->00:15:43.125 there's a USB connection going through there, we also found out on the speck that it’s also 00:15:43.125-->00:15:48.292 documented there. So now let's flip this thing and look at the bottom. See, there’s a lot more 00:15:48.292-->00:15:53.833 chips on the bottom, it’s more interesting there. So there’s a big one and a cluster of small 00:15:53.833-->00:15:59.917 ones. So, to break it down a little bit. The big chip is the free scale chip that is used to 00:15:59.917-->00:16:04.917 connect to the can bus. The cluster, or the complex to the right is the tuchi cellular 00:16:07.208-->00:16:12.917 complex. There's a bunch of chips, there’s a baseband processor, there’s a flash chip, 00:16:12.917-->00:16:17.250 [clears throat] excuse me. And the bottom left you see there’s a footprint. So i'm gonna go 00:16:17.250-->00:16:23.292 back one and show you, there’s a little arrow there, uh, that’s my way of indicating pin one. 00:16:23.292-->00:16:28.292 That’s a footprint that we kind of recognized from previous hacks with freescale processors 00:16:31.958-->00:16:36.958 that we had laying around so we had the debugger we just solder header on it and plugged her in 00:16:39.125-->00:16:44.125 so we got some of the firmware off we- we didn't manage to get the whole of it, but let’s put 00:16:46.333-->00:16:51.333 it aside for a second and keep looking. Now we know the radio is connected to the TCU over 00:16:54.833-->00:17:00.833 USB. So lets man in the middle that USB. We have a USB interposer so, a couple of 00:17:00.833-->00:17:06.958 custom cables later, and after realizing we have no cell signal in our lab, we had to put it on 00:17:06.958-->00:17:12.917 two office chairs and roll it next to the window. [laughing]. Then we boot everything up, you 00:17:12.917-->00:17:15.833 see the power supply on the right. We had to change it because we didn't have enough 00:17:15.833-->00:17:21.792 watts. So, we plug it in and boot it up and we look at the communications and we see the 00:17:21.792-->00:17:28.500 USB in numeration, it says, Comneon. Does anyone here, does it ring a bell to anyone? No? 00:17:28.500-->00:17:34.958 Ok. So we keep looking at it, and we see AT commands going on USB. You see on the left, you 00:17:34.958-->00:17:36.958 see GPS coordinates going on. And on the right you see the setup where it establishes the 00:17:36.958-->00:17:41.958 cause with the TCU telling it this is the vin your on, this is the user and password, all that. 00:17:46.625-->00:17:51.625 And were like this is very familiar, then it hit us. Let's take a look at the chip, does 00:17:57.875-->00:18:02.875 anyone recognize this chip? No? Lets try it again, here’s a hint. [silence] No? Ok. This 00:18:09.417-->00:18:14.833 chip was used in the original iPhone. The, what’s its called, the iphone 2? Not the iPhone 00:18:14.833-->00:18:19.833 two, the iPhone. >> No the original >>Yeah no number the iPhone no number. >> So yea this 00:18:21.875-->00:18:26.875 is the infinium PMB 8876. It was in the original iPhone not even a 3G. So uh, then uh, like it 00:18:30.208-->00:18:35.208 has, it’s basically a 2G cellular modem. But, uh, this does not mean that your car runs 00:18:38.458-->00:18:43.583 iOS, this is the baseband processor not the application processor. So, uh, we wanted to 00:18:43.583-->00:18:50.208 take a closer look at it. So we basically wrote a little python USB wrapper to talk to this and 00:18:50.208-->00:18:55.208 you can send it AP commands like, the vendor, model, there’s the sim MZ at the bottom there. 00:18:58.542-->00:19:03.542 But because it's effectively an iPhone chip set, why don't we try and see if the old classic 00:19:06.250-->00:19:11.583 vulnerabilities are there. So I believe the ATX app vulnerability was found in 2007 00:19:11.583-->00:19:18.208 and publicly disclosed then so, we try that and, it causes our TCU to crash and reboot. Then we 00:19:18.208-->00:19:23.125 reconnect to it, and one of the nice features about this baseband is that you can 00:19:23.125-->00:19:28.250 actually read the exception log, and we can see that we generated an exception, we have the start 00:19:28.250-->00:19:32.750 of the data here, and we scroll down a little bit further and here's part of our stack where 00:19:32.750-->00:19:38.208 we’ve got our forty-one characters from the A’s, that's the start of the stack. And then 00:19:38.208-->00:19:44.542 we scroll down a little bit more and there's the registers so. We have the registers, there being 00:19:44.542-->00:19:48.833 filled in with the forty-ones from the stack overflow. Including our fifteen which is 00:19:48.833-->00:19:53.833 our program counter. So we now control code execution at this point. So, we tried the other 00:19:56.167-->00:20:01.167 ones SDKPROF. X log, FNS, those all worked also. So, this is cool, but, it still requires 00:20:03.833-->00:20:08.833 that you own the IVI in order to exploit this. So, um, in this particular vehicle there's two 00:20:11.250-->00:20:17.875 different can busses, the IVI is on one, and then there's the TCU on a different one. So 00:20:17.875-->00:20:22.875 potentially you can jump from one can bus to another by exploding this. So that makes it 00:20:25.000-->00:20:30.000 interesting but it’s still, I think we can do better than that. So, in the iPhone, it was 00:20:33.250-->00:20:38.750 actually found in the 3G, there was an over the air over flow, um, found by Ralph Phillip 00:20:38.750-->00:20:43.750 Wineman, and published in 2010. There's a timsy field in the GSM protocol where it’s 00:20:47.542-->00:20:53.583 specification specifically says, this must be thirty-two bits. But then in how it’s actually 00:20:53.583-->00:20:58.583 encoded in the protocol, it’s a TLV field which means it can be dynamically sized. So we can put 00:21:01.333-->00:21:07.125 sixty-four more, like seventy-two more more bits in this field that the spec says it 00:21:07.125-->00:21:12.125 must be thirty-two. And were like this is cool, let’s try and do this. The iOS [inaudible] 00:21:16.458-->00:21:21.458 handbook actually has a chapter describing this vulnerability, and on page three-fifty-six, it 00:21:23.583-->00:21:29.125 actually has proof of concept code, that you can use with openBTS. Basically you are 00:21:29.125-->00:21:34.750 emulating a malicious base station, and letting the car connect to you and then sending 00:21:34.750-->00:21:39.750 a timsy reallocation command. And overflowing it with an overlong timsy. And openBTS, by 00:21:43.250-->00:21:48.250 now they’ve basically removed the test call functionality which this proof of concept in 00:21:51.833-->00:21:57.667 the book depends on, basically they didn't want to make it easy for people to use this to hack 00:21:57.667-->00:22:02.125 the cell stations that they were trying to deploy. There’s a little bit of controversy 00:22:02.125-->00:22:06.958 because they thought that was security through obscurity kind of silly. So people forked it 00:22:06.958-->00:22:12.750 and we were able to find other versions that had this test call reimplemented but we also needed 00:22:12.750-->00:22:18.917 a faraday cage because it’s a licensed spectrum and we can’t broadcast in the spectrum 00:22:18.917-->00:22:23.792 without a faraday cage so we got a faraday cage, we put the TCU, antenna, and raspberry pie in 00:22:23.792-->00:22:30.208 there, we could try this out. Heres another shot of us actually with a going, we got a 00:22:30.208-->00:22:36.833 blade RF, software to find radio feeding the antenna in the faraday cage, trying it out. We 00:22:36.833-->00:22:41.833 originally, we were trying with a USRP software to find radio, we had some hardware issues, and 00:22:45.208-->00:22:50.208 just general flakey behavior. And after, we had a discussion with Jared Boon, and talked to 00:22:53.250-->00:22:58.875 him about the problems we were having and he helped us realize what was wrong. And it turned 00:22:58.875-->00:23:05.125 out that this specific USRP model that we were using didn't have strong enough frequency, or 00:23:05.125-->00:23:11.625 didn’t have good enough frequency stability to keep a cell phone connection with this 00:23:11.625-->00:23:16.625 older infineon chip set so, that mis match caused us a lot of problems and banging heads, 00:23:19.000-->00:23:22.583 because it would start to connect and then it wouldn't keep the connection because it 00:23:22.583-->00:23:28.208 would drift off. So, after a while we were able to fully confirm over the air exploit. 00:23:28.208-->00:23:34.792 This is actually a screenshot of a text message that I sent Micky while he was driving to a 00:23:34.792-->00:23:41.042 conference to go present somewhere else. So, we finally got this working, we wanted to 00:23:41.042-->00:23:47.917 thank Jared for his help here, but in this case also we control registers who had arbitrary 00:23:47.917-->00:23:53.042 access, we control our fifteen program counter again so, we have remote code execution 00:23:53.042-->00:23:58.042 potentially because we control the program flow. So, where can we go from here? We don't have a 00:24:02.708-->00:24:07.667 copy of the firmware because we didn't have a good way to extract the firmware, we could 00:24:07.667-->00:24:13.458 just talk it. One interesting thing is that the original apple hackers they were able to 00:24:13.458-->00:24:17.458 download the firmware off of apple's website and extract the baseband firmer and start 00:24:17.458-->00:24:24.000 reversing it from there. But we need to actually exploit one of the existing vulnerabilities in 00:24:24.000-->00:24:29.625 order to extract the firmware itself. And we do have that exception log that has 00:24:29.625-->00:24:35.042 registered state when the system crashes and we also have some of the stack. We have a small 00:24:35.042-->00:24:39.792 amount of stack value. We do have to reset every time in order to get that exception log, 00:24:39.792-->00:24:44.792 but we can work with that. So, at this point we pulled Oleks in to help us out. >> Thank you 00:24:48.708-->00:24:53.708 Jason. So, it was just mentioned we don't have the firmware, but we have a bunch of information 00:24:57.042-->00:25:02.042 in our crash exception log like system stack and registers, um, so, that's enough for us to at 00:25:04.667-->00:25:09.667 least play a bit, to understand at least what kind of protection this chip has. Because if it has 00:25:13.167-->00:25:16.792 old protection like [inaudible] and all the software protections, then it will 00:25:16.792-->00:25:20.500 [inaudible] barley hard to exploit the blind [inaudible] liability. So let's try 00:25:20.500-->00:25:24.542 [inaudible], and what kind of protections is there. So we ran it a couple times and see the 00:25:24.542-->00:25:29.542 address, and the address was not changing. So there's no SOL, which is really good, but not 00:25:33.875-->00:25:39.500 enough to make the final exploit. So then we start playing a little bit, because we 00:25:39.500-->00:25:44.875 controlling the air fifteen prime counter, we may to jump somewhere to see if [inaudible] 00:25:44.875-->00:25:49.875 is good or not. And also we can spray a little bit like around [inaudible] or around some 00:25:52.333-->00:25:58.250 instructions like jump or air four, and we can spread them through the same buffer, up to 00:25:58.250-->00:26:03.250 two hundred twelve bytes. So the spread of one instruction which is jump to air four, and then we 00:26:06.625-->00:26:12.792 tried to loop and send jump to that that instruction. So then finally when we got the 00:26:12.792-->00:26:17.792 execution we figured out there’s no bet at all, and also the stack is executable. Basically 00:26:20.375-->00:26:25.375 there is no protection in the chip at all. And then later on we checked the configuration of 00:26:27.375-->00:26:32.375 the MMU and it will tell us the memory protection and the value is 300 in that specific register 00:26:37.750-->00:26:42.750 meaning that it will allow to rewrite and execute any segments in the memory. So that’s a 00:26:46.667-->00:26:52.792 really good expectation of the exploitation. From here, [soft voice] that’ s another 00:26:52.792-->00:26:57.792 indication of, uh, from here we understand that we need to somehow run a show court more 00:27:00.542-->00:27:05.542 stable so we spread the nops and put in our shell court [inaudible] in the stack, then 00:27:08.292-->00:27:13.292 we jumped to that shell court later. So pretty old school techniques, but now after we 00:27:15.458-->00:27:22.208 have the court execution we need to run some post exploitation shell court which will allow us 00:27:22.208-->00:27:26.833 to make the next step, but what is the next step? It's not the full OS, you cannot run the real 00:27:26.833-->00:27:32.292 shell. But we really want to investigate what kind of can messages we can send, what kind 00:27:32.292-->00:27:37.583 of protocols does it support. Does it support UR and so on. So to make this happen we need to 00:27:37.583-->00:27:42.583 extract the firmware. But we cannot print the firmware. But we have the login information 00:27:44.958-->00:27:51.375 which Jason [inaudible] so we were thinking bout let’s use this log buffer and copy the 00:27:51.375-->00:27:56.375 firmware to this buffer and then extract this buffer combined it together to get the final 00:27:58.833-->00:28:04.625 firmware image. So for [inaudible] we extract two hundred twelve bytes and we have 00:28:04.625-->00:28:09.625 [inaudible] checked before enough to make sure our shell court is runny successfully and 00:28:09.625-->00:28:14.333 we dump the two hundred twelve bytes to the stack which we will print in the next [inaudible] 00:28:14.333-->00:28:19.333 when we run the log comment. In this case the rest of the instruction, we will jump to 00:28:23.000-->00:28:28.000 [inaudible] to make sure exactly the control dump will be on the log after reboot. So again run 00:28:31.917-->00:28:37.292 an AT log after reboot and you’ve got two hundred twelve bytes. So that’s the example of 00:28:37.292-->00:28:42.292 that log we have [inaudible] we have air fifteen which is invalid address to make sure we 00:28:44.375-->00:28:49.542 stop at a specific moment, and then before that [inaudible] we have the dump of our five 00:28:49.542-->00:28:54.542 hundred twelve bytes. And then we do it fourteen thousand times to extract all the parts of the 00:28:58.917-->00:29:03.917 firmware and then we can combined it together and then now we have the capability to 00:29:06.458-->00:29:11.458 reverse engineer to find what protocol it supports and to build an entire picture of post 00:29:14.750-->00:29:19.750 exploitation. From here Jason will continue. >> So, one other point with this is that we now 00:29:27.917-->00:29:32.917 have extracted the firmware, most of the address spaces are at a fixed location but there 00:29:35.667-->00:29:41.750 are some dynamic memory allocations that are happening so, we can read the firmware and 00:29:41.750-->00:29:47.375 have a reliable read from the firmware but the SRAM is moving around a little bit and 00:29:47.375-->00:29:51.833 sometimes the pointers and structures don't entirely make sense. We have to crash and 00:29:51.833-->00:29:56.833 reboot in order to read every single block and I think this took what, four tor seven days? 00:29:59.958-->00:30:06.167 [whisper] Seven days to read this and get the entire block once, because it reboots it has 00:30:06.167-->00:30:11.167 to wait a few seconds before it can connect again. But once we’re able to do this what can 00:30:13.833-->00:30:18.833 we do from there? The impact of this is very vehicle specific so, like this particular device 00:30:22.375-->00:30:28.875 can be connected different places different architectures in different cars so, in the 00:30:28.875-->00:30:33.875 vehicle we found it in its connected to the EV ken this way's which is connected to the 00:30:38.500-->00:30:45.208 power delivery module the traction motor inverter the AC amplifier controls and then the 00:30:45.208-->00:30:52.042 lithium ion battery pack. In other vehicles it will be different and there will be 00:30:52.042-->00:30:57.042 different things happening there, so. This TCU does have the ability to send can messages 00:30:59.958-->00:31:04.958 on the bus, it was originally designed to work with the vehicle immobilizer so it could 00:31:08.583-->00:31:14.458 receive a message and block the starter. We don't know if that actually works, or we don't know 00:31:14.458-->00:31:20.167 if it’s hooked up because we don't have a full car. We did ask a few people if we could 00:31:20.167-->00:31:25.750 borrow their cars, and they were like hell no. [laughing] you can't even drive by my 00:31:25.750-->00:31:30.750 house.[laughing]. So we don't really know what the full ramifications are at this point 00:31:33.042-->00:31:38.042 but it will very, specific vehicles are different. So for conclusions, as of Thursday this 00:31:46.375-->00:31:51.375 ICF cert advisory went out. Basically CVS version three 8.8 remotely exploitable, low skill 00:31:54.250-->00:31:59.833 level to exploit, public exploits are available it’s for the Continental AG infinite 00:31:59.833-->00:32:06.333 SKull that contains the infinite SKull stack based overflow. We do have some affected products. 00:32:06.333-->00:32:12.333 We know that BMW and Ford have a few models, we don’t know how many, but basically any 00:32:12.333-->00:32:18.792 telematics control modules built by Continental that contain this chip set are affected. I’d like 00:32:18.792-->00:32:23.792 to talk a little about just how these chips were distributed around. Originally the chip and 00:32:28.458-->00:32:34.250 the baseband firmware, the reference waistband firmware came from infineon, it then went 00:32:34.250-->00:32:40.417 to apple though showed up in the iPhone. And external researchers found vulnerabilities in the 00:32:40.417-->00:32:47.375 baseband firmware. One thing I thought was really interesting was the timsey overflow, the 00:32:47.375-->00:32:52.375 original advisory for that only mentioned iPhone 3G and later, but we found this same chip that 00:32:55.292-->00:33:01.292 was in the original iPhone. So I was wondering if the original iphone actually was vulnerable 00:33:01.292-->00:33:07.083 and they just didn't care, because the phone market moved so much more quickly. And that 00:33:07.083-->00:33:12.167 kind of brings me to my next point is that these are different market segments, like 00:33:12.167-->00:33:17.167 there’s been large focus on mobile phones,everything going in there for over twelve years. 00:33:20.833-->00:33:27.625 This particular vulnerability was found ten years ago, and made public ten years ago. But 00:33:27.625-->00:33:33.458 these chips also went to the automotive market segment where only these last few years have 00:33:33.458-->00:33:38.458 been this heavy focus. So, we're just now finding out that these things went other places and 00:33:41.333-->00:33:46.917 it’s possible they went to other market segments also that we don't know either. So, I think 00:33:46.917-->00:33:52.583 it’s really critical to understand that. I’d like to point out that this is not a O 00:33:52.583-->00:33:57.583 day, as of today this is a two thousand four hundred forty one day. But also the different 00:34:01.417-->00:34:06.417 market segments [clapping] [laughing] So the different market segments, they have 00:34:09.583-->00:34:14.458 different levels of security maturity and they can have very different product life cycles. 00:34:14.458-->00:34:19.333 Like mobiles phones, they expect you to upgrade your mobile phone and get a new one every two 00:34:19.333-->00:34:24.333 years. And vehicles, they don't even get the car out the door like within two years of the 00:34:26.875-->00:34:33.500 time they start producing this, so, there’s a very long development life cycle. There’s 00:34:33.500-->00:34:38.500 a very long in use life cycle. And the problem with this is, they can share components and 00:34:41.125-->00:34:46.792 you can have something with this very long life cycle that’s already been exploited years ago 00:34:46.792-->00:34:53.000 in another market segment, people just don't realize that. So you really need to be aware 00:34:53.000-->00:34:59.583 of security issues that could exist in your product that happen somewhere else. So, If 00:34:59.583-->00:35:04.583 you're designing and developing something that is important for your car, or your device or any 00:35:09.208-->00:35:14.833 other, maybe it’s a medical device. Like I don’t know, anything that you're working on 00:35:14.833-->00:35:19.833 you should look and see if the components in your device have already been owned, if there are 00:35:22.208-->00:35:28.708 any issues with any of those components elsewhere. This is a pretty interesting example 00:35:28.708-->00:35:33.708 because it survived ten years after publication. We would like to thank a few people. We would 00:35:38.208-->00:35:44.500 like to thank Nissan North America, they took this issue and were, they helped us and 00:35:44.500-->00:35:49.833 they did help us provide information to the supplier, they helped get information to 00:35:49.833-->00:35:54.833 other manufacturers. They were definitely responsive to this. We’d also like to contact ICF 00:35:57.500-->00:36:04.208 cert, specifically Jason Berkley, there was a period of time there where we’re calling 00:36:04.208-->00:36:09.167 him everyday to figure out what's going on, he also helped us to get information to the 00:36:09.167-->00:36:14.875 affected parties and coordinated everything, got the advisory out, we had a few rounds of 00:36:14.875-->00:36:20.833 drafts to make sure that it was as correct as we could get it. We also wanted to thank auto 00:36:20.833-->00:36:25.833 isack their industry coordination body that has also helped trying to get some of 00:36:29.375-->00:36:34.708 this information out to other members and other OEM’s. We also wanted to thank intel pcert 00:36:34.708-->00:36:39.708 because, it’s kind of funny because infineon was purchased by Intel, so when ICF cert was 00:36:42.875-->00:36:47.917 trying to get a hold of infineon, we were like, we can go talk to them, we know these 00:36:47.917-->00:36:52.917 people, you can get a call back from in an hour. We definitely wanted to thank pcert about 00:36:55.167-->00:37:00.750 that. We do have the advisory up here again so definitely go take a look at that [whisper]yeah 00:37:00.750-->00:37:05.750 yeah, It does have more information so, go take a look at that. [whispers]. So the next 00:37:10.000-->00:37:16.875 slide is the final slide, but before we do that, because we have to move the slides before 00:37:16.875-->00:37:22.625 we come to present to like PDF and USB and print any animated gifts and all that shebang, we 00:37:22.625-->00:37:27.833 need to do all this kind of stuff, we lost the slide. And it’s a really important slide, 00:37:27.833-->00:37:32.833 It basically says we couldn't have done this without previous work, and the previous work we 00:37:35.458-->00:37:40.458 mentioned is Charlie Miller and Chris Vlasak, and Mark Rogers, and the Keen Team, and Scott 00:37:42.583-->00:37:47.583 Helm, and their previous work on the Nissan IPI. So, it’s really important to mention if you do 00:37:51.083-->00:37:57.250 use some of others people work to give them credit, and I just wanted to do that before we say 00:37:57.250-->00:38:02.250 thank you. [applause]