hi my name is david rogers and uh really great to be at the car hacking village uh to give this talk uh talking about our hacking rig and um yeah let's let's get going so um my name is um david rogers i own a company called copper horse uh we're based in the uk uh my background is uh in in semiconductors originally and then in the mobile industry for the past 20 years i'm heavily involved in a lot of security related topics on the author of the uk's code of practice on iot security i chair the mobile industries fraud and security group globally i'm actually communicating to you from google today actually from a gsma meeting and of course i like cars and i like cats as well and i sometimes drive cars that are named after cats so yeah um it's great to talk to you and um so how do we end up with with the stuff that we're going to talk about here well uh so my company got involved in a consortium called secure cav which was looking at future connected and autonomous vehicle security and with a consortium together with siemens and a couple of universities looking at how we could at a hardware level detect security issues and also then actually prevent them in some way or report them and to explore what we could do around machine learning as well um it's an extremely interesting project uh it's led to a lot of work with uh an organization called which which is kind of like consumer reports uh in the uk um and also we we we uh through the hack community we've we've done some good work um as a result of b-size comrade in wales um we've done some good work um as a result of b-size comrade in wales now uh have a partnership with uh carlisle university we've actually uh sold one of these rigs to them and we're doing continued research on this so um our our project was right in the middle of the pandemic and um our university partners were due to create some demonstrators and we were um due to do all of our security work uh on those demonstrators and of course uh the universities couldn't get into their facilities um so wanted to do some cool things around some of the tools that i'll show you later in the top but we couldn't do it and we basically had to to build something up ourselves and so we went down this road we looked at what was out there and there's some great things uh using arduinos and using canvas hacks canvas hats and um existing uh vehicle components uh so that's the road that we went down and um a couple of really cool projects where um they're using data from simulators from essentially from games and so we we started to build this up and we decided well actually this is really good and actually wouldn't it be fantastic if we can build this into a real a real car basically so we're taking telemetry from multiple different simulators multiple different games um now there are um academic simulators out there so probably people will have heard of the carla simulator but the community of people who are supporting um these kinds of simulators is actually quite small but the gaming community and the esports community is absolutely massive and uh the amount of cool stuff that's being created from hardware manufacturers through to um sort of individual software developers is is absolutely amazing and so uh so one of the things that we've been doing is we've been doing a lot of research and we've been doing a lot of research and we've been doing a lot of research and we've been doing a lot of research and things that we we decided to build in was uh was a motion uh rig which um we got from the dof things that we we decided to build in was uh was a motion uh rig which um we got from the dof reality in ukraine um and has been absolutely amazing and really gives us a real realism of actually how to experience a vehicle being hacked um so we have this um a three dof motion simulator uh which gives us a traction loss at the back there so we see that motor number three there uh so you know if you're slipping especially if you're racing um it gives you that real immersive immersion uh and of course if you crash into a wall uh without any brakes and you really feel it so we've been gradually sort of building this up alongside all of our security work um with this with this car network but then with with all of this telemetry going to these different components that are doing different things and we're gradually uh sort of building that up um so uh we we have a you know very straightforward canvas with with some components on it and so what else can we do well obviously we could put things like um sensors on there and we can connect up um other in-vehicle components um at the time uh so it was we we were loaned some vehicles uh to have a look at um and we also um we because we were in the middle of a pandemic um we could have a look at some of the things that we could have done in the middle of a pandemic um we could have a look at some of the things that we could have done in the middle of a pandemic really access for example scrap yards they were all completely closed so we started to go around down the road of looking at other sort of third-party components and we actually ended up with looking at some of the the aosp head units that are quite cheap on on amazon and ebay and found some some horror stories in those things um but um we we were able to get them working um when when we were building up the um the network itself um presented a so obviously we needed to be able to take that so say the telemetry from the simulators and then transmit that um into into the canvas and we we found a good way of doing that um there's a really cool tool called simhub um that allows us to do that more easily because some of the telemetries are set over udp or some of it's done by memory scraping and of course the games community have done a lot of the hard work so we chucked that into their motion rig and other components but but but So when we were looking at the head units, what we were really interested in was head units that were connected to the CAN bus itself. And there's a lot of research to be done here. I don't think there's been a huge amount done so far. So you can see here that this is directly connected to our CAN bus and to our simulator. And this little red box that you can see on the right hand side there is this kind of CAN bus converter box. And a lot of these Chinese Android open source head units actually use these boxes. And it seems there's a sort of proprietary serial protocol going to these things. And then they have the sort of pre-selected CAN dictionaries that are selected by choosing. Individual apps that are pre-installed on these units and these companies clearly all talk to each other because they all sort of co-support the different manufacturers of these little boxes and these CAN bus adapter units. And these devices, these head units are designed to be put into legacy vehicles. So you can imagine the security risk. And we're looking at, you know, what is on here, what versions of Android are on there? You know, we can see that they've actually managed to hack in the Play Store onto there. They've got Google Maps, they've got Chrome browser. So the question is like, you know, does a Chrome browser auto update on a device like this? And to what extent is the user exposed to existing vulnerability? And, you know, what's the differential between what's going to be patched and what's not? And really, is it possible to, you know, cross into that CAN bus from malicious Android app that's on one of these legacy head units? It's something that we're exploring with Cardiff University as well at the moment. A very, very interesting area of research, I think. What we also decided to do was to build in some functions to at least demonstrate to people what would happen if we disabled certain functions in the vehicle. So, for example, we thought it would be quite cool just to be able to cut off the brakes or to remove the clutch function or the accelerator. So pretty straightforward, just a hardware hack. And you can see my sort of Heath Robinson wooden button with some nails in it at the top left there just to kind of prove it out. And we built this, we built this box, which allows, you know, somebody who's next to the rig, so this is actually a B-size London, to be able to disrupt the driving experience of the person in the car, whether that's distracting them by turning on the wipers or causing disruption to other drivers by turning on hazards. You know, this sort of low level functionality in vehicles can sometimes have a very big effect. We have evolved that somewhat. So we've added in new functions. And as I learn, you know, what works and what doesn't work, I'm sort of building that into the rig. So we have some at the moment, we started out with Logic G29 pedals, Logitech G29 pedals, and essentially wired all that in so that we can turn them off at will and then turn on other functionality. If it's supported in the simulator, of course, because it depends, you know, what game you're playing or what simulator you're using. But it's a really, really useful tool to actually see how drivers react and to really cause a lot of trouble to them. So there's a sort of, there's what you can actually do in a car. So obviously, you know, it's not possible to reach some certain functions because of certain security that exists or some electromechanical things. So we need to kind of ground it in reality a little bit. But it's still fun to explore the kind of what if scenarios around these things. But to come back to like the core reason that we built this stuff in the first place was actually to look at some of the types of hacks that are out there or that could happen. And I always like to look at stuff that is actually going on right now and what criminals are actually doing, something that we've done in the mobile phone world. And so one of the kind of criminal mods out there, is around mileage correction. So you can kind of get these essentially man in the middle devices that you can buy through online sites. We could get these for about 300 euros for specific vehicles. And we wanted to explore how they worked, what they're doing on the CAN bus and how they operate without obviously having to put it in a real vehicle. Because in most countries, if these things are not outright illegal, for example, in the UK, you would have to declare that you have this thing in a vehicle. And obviously that's going to affect the resale value. So it's not illegal to buy one, but it would be illegal to essentially use one and not tell the new owner that you'd used one. But of course, you know, people are using these things. There is obviously a market for them. So the way that they work is that you install this thing and then you flash the headlights four times and it switches the mode of the mileage corrector and gives feedback to the user because it's behind the dashboard. And it flashes the hazard lights the number of times depending on what mode it is. So, you know, you might get four flashes for a particular mode. And what you see is that it's not actually stopping the odometer. It's slowing it down. It's slowing it down because it's kind of manipulating the speedo. And essentially so it is clocking up the mileage more slowly. It's very subtle because there are databases out there that, you know, log your mileage when you take your car to the garage and so on. And of course, if that thing is static, that's going to be very, very obvious very quickly that you've been tampering with a mileage. So and particularly for sort of more modern classics that people want, you know, people want to have a look at these databases and actually check that they've got the vehicle that they have got. And it's not unusual to see this sort of slow down in the curve of mileage anyway, because obviously for something like, say, a 993 911, it's a modern classic. People don't want to buy it. They want to put a lot of miles on them. And it might be very difficult to see the usage of it. And the reason that people are putting these things in is obviously to increase the resale value primarily. Because if you can, I don't know, take the 911 example, if you can keep that thing under, you know, 100,000 miles, that is going to get you a premium on the resale. So we were able to install this thing. And our network, and it's actually on our rig now, and we can actually operate that using the rig and actually while we're driving along in the simulator, which is really, really cool. And it actually is just an example of stuff that not only can we demonstrate how it operates, we can actually monitor the CAN bus and see what the CAN traffic is. Obviously, we can reverse engineer the hardware as well. But it's a very nice way of doing that. And we could potentially do that with other components for particular vids. And of course, there are a lot of tools that are out there. So if you just take OBD2 dongles, for example, now some of them are completely legitimate, but there's other more nefarious tracking devices and so on. Usually they're accessing the same data and then adding a bit. So they might add some GPS information and then send that over the mobile network. But there are other more interesting OBD2 dongles. One example that I was told about is for essentially spoofing the AdBlue check for lorry drivers, so that the vehicle is fooled into thinking that it's full of AdBlue. And obviously, AdBlue is extremely expensive and particularly for trucks. So. You can see how that market is created for those sorts of tools that exist. So we can use our rig to explore these kind of devices and what they do to a limited extent. So, yeah, there's a lot of potential in this platform for exploring different tools that are out there. But in the project that we were looking at, of course, we were actually so Siemens were actually looking at, well, how can we detect this kind of malicious traffic, if you will, or anomalous traffic on the network? And then how can they secure it? And they were looking at it as a chip level. And there were some really, really interesting things done. But we were then going to actually look at how to how how we could actually break their system if possible or that proposed system. And that's what we went about doing. So. So in the process of doing all of this, because, again, we were in the middle of a pandemic, we had to work out how to do all of this remotely on multiple sites, basically in people's houses. And so we ended up being forced into creating a system where you could remotely test from anywhere in the world. The rig or the car or the set up. Where wherever it was placed. And so I think that's kind of a useful thing. And so we had a camera set ups. We had a few switch bots for switching on the hardware remotely where there were physical switches. And we had a bunch of VMS that were doing things like fuzzing and so on. And in the cases where multiple tools were running, we were able to set up some tools to, to essentially do OCR on what was on the screen and then auto type as to the next step. So we were eliminating sort of issues where we might catch something during fuzzing or some kind of crash or something in the middle of the night. And then have to wait before we continue to the fuzzing. We could actually automate that, capture the crash and then do something about it. So, so really, really cool. And I think there's some real. Potential in kind of working on that stuff in the future. For Karma manufacturers and for anyone else, really. So, so yeah, so this is the, this is the rig as it stands. And it was just kind of continued to be developed there. Got some nice little bezel removers. It looks a lot better actually when you're racing. Your brain actually completely removes the bezels there. Of course we could have gone for VR, but we've got real, real components on there. So we want to see the real data and how, how those needles work and so on. And, and to be honest, I'm a bigger fan of triple screens from an esports perspective as well. And obviously from an audience perspective, it's nice to kind of see this. So, so we get this sort of full, full visual experience. And it really, really is quite immersive. You can see we've also got stream deck on there as well, which is used for, for button control. And so on. So as, as we've, as we've developed the rig, we've, we've, you know, I mentioned that we had the Logitech G29 pedals and steering wheel, which is pretty much a sort of gaming, a gaming device. It's not that expensive, really. But I modified the pedals to, to allow for the switching off. But, you know, there's lots of things you can do. And there's a lot of community hardware modifications, as I said. So actually the way that these work, essentially they're, they're potentiometers inside them. And they're travel based. They're not pressure based. But there are some modifications out there that kind of create a more realistic feel. So almost to emulate like a load cell break. And if I want to buy load cell breaks from say Fanatec or someone like that, that sort of real racing breaks, they're really, really expensive. But you can actually buy some quite cool mods that turn your stock G29 pedals. They put a linear potentiometer into, into the pedal. And, and then have a much stiffer load cell style spring mechanism and everything. And it just, just adds an extra layer of realism to it. I think ultimately we will actually swap out those for real load cell breaks. But for now it just, just definitely enhances things. The same for, we've now kind of moved on from the G29 wheel itself. And put in a direct drive DD Pro Fanatec base. And a full size rim. And you can see there's the size difference there. And it really, really again enhances that realism and immersion. Especially, you know, what you want is for the person on that rig to actually believe that they're in a car. Because when things go wrong, and when we start to do some of the sort of quasi cyber attacks on them, or real cyber attacks, we want it to like be really, really realistic. So that, that's, that's really cool and works really well. Something else we did with the pedals as well. There's something called the Leo Bodnar Cable. So Leo Bodnar, a company based in, near to Silverstone in the UK, work with some motorsport companies. And they can, the cable essentially, gives you a much better resolution. So it takes it from 256 bits of resolution, or eight bits of resolution to 10 bits, which gives you essentially 1,024 bit smoothness to the original 256 bits. We've put things like seat belts on there. One of the recent mods I did was to put working lights, because we had all that data from the telemetry. And so I put a set of 12 volt relays in there. Hacking box and, and, and put some, just some motor bike lights that you, I think I got them for 20 quid on Amazon and just mounted them on the back. So when you put the indicators on or the running lights, whatever it actually is on the rig, and we can just keep adding that stuff, really it's just what I kind of, whatever, wherever our imagination goes. The one on the right that you can see there is, I see a rear view camera. So I mounted that over, the rear view mirror, the virtual mirror, and this is a set of Corsa Competizione. So in modern GT3 cars, they actually have these screens in their, in their cars. So I just kind of repurposed this dodgy head unit to, to put that in there. And the whole thing's actually transportable. So I can put it in a Ford Transit van and I don't have to kind of take it apart or anything. And you can see the boss there, pumpkin inspecting it as it's about to go to, to, to visit someone. Okay. So here, here we have the, the rig as you've seen in the presentation. We'll maybe see a little bit of the motion. You can see the lights here where we're kind of braked at the moment and waiting for, for me to drive. We, on, on the rig itself, actually we've, we've kind of expanded this with more expensive equipment. So we started out with Logitech, Logitech equipment. So the G29 wheel and pedals, we still have the Logitech pedals there, although these are heavily modified now. So we've put a, what's called a Leo Bodnar modification on there to increase the, the resolution of the pedals. And we've also put a load cell modification in there to make it more realistic. Of course, we could spend a lot of money and put a load cell pedals, set load cell pedals in there. But remember that we've actually modified the pedals, so that we can actually remove brakes and clutch and accelerator, but we probably will expand that in the future. So we've got our head unit here, which is connected over to the canvas, which I'll show you in a minute. And then this is our new wheel, which is a Fanatec wheel. And this is the DD pro. And the reason that I've put this on here as well as it gives you a really, really realistic driving feel. So the feedback and the force that you get, probably on the Logitech wheel, it's probably up to maybe less than two Newton meters of, of, of force in this, you're getting over eight Newton meters and you definitely feel it. I do a lot of sim racing as well. And you, the feel that you get of, of the road is much greater. So this gives people a more realistic driving experience. I've got a TH8A shifter on there. It's the first master. It's actually quite a nice shifter. I like it. We've got, we just put a custom gear knob on there. And all of this is connected to different software in the rig. So we have something called sim racing studio, which comes with the motion platform. And that's a really excellent piece of software. We also use sim hub for translating some of the telemetry, and we've got some nice scripts and, and software to go with that. I use a bunch of other tools as well. Some tools that we've written as well. And, and yeah, so we also have a handbrake here as well. The emergency stop button is for the motion rig. Cause it can get a bit crazy. If you ever, ever used beam NG, driving the car off the cliff is somewhat of an experience. This is the stream deck here. So you can see here that we've got the different controls. This is for the truck. This is a shortcut button I have here for, for doing a mileage correction. That's just going to flash the lights four times. But we can cycle through. We've got loads and loads of different, different SIM functions on here. And it's really nice to be able to, to, to, to use that. It's very nice feature. This other tool here is something called SIM dashboard. This allows me to send the telemetry data into another kind of visual tool, which is very, very cheap as an Android client for it's really, really nice. You can build your own dashboards. You can build other information as well. Again, just touching the surface of that, but we can probably do a hell of a lot of things in the future. So, okay, so let's have a look at some of the equipment that we've got here. So I'll start off with the mileage corrector. So that's the, that's the device that you get sent when you buy it. And this is actually plugged into the back of the, of the instrument cluster here. You can see that we have another one here. And so that would be hidden behind your dashboard. And obviously if somebody was buying it, buying the car, they might not know about it, but you might want to take it out before you sold it as well. We built alongside the custom hacking box for removing the, the, the accelerator and the brakes and so on. We also have this sort of custom box here. So this is the Arduino I was talking about with the canvas hat. We've also got an OBD2 connector here, which is useful for us for monitoring the CAN data. If you want to use any of the sort of tools that you can buy out there for car stuff. We also have, this is just a relay board here. So we just using the 12 volt relays. I did originally look at using MOSFETs, but the, the lights that I've gotten here are just basically sort of third party motorcycle lights that I've repurposed for the rig. And what they're expecting is actually, an output from a relay, not from a MOSFET. It would be wired differently. These boards are really, really cheap and it's really straightforward to integrate. So you can see we've got a selection of head units and things that we've bought. We'd be looking at reverse engineering these things. This is one that blew up on me, blew up power supply as well. So what a lot of these come with when, when they have a canvas connections, a canvas decoder, and it appears to us that there's some sort of proprietary, serial protocol going to these. And then through software, through the sort of pre-installed apps that they've put on these things, they, you will select a decoder for a particular vehicle platform. And that will essentially have a sort of pre-programmed can dictionary to enable it to talk to the canvas. And so somebody would just plug that into their car. And, and, and of course, I've seen lots of complaints about these things because of course, they're not perfect. What we're more interested in is things like pre-installed malware, what type of state these things are in, whether they're going to get software updates and so on. So you can see this is one here. It's just one of these head units and they often come with this kind of car menu and different car settings and so on. So in this case, we can see some of the data. So, this is actually will change. It's connected to our cameras here. At the moment, we just paused. So yeah, very, very interesting. We've again, only touched the surface of some of this stuff, but it allows us to play around with that and, and see what kind of things we can do. So the last thing I'll show you here is actually some of the extra components. So I told you about the, the rear facing camera, but interestingly, we got a TPMS. So here, so tire pressure monitoring. So one of my sort of little future challenges will be to add the TPMS into the rig as well and see how good or how bad these third party devices are. These are just the, the pressure caps. Okay. So let's get onto the interesting part. So I would love to bring this rig to Las Vegas, but it's probably not going to be possible. So I'm going to show you some driving. I also do, some drive alongs and stuff. So let's, let's get going. So this, this simulator here is a Euro truck simulator too. I'm actually in the middle of a delivery at the moment. You'll see that I do a lot of sim racing and stream that online. And that's with exactly the same rig and with the motion and everything. And I'm just going to drive along here. I'm just going to, I've got the motion turned off right now, but I'm just going to show you very quickly how the mileage correction works. So you see that I've got the full beam lights on here, driving along into the early morning. What I'm going to do, I'm just going to do the, the four flashes, right? And what you'll see is the response back from the hazard lights as it switches on. It switches modes and you'll see, you'll see the speedo do something as well. And these things can be a bit flaky as well. So, so it takes maybe a couple of times to actually activate and get it to go. It's to be the one time that we can't get it to go. So what I call David's rule of demos, the demos never work. There we go. So you can see it switched modes there. And you can see also the speedo has dropped down because what it's actually doing is causing the speedo to misreport. I'm just going to move outwards there. You can see the indicators. So hopefully it's going to switch modes again, get it to change. There we go. So it's flashed twice. It's moving into a different mode. And you can see there that it's flashing again. So that's how that works. If we move back, I'll just show you, if you just show the lights. So on the rear of the vehicle, if I just show you how that says, I'll put the hazard lights on now. And obviously I can put the indicators on as well. So, so there we go. And, and what we can do now is perhaps just pause for a second. So that's really what the rig's about. But I just want to talk about this whole thing about the future security in cars. So obviously we're demonstrating using older vehicle equipment and canvas hacks that, of course, we all know about. We all know that the canvas is not integrity protected and there's no authentication and so on. But it is quite nice. I mean, it functions as a thing. But obviously there's a lot of work going on in the standards space, but also in the hardware security space to actually ensure future security in cars. But that's not going to make threats go away. Threats are evolving and some really unusual things are happening. And just really like the mobile phone space where we've gone from just having kind of mobile phone calling and SMS capability, you know, all this extra functionality that you never expected to be in a car is in there. So all the functions for communicating outwards, and there are multiple SIMs and cars, need to be secured. And they're all coming from all these different vendors. So it's impossible for the OEMs to understand everything that they've got. And even for them, they're not really au fait about things like hardware security and how to implement TEEs and trusted execution environment type technology and how to properly implement secure boot. Build all of this together into certain things. And that's what we're doing at Kerman Hall. But the technology is moving so quickly that, you know, they're jumping into launching automotive ethernet on top of legacy technologies. They're launching V2X type stuff. So multiple new interfaces coming into vehicles and it's going at pace. So while we can bring a lot of our knowledge into that domain, and there is a lot of transfer, a lot of assurance of knowledge, everything from the stuff on SBOM through to like, as I say, hardware security through to mobile security improvements and to protocol security. So that is all coming together and they can kind of stand on the shoulders of all of that work and benefit from it. I still don't think there's a level of maturity in the automotive industry that is commensurate with the threat. And of course, you know, this is a, these are vehicles that are essentially weapons and can kill people. And it's a very, very unusual sort of moving IoT device. So I still have a lot of concerns. And I think that, you know, the security research community has to really help these guys to understand. They're still coming to terms with, you know, what, what CVD is, what vulnerability disclosure is and how to handle vulnerabilities in multiple places. And there are some sensitive ones. So of the obvious one being a lot of the car key hacks, but ultimately they, they need the security research community and they will benefit from our input. And I think it's just a case of kind of waiting for them to get to that state and they are getting there. And helping to point out to them the stuff that we see that maybe they're not going to see in a development center. And they're not going to think, well, or they may think, you know, why would you ever try this particular attack? No one would ever do that when actually we know that of course somebody would do that. So we bring a kind of hugely different skill set to what they have in engineering, but both are equally valid. So, yeah, I mean, I'm a little bit skeptical as to like how sort of attacks can be really detected in future vehicles on board. Because as an attacker, I probably am going to want to disrupt that. And I'm probably going to know that there's going to be some detection mechanism in there. So we really need to think like, well, one step or two steps ahead. So how does the attacker react to a particular defense mechanism? So, in the case of the mileage correction there, we were able to actually kind of attack the defense mechanism and really, really screw around with it. And, you know, for the defender, they have to make sure that everything's right. But as an attacker, I can just make sure that everything just dies and they still, you know, reach my objectives. So, I mentioned sim racing. So, I've really, really got engaged with sim racing during the pandemic and actually utilizing this rig. And it's been a really good way of actually talking to people who are in the car industry as well about the sort of threats and so on. And I compete in Apex online racing, a set of course of competition, only GT3 leagues and other leagues. And they're really, really, really fantastic. And I think the more people in the hockey community that get into sim racing, it'll be absolutely fantastic. But in a kind of another vein here, so I'm racing with the rig, but it's absolutely incredible to see that sort of line between real world racing and sim sports being crossed. So there's this sort of real mixed reality that's going on. And that's what we'll see in the future. It's really a gateway into the future. All of these circuits are laser mapped. The equipment, the Fanatec wheels, for example, they're in control. They're in the actual cars. So this is a real, real mix. And of course, even these esports communities suffer cybersecurity issues. And there's been a lot of DDoSing of servers. And the suspicion is it's actually gambling syndicates that are sort of betting on races and disrupting them. So really, really interesting in itself. If you want to find out a little bit more, well, of course, you can go to my Twitch and I've got a few live streams where we do drive along in trucks. That's Euro Truck Simulator 2 there. And we do different things in the simulator and we go around the rig and explain what we're doing. So have a look on there. There's quite a few more videos for DEF CON here for this event. And that's really it. So thank you very much for listening. I'm going to be in the room. So for those of you who are in the car hacking world, listening to this, have a look around for me because I'll be standing there somewhere. Thank you. Bye. Bye. Bye. Bye. Bye. Bye. Bye. Bye. Bye. Bye. Bye. Bye. Bye. Bye. Bye. Bye. Bye. Bye. Bye. Bye. you you you you you you you you you