[00:00.000 --> 00:03.240] All right. Good morning. [00:04.920 --> 00:07.900] Should I not talk too loud? Any of you guys got headaches? [00:10.980 --> 00:15.040] What's that? Pass the flask around. A little hair of the dog. [00:15.180 --> 00:19.940] Yeah, all right. Yeah, there isn't enough left in the flask. [00:21.100 --> 00:27.460] But so, yeah, I'll try not to bore you guys to death this morning. But thanks for turning out. [00:27.460 --> 00:32.820] Yeah, it is interesting times in the wireless village. I was originally scheduled for 7 o'clock [00:32.820 --> 00:39.380] on Thursday, but those darn EFF people got in our way. So here we are back. I'm going to do the [00:39.380 --> 00:45.160] talk that was originally scheduled for Thursday at 7 now. Bright and shiny early Saturday morning [00:45.160 --> 00:54.780] after all our great DEF CON parties. Yeah, I went to bed early. I went to bed early. [00:55.420 --> 01:01.660] 2 a.m., and the alarm went off at 6.45, and I haven't had nearly enough coffee yet. [01:01.780 --> 01:11.100] So all right, let's get started. We're going to do an introduction to the Nordic NRF24L01 Plus. [01:11.100 --> 01:16.700] It's a pretty cool wireless chipset that I had an opportunity to do some playing with for a [01:16.700 --> 01:21.220] project. We'll talk about that project and all of the stuff that went along with that. [01:21.780 --> 01:27.080] We'll see that within sort of this project and the presentation and some of the stuff that [01:27.080 --> 01:33.440] we worked on for this, this may also be a candidate for next year's fail panel. [01:33.640 --> 01:40.780] How many of you got to go to the DEF CON Comedy Jam panel? And yeah, we had some folks up there. [01:40.780 --> 01:46.580] The overarching theme of that is fail every year. And we tried to do something that was humorous. [01:46.580 --> 01:52.940] One of my coworkers and I, we hacked some Teledildonic devices. [01:53.520 --> 01:58.540] So we played and hacked with an internet and Bluetooth-connected vibrator [01:59.360 --> 02:07.580] for epic lulls. It was lots of fun. And it, yeah, owned all sorts of interesting social [02:07.580 --> 02:13.380] connotary as well. So the overarching theme of fail, people make mistakes, [02:13.380 --> 02:19.720] and there were definitely some mistakes that were made going into this. One of those being, [02:19.720 --> 02:25.580] you ever have that time when you take on one too many projects? Yeah, I'm about three projects too [02:25.580 --> 02:32.880] many too deep, and this was one of them. So there's sort of lots of exercise left to the reader. It is [02:32.880 --> 02:37.700] definitely an introduction to some of the capabilities of this Nordic Radio. But we'll [02:37.700 --> 02:42.300] give you some examples, some ideas as how you can use it. And it's definitely something affordable [02:42.300 --> 02:48.500] that you guys might want to start playing with. All right. So a little bit about me. I'm a hardware [02:48.500 --> 02:57.280] hacker and penetration tester for a small boutique consulting group called InGuardians. I just had [02:57.280 --> 03:04.160] my one-year anniversary with them. And sort of as a part of this project, my one-year anniversary [03:04.160 --> 03:08.640] right about DEF CON last year, I had a little impact into the project where I got introduced [03:08.640 --> 03:15.180] to this radio. And I'll explain that in a little bit. I'm also an instructor for the SANS Institute. [03:15.180 --> 03:23.200] I teach their wireless class, SANS Sec 617. So wireless security, ethical hacking, and defense. [03:23.260 --> 03:28.350] I'm also a member of the Paul's Security Weekly crew, formerly known as Paul.com Security Weekly. [03:28.860 --> 03:35.380] Yes, trademark disputes. We changed the name. It was going to cost us $15,000 to fight the [03:35.910 --> 03:43.480] Paul.com issue with no guarantees at the end. So we elected to spend $5,000 to rebrand and have [03:43.600 --> 03:50.120] a $10,000 party with a guarantee at the end. So yeah, it was a financial decision and it worked [03:50.120 --> 03:57.100] out. I'm also an extra class ham radio operator. My call sign's KB1TNF, Kilo Bravo 1, Tango November [03:57.100 --> 04:04.760] Foxtrot. Or if you're being funny, Kevin Bacon 1. That's not funny. Okay. How many of you guys [04:04.760 --> 04:08.300] are going to take your ham radio exams tomorrow? How many of you guys are going to show up and [04:08.300 --> 04:15.140] take the cram session at 9 to noon here tomorrow? Yes, come do it. It's totally worth it. Totally [04:15.140 --> 04:21.640] worth it. All right. All right. So I had a little inspiration for talking about this radio and [04:21.640 --> 04:29.500] learning about this radio. I participate as an event organizer and volunteer for the Mid-Atlantic [04:29.500 --> 04:36.240] Cyber Collegiate Defense Competition. It's a competition where college students create teams [04:36.240 --> 04:42.680] within their local university for computer security club or computer club. They participate in some [04:42.680 --> 04:48.640] local and regional events. The semifinals are held regionally. I participate at the [04:48.640 --> 04:54.020] Mid-Atlantic region that divided into a bunch of different regions. As part of my involvement [04:54.520 --> 04:59.600] for the last four years, I've created their electronic badges. And their electronic badges [04:59.600 --> 05:05.700] as part of their scenario have been what's considered in scope. They're a hackable and [05:05.700 --> 05:10.640] defendable asset and they're scored based on points as to what they do with these badges. [05:12.980 --> 05:16.820] Normally this goes pretty darn well. We have lots of time to work on the badges. We know what the [05:16.820 --> 05:23.780] theme for the next year's competition is going to be a year in advance. So basically the ride home, [05:23.780 --> 05:30.180] eight-hour car ride on the way home, my cohort and I start talking about what we're going to do for [05:30.180 --> 05:35.660] the badges next year on the ride home. Unfortunately, the year before we didn't have a good [05:35.660 --> 05:41.800] handle on what we were going to do. And right about that time, so actually not last year, [05:41.800 --> 05:47.040] the year before at Mid-Atlantic CCDC competition, I was actually participating in my exit interview [05:47.040 --> 05:52.920] for getting laid off while at competition. So I was leaving competition unemployed. [05:54.180 --> 06:03.040] That was kind of interesting. So to that, in that year, over the last year, [06:03.040 --> 06:07.300] things sort of got put on hold as far as examining stuff what we're going to do for [06:07.300 --> 06:16.380] last year's Mid-Atlantic CCDC competition. So I was unemployed, found a job, was a great job. [06:16.380 --> 06:21.440] I was there three and a half months and they laid me off. So I got laid off twice in a four-month [06:21.440 --> 06:26.700] period, which sucked. In that four-month, three-and-a-half-month period, we had a child. [06:27.060 --> 06:33.020] We have two kids. So yeah, we had a four-week-old at home who had just come home from the hospital, [06:33.020 --> 06:38.980] was three weeks early, and has spent a week and a half in the NICU. So needless to say, [06:38.980 --> 06:45.060] there was a little bit going on in my life outside of looking at badges for the Mid-Atlantic CCDC [06:45.060 --> 06:51.660] competition. It ended up coming down to two months prior. Oh, so my compatriot as well, [06:51.660 --> 06:57.100] Darren Wigley, had helped me for four years on building badges and coming up with a scenario. [06:57.420 --> 07:03.720] He also got laid off from the same company at CCDC the year prior and his new job had him [07:03.720 --> 07:10.900] traveling 90% and had just no cycles to give to me to help with the badges. So I was on my own [07:10.900 --> 07:17.500] and by the time it came down to it, I had exactly two months to come up with a scenario, build a [07:17.500 --> 07:22.660] badge, get it implemented, and then bring it to the competition. So I needed something fast and [07:22.660 --> 07:28.440] easy. Some of those design constraints for that particular badge were you're going to be handing [07:28.440 --> 07:32.560] this badge to a bunch of college students that may have never touched a microcontroller in their [07:32.560 --> 07:37.120] entire life, yet you're giving them a badge with a microcontroller that they have to learn how to [07:37.120 --> 07:42.960] program and defend in two days. Same thing from the red team side, the attackers that are [07:42.960 --> 07:47.440] attacking these students' networks. Some of these attackers are not hardware guys, they're software [07:47.440 --> 07:51.720] guys, they're web application security guys. They may have never touched a microcontroller in their [07:51.720 --> 07:58.520] life. So they need to learn how to turn the badge into an attack tool in two days. So it needs to be [07:58.520 --> 08:03.620] something that you can attack and defend in two days and do it fairly simply. Turns out this was a [08:03.620 --> 08:08.820] pretty interesting thing. I had some design constraints that I needed to think about for this. [08:08.960 --> 08:14.140] We're giving them to them as a badge, and so they need to be powered for two days. The badge needed [08:14.140 --> 08:18.380] to be powered with some fairly standard type of batteries. There was a budget involved. I couldn't [08:18.380 --> 08:25.320] spend two or three hundred dollars on a badge. I think I had the whopping price of $48 per person [08:25.320 --> 08:33.180] for a badge, which is pretty significant. The badge development effort is all funded through [08:33.180 --> 08:38.820] grants through the National Science Foundation for this event, as well as private donations and [08:38.820 --> 08:44.160] corporate donations as well. So there is a limit. I needed something that we could [08:44.160 --> 08:48.320] have low power that the students and attackers could wear around their necks for two days on a [08:48.320 --> 08:54.900] set of batteries. It needed to be relatively low cost and sort of low barrier to entry for the [08:54.900 --> 09:01.910] students to start figuring out what they needed to do. What ended up happening is I selected a [09:01.910 --> 09:06.330] set of radios because they ended up being fairly low power, fairly inexpensive, and easy to use. [09:06.630 --> 09:12.970] But additional research after the fact and during implementation time, I found these radios, the [09:12.970 --> 09:17.930] Nordic NRF 24L01 pluses, and I went, oh, these are going to suit my purpose. These are really [09:17.930 --> 09:23.230] neat. And then after I got them in my hand, I was like, these things are awesome. There's so [09:23.230 --> 09:27.270] much more that you can do with these with some hackery. And that's sort of what I wanted to [09:27.270 --> 09:32.710] introduce to you folks today. This is probably a radio chip set that many of you have never heard [09:32.710 --> 09:38.710] of but can have some really cool fun things and some potential security application for you as [09:38.710 --> 09:43.870] well. We're only going to take sort of a scratch at the surface. Many of those exercises left to [09:43.870 --> 09:47.630] the reader. I'm going to give you the introduction as to some of the things you can start doing, [09:47.630 --> 09:54.030] some challenges with those as well. So this is the display. We've got a setup here. Not quite [09:54.030 --> 10:02.050] as nice. What the badges ended up turning out to be were simulated aircraft ADS-B beacons and [10:02.050 --> 10:06.890] simulated because they had very little code space to deal with. So basically what ended up happening [10:06.890 --> 10:12.250] is that the badge just spits out an aircraft tail number. Hey, I'm aircraft this. And the [10:12.250 --> 10:19.030] radios have a fairly short transmit and receive distance. So we built a aircraft arrivals and [10:19.030 --> 10:25.730] board. So when they came close to the, quote, airport, the station here, the station would [10:25.730 --> 10:30.570] receive messages. And it would receive messages of a tail number. So we'd put them in an arrivals [10:30.570 --> 10:36.150] board. And every time a message was received, they'd reset the counter on the arrivals board. [10:36.150 --> 10:43.510] After that message was not seen for a five-minute period, it would move into the departures board. [10:43.750 --> 10:47.490] If we didn't see a beacon from an aircraft for five minutes, that means they're not there [10:47.490 --> 10:52.650] anymore. They've departed. After they were in the departures board for five minutes, [10:52.650 --> 10:56.850] that means that they're gone. This was also right about the time that the Malaysian [10:56.850 --> 11:01.570] airlines flight disappeared over the ocean. So there were all sorts of jokes there. [11:02.250 --> 11:10.530] Yeah. Completely unrelated. Yeah. Yeah. Yeah. What? Too soon? Okay. All right. [11:10.730 --> 11:15.050] All right. So a little bit about this radio. It's a 2.4 gigahertz radio in the ISM band, [11:15.050 --> 11:21.430] industrial, scientific and medical band. No license required to use. Just like your BGN [11:21.430 --> 11:27.570] wireless stuff, some BGN wireless stuff in the same frequency ranges. It's fairly low speed. [11:27.590 --> 11:33.950] Maximum data rate transfer is 2 meg. Typically we see them more often in the 250k to 1 meg [11:34.570 --> 11:41.890] range depending on application. It is very low power consumption for a radio. You can do all [11:41.890 --> 11:48.050] sorts of radio shut down over the radio with some of the various implementations. Requires 3.3 [11:48.050 --> 11:56.290] volts. And at a minimum, sorry, 3.3 volts at a minimum 1.9. So we'll take a set of batteries [11:56.290 --> 12:03.250] and drain those really well. Take them all the way down to make them unusable. Grab every possible [12:03.250 --> 12:08.790] amount of power out of them. So get some pretty decent battery life and it will continue to work [12:08.790 --> 12:16.590] all the way down to 1.9 volts. Uses Gaussian frequency shift keying, GFSK modulation. So for [12:16.590 --> 12:21.190] those of you doing some of the GNU radio, GNU radio companion stuff, we now know how we can [12:21.190 --> 12:30.330] potentially start decoding some of this stuff. The chip itself is a QFN 20 by 24 by 4 millimeter [12:30.330 --> 12:37.410] by 4 millimeter. 10 millimeter by 10 millimeter, sorry. QFN package. These things suck to solder. [12:38.410 --> 12:41.930] Hence, every time you're probably going to buy one, you're going to buy them on one of these [12:41.930 --> 12:46.750] breakout boards. This is actually some of the samples that I had in my home office. Some of [12:46.750 --> 12:51.450] these breakout boards that elude at higher expense actually include a RPSMA connector and you can add [12:51.570 --> 12:58.230] a standard 2.4 gigahertz antenna to it. So this has just got the like the 1.1 DBI rubber ducky [12:58.230 --> 13:02.970] antenna. There's no reason we can't go take an 18 DBI parabolic dish antenna and put it on here [13:02.970 --> 13:09.890] if we want to. So we increase in distance and have all sorts of good fun there. The standard [13:09.890 --> 13:18.810] version without the RPSMA connector, very similar to this one, in small quantity, quantity of 10 [13:18.810 --> 13:25.290] on eBay from China, they're about $1.10 a piece. I can buy a bunch of these things and throw them [13:25.290 --> 13:29.610] away if I want to because they're that cheap. You think about some of the other chipsets that you [13:29.610 --> 13:33.510] may be looking at, you know, Wi-Fi chipsets, you're probably going to pay $30 or $40 for. [13:33.870 --> 13:37.530] The breakout boards from SparkFun are going to be relatively expensive, maybe $50, $60. [13:38.690 --> 13:44.230] Bluetooth, Bluetooth Low Energy, you're probably $5 to $10 a piece. Zigbee, some of the stuff that [13:44.230 --> 13:51.850] I've seen for the development kits are about $40 on the low end. These are a dollar. That's good. [13:51.870 --> 13:56.950] And for a radio that costs a dollar, we can do all sorts of fun stuff with those. [13:56.950 --> 14:06.910] Okay. Some other interesting ones as well, the NRF24LU one also has built-in USB support, [14:06.910 --> 14:13.070] so it becomes a USB device. You can plug that into any USB port and access it over serial. [14:13.650 --> 14:19.630] The devices that we're looking at here are actually SPI bus, so a little bit different. [14:19.630 --> 14:23.810] We've got to have another microcontroller in between this device and potentially something [14:23.810 --> 14:27.890] else to use it. Those other devices are a little bit more expensive with the built-in [14:27.890 --> 14:33.430] serial support, and they don't necessarily integrate as well with a standalone microcontroller. [14:34.690 --> 14:42.570] All right. Within the Nordic NRF24LU one, they've got their own standard protocol called [14:42.570 --> 14:51.550] shockburst, and most notably advanced, sorry, shockburst enhanced. It does all sorts of fun [14:51.550 --> 14:59.190] packet stuff for us, very much like we'd expect for 802.11 TCP, you name it, it does packet [14:59.190 --> 15:06.870] assembly, CRC checksums, retransmissions, shockburst enhanced will handle all of this stuff [15:06.870 --> 15:12.930] for us. In the default mode. Plug it in, start sending packets to the radio, packets come out [15:12.930 --> 15:16.150] of the radio, received by another radio, shockburst enhanced, and we don't have to worry about [15:16.150 --> 15:25.190] anything. Awesome. And it costs me a dollar. However, we can take one of these devices and [15:25.190 --> 15:30.950] put them in what they call direct shockburst mode, which leverages us the ability to directly [15:30.950 --> 15:36.290] access the radio and craft our own packets within the limitations of the shockburst enhanced [15:36.290 --> 15:42.070] framework. There's some specific challenges to that. So we can implement with these radio chips, [15:42.070 --> 15:50.370] implement ANT, iBeacon and some Bluetooth low energy functionality for a radio that costs us a [15:50.370 --> 15:58.090] dollar. It's all done in software and not saved at the radio. We've got some links to the spec [15:58.090 --> 16:04.010] sheet as well. And I'm trying to remember, my images for these, for a lot of the slides come up [16:05.330 --> 16:10.770] as take the title of the slide, go to Google image search and take the first image that's [16:10.770 --> 16:17.270] decent and shows up. This is a Marvel superhero from like Marvel Saturday morning cartoon [16:17.270 --> 16:22.090] somewhere. And I have no idea which one it is. And I tried to remember which one it was. [16:22.270 --> 16:27.730] But it was the only one that actually looks cool when I put protocol in Google image search. [16:27.970 --> 16:33.250] So that's what we've got. All right. How do we interact with the radio? [16:33.250 --> 16:40.210] We're going to use SPI. When I started looking at SPI, I had never worked with SPI before I [16:40.210 --> 16:45.770] worked on this project for the Mid-Atlantic CCDC project. And I thought it was this voodoo [16:45.770 --> 16:51.770] and magic. Turns out you spend about 15 or 20 minutes with it and you'll get some pretty good [16:51.770 --> 16:57.870] ideas. I happened to interface mine with an Arduino. And I can hear you guys saying I hate [16:57.870 --> 17:03.190] Arduinos for microcontroller. I get it. But guess what? I had design constraints. They're easy to [17:03.190 --> 17:07.710] use. Had to have students that had open IDE that they could use. Didn't want to have to have them [17:07.710 --> 17:12.970] spend money to participate in this challenge. It's easy to use. Even a monkey can do it just [17:12.970 --> 17:19.230] like this one up here. Using SPI on the Arduino was actually pretty darn easy. [17:21.130 --> 17:28.010] So if you want to learn some more about the SPI implementation, Nordic Semiconductor and some [17:28.010 --> 17:33.130] other folks have got some great tutorials on understanding SPI. This was the one that I used. [17:33.690 --> 17:39.750] And SPI does allow us to have multiple of these serial devices on the same chain. So we can [17:39.750 --> 17:46.670] conceivably daisy chain multiple radios. Pulsing which ones are on and off. And we could conceivably [17:46.670 --> 17:51.990] do that with an Arduino as well. It turns out it's really not as much voodoo as you seem to think and [17:51.990 --> 17:59.810] ends up being fairly easy. So Larry, why the heck do we care about this stuff? Well, we're seeing [17:59.810 --> 18:09.690] the adoption of the Nordic NRF24L01 and L01 plus radios in all sorts of commercial devices. Max [18:09.690 --> 18:17.770] Moser and I want to say Dominic Spill actually spent some time as part of their Keyboard [18:17.770 --> 18:23.930] Sniffing Development Project figuring out which devices had some of the stuff. That's where some [18:23.930 --> 18:32.330] of the Ativa platform stuff. It's a voting platform for like when you go into like a [18:32.330 --> 18:36.550] closed caption studio audience type of thing. And you can vote on various things based on some of [18:36.550 --> 18:42.550] the shows and some of those types of things. Wireless device that you can do some voting with. [18:42.550 --> 18:49.250] The Nike plus portion that goes the beat portion that goes with your in your shoe that tracks your [18:49.250 --> 18:58.170] steps. Uses the Nordic radio as well. The Garmin Chirp for doing activity tracking for exercise. [18:58.670 --> 19:07.810] A whole bunch of unnamed medical devices. In this one, a Suunto sports instrument. [19:08.650 --> 19:15.070] This one's the Microsoft keyboard. The Logitech unifying receiver. How many of you guys have [19:15.070 --> 19:20.890] bought one of these Logitech wireless keyboards at like Staples recently with a unifying receiver? [19:20.890 --> 19:27.550] It's the one with the little like red star thing on it. Nordic NRF24L01 plus radios. In fact, [19:29.190 --> 19:32.390] I picked this one up at Staples last week for 20 bucks. [19:33.310 --> 19:38.630] And now we can have all sorts of fun hackery for a $20 keyboard and a $1 radio. A little bit more [19:38.630 --> 19:44.010] complicated. Various unnamed medical devices. I have a good friend that may or may not have [19:44.010 --> 19:49.970] hacked his own insulin pump and I'll leave it at that. Some of those type of devices that may be [19:49.970 --> 19:54.790] life-saving actually contain some of these radios and could have some pretty serious impact should [19:54.790 --> 20:01.470] some of that stuff go bad. So thanks to Travis Goodspeed. He spent a lot of time looking at [20:01.470 --> 20:09.210] some of these radios and interacting with these radios with the GoodFET, the interactive board [20:09.210 --> 20:15.850] for dealing with all sorts of fun devices, ZigBee and others, dealing with various wireless chipsets [20:16.910 --> 20:22.930] and all open source. I highly suggest if you're interested to pick one up, it's all open source. [20:24.330 --> 20:30.570] Travis, through some magic of math and implementation hacks, discovered that we [20:30.570 --> 20:38.090] can turn one of these Nordic radios into a promiscuous sniffer. It's a little bit convoluted. [20:38.090 --> 20:45.630] He's using some modes for the registers in the chipset to an invalid state at which point the [20:45.630 --> 20:50.150] radio says, oh, well, that's fine. I'll just turn the radio on and just spit you a stream of raw [20:50.150 --> 20:55.250] data. And then we can disable some of the other settings as well. So shock burst doesn't process [20:55.250 --> 21:02.570] stuff like CRC 32-bit checksums. And now we potentially have a $1 2.4 gigahertz sniffer. [21:02.570 --> 21:10.090] Okay. It does require some interesting hackery. It will not do channel hopping. The radio takes [21:10.090 --> 21:15.210] in radio terms, anyways, takes some significant time to retune the radios between the different [21:15.210 --> 21:20.410] channels for channel hopping and the time that is remaining for a lot of the protocols that do [21:20.410 --> 21:24.110] channel hopping. We don't have enough time left to actually do any processing on the packet that [21:24.110 --> 21:31.030] we receive. So it can't hop fast enough. But we can sit on one channel and listen for traffic as [21:31.030 --> 21:37.190] it goes by on that one channel. Very similar to how the Uber Tooth One operates for doing some of [21:37.190 --> 21:43.210] the Bluetooth sniffing. It sits on channel 39 by default and listens for all the packets go by on [21:43.210 --> 21:52.050] channel 39 when it hops 1,600 times a second. We'll get to this a little bit more. All right. [21:52.050 --> 21:57.290] So one of the things that we mentioned, we can do Bluetooth low energy. And for any of you who [21:57.290 --> 22:04.750] have seen Mike Ryan's talk on how smart is Bluetooth smart, you learn that Bluetooth low [22:04.750 --> 22:13.490] energy is all sorts of fail. They significantly reduced the channel hopping requirements, [22:14.180 --> 22:19.510] took out half the number of frequencies and the number of channels, shortened the frequency [22:19.510 --> 22:26.090] hopping time frame, and some various cryptographic failures as well. So it might be neat for us to [22:26.090 --> 22:32.770] start looking at some Bluetooth low energy stuff. The maximum data rate transfer for Bluetooth low [22:32.770 --> 22:38.650] energy is 1 meg, which is well within the duty cycle of the Nordic radio. It would do 250, 1 and [22:38.650 --> 22:47.370] 2 meg. So we certainly can do some of that. The problem is that observing and or transmitting [22:47.370 --> 22:53.810] some packets with the Nordic radio, the enhanced shock burst when we go into direct mode and [22:53.810 --> 23:02.170] disable CRC 32-bit checksum checks, the packet size is only 32 bytes long. Let me make sure I [23:02.170 --> 23:09.530] get that number right. Yep. 32 bytes long. But Bluetooth low energy packets can be up to 39 [23:09.530 --> 23:16.910] bytes long. Some of the packet types, depending on their advertising rates, we can fit and have fit [23:16.910 --> 23:22.690] in the 32-byte packet. So we only have the ability to sniff and or transmit specific packet types. [23:22.690 --> 23:28.870] Specifically, one of those is the advanced no connection indicator. Hey, I'm a device and I'm [23:28.870 --> 23:35.290] here. So broadcast packets. So we can observe broadcast packets and we can conceivably craft [23:35.290 --> 23:43.270] our own. However, also only on channels 37, 38 and 39, which is where all of these actually happen [23:43.270 --> 23:48.470] within Bluetooth low energy. All of the discoverable mode packets for Bluetooth low energy happen on [23:48.470 --> 23:56.350] three channels as opposed to 79 with normal Bluetooth stuff. So Bluetooth low energy sniffing, [23:56.350 --> 24:00.850] yes, I actually went to meme generator and created this specifically for this slide. [24:01.010 --> 24:10.270] I couldn't find anything in Google image search, so I went and made my own. It's not so easy to do [24:10.270 --> 24:15.690] Bluetooth low energy sniffing with one of these devices. The channel hopping is one of the ways [24:15.690 --> 24:21.750] that's going to come down to fail for us. The radio just can't hop fast enough for Bluetooth [24:21.750 --> 24:26.790] low energy to do connection following. But we could do very similar types of things like the [24:26.790 --> 24:32.410] ubertooth one does by listening on one or potentially implementing three radios and [24:32.410 --> 24:37.270] sniffing on just three channels. However, based on the packet size problems, we're only able to [24:37.270 --> 24:44.090] grab those advanced non-connection indicator packets. So we can find beaconing devices and [24:44.090 --> 24:49.350] potentially beacon devices ourselves. So some limited capabilities, but we only paid a dollar [24:49.350 --> 24:59.050] for it. All right. Have you guys heard of iBeacon? This is kind of neat stuff. Apple's [25:00.750 --> 25:07.250] pseudo-proprietary technology for doing location tracking. Some of the stories that we hear about [25:07.250 --> 25:15.830] Apple wants to see successes for iBeacon is to put iBeacon's devices within, say, grocery stores [25:15.830 --> 25:20.070] so that when you fire up your grocery store application and you walk around the grocery store [25:20.070 --> 25:26.510] and you show up in the toilet paper aisle, it knows you're in the toilet paper aisle and you're [25:26.510 --> 25:32.370] standing in front of the Charmin and it can beam a coupon for Charmin to your phone while you're [25:32.370 --> 25:37.630] standing in front of Charmin. Because you'd normally buy Quilted Northern, but hey, now I've [25:37.630 --> 25:43.830] got this coupon and now they're the same price or cheaper, so I'll buy Charmin. Location tracking [25:43.830 --> 25:49.610] within building with a commercial application and now we start tying that to something for [25:49.610 --> 25:58.110] purchasing habits, that's kind of creepy. That said, it's still a pretty darn neat application. [25:58.830 --> 26:04.690] We can still, with the Nordic Radio, do some stuff with iBeacon. However, iBeacon is based on [26:04.690 --> 26:10.030] Bluetooth Low Energy and we just sort of went over some of those challenges with Bluetooth Low Energy. [26:10.590 --> 26:17.510] However, some of those challenges still exist. We can only either broadcast or sniff [26:18.010 --> 26:24.270] the presence for some of those devices. And injection actually works a little bit better [26:24.270 --> 26:31.210] here. So we can create iBeacon advertisements. Hey, I'm an iBeacon and I'm here. And that's [26:31.210 --> 26:37.110] sort of about it for this radio with iBeacon. All right, some practical implementation for you guys [26:37.110 --> 26:42.070] to get started for some of this stuff. This is exactly what we used for the Mid-Atlantic CCDC [26:42.070 --> 26:49.430] competition. This is their badge. Sexy, isn't it? It's an Arduino micro and one of the radios. [26:49.430 --> 26:54.630] And a battery pack and a lanyard. I didn't put the battery pack. They had four AA batteries [26:54.630 --> 26:59.370] and a USB connected thing. So I made these guys wear four AA batteries around their neck [26:59.370 --> 27:06.890] with this nice thin lanyard for two days. It sucked. It sucked. But the battery packs were cheap. [27:06.890 --> 27:11.150] We got them in all under budget. I got them in way under budget and they had a great time with them. [27:11.170 --> 27:17.530] Okay, so with this, with the Arduino, we're using the SPI libraries, which were included. If not, [27:17.530 --> 27:25.810] fairly easy to grab. And there are a couple of ‑‑ there are at least two Nordic NRF 24L01 [27:25.810 --> 27:32.450] libraries available for Arduino. This was the one I found to be the most robust, the one from [27:32.450 --> 27:39.110] Maniac Bug. Easy to install, copy, unzip, put in your Arduino libraries folder and import your [27:39.110 --> 27:44.430] libraries. He's got tons of examples. Part of the reason why I really liked some of his stuff, [27:44.430 --> 27:53.010] it's well documented. And the examples are well documented as well. The ADS‑B beacon is half of [27:53.010 --> 28:00.090] his ping pair transponder examples. It took me all of three days to write the code to modify his stuff [28:00.090 --> 28:07.230] and put it through some pretty rigorous testing. Based on the code for that ping pair example. And [28:07.230 --> 28:16.350] yes, giving credit where credit was due. Most of the code was Maniac Bug's. And got it done in a [28:16.350 --> 28:22.670] two‑month time frame. This is the one that was really flexible. Because it's library based, we [28:22.670 --> 28:27.870] can do some modification to it. We can actually use the libraries to set all the registers to [28:27.870 --> 28:32.610] disable the CRC 32‑bit checksum. We can enable shock burst direct mode if we really want to. [28:32.610 --> 28:38.370] And there's also some libraries for us to do some of that limited Bluetooth low energy stuff [28:38.370 --> 28:47.090] under Arduino as well. With the BT ‑‑ Bluetooth low energy libraries as well. So, fairly easy to [28:47.090 --> 28:53.570] use. It's six wire SPI. If I remember correctly. Five or six wires. We can go through and count [28:53.570 --> 29:00.730] them if we really want. When we built these, I recruited help. I recruited my six‑year‑old [29:00.730 --> 29:07.730] daughter and my wife to wire these. If my six‑year‑old can wire these, so can you. [29:08.870 --> 29:16.510] All right. So, lots of good fun. Now, there's all sorts of things that right out of the box [29:16.510 --> 29:20.250] with the Arduino stuff, we can start capturing. We can start capturing some of other Arduino [29:20.250 --> 29:26.350] traffic. Some other potential applications with standard shock burst enhanced stuff. [29:26.350 --> 29:34.430] For example, some great proprietary type of items. There's some folks here at Con from the Midwest, [29:34.830 --> 29:40.050] a group that calls themselves the Whiskey Pirates. They decided that they wanted to have a learning [29:40.050 --> 29:45.070] experience before they came to DEF CON. One of the guys wanted to learn surface mount soldering. [29:45.070 --> 29:50.010] The other guy wanted to learn how to do board design with Eagle. The other guy wanted to learn [29:50.010 --> 29:57.250] how to program ARM Cortex A7 processors and do some firmware development for that. So, they got [29:57.250 --> 30:04.210] together and they did just that. And, in fact, they built this badge in, like, four and a half [30:04.210 --> 30:09.950] months. Like, damn! And they didn't get to implement all the features and firmware. They [30:09.950 --> 30:15.690] gave me this one Thursday late afternoon. They were still in their hotel room cranking out [30:15.690 --> 30:19.310] firmware and they were, like, reflashing these things every 15 minutes because they were adding [30:19.310 --> 30:24.390] more and more features. As one of the things that they wanted to do further development for, [30:24.390 --> 30:31.530] these badges feature Nordic NRF24L01 radios. They wanted to be able to do games between the [30:31.530 --> 30:39.070] multiple badges, the ability to have a microphone so that would do VU meter type of stuff and sync [30:39.070 --> 30:44.150] the levels for the VU meter between all the badges. So, like, one guy could be in the party [30:44.150 --> 30:49.250] and everybody else can be in the hallway and they're all thumping to the same beat. Pretty cool. [30:49.250 --> 30:55.130] We can potentially use that to sniff and or mess with those as well. Okay. Lots of hobby-based [30:55.130 --> 31:00.890] applications. How many of you guys have seen the Flea Microcopter? And I can't remember the [31:00.890 --> 31:10.970] company that makes it. It's one of the tiny, tiny nano quadrotors. It's about this big. They [31:10.970 --> 31:17.810] use the Nordic NRF radio to do control for that device. Wireless 2.4 gigahertz. So you can now [31:17.810 --> 31:25.650] conceivably build your own controllers and crash other people's quadcopters. Okay. All right. Some [31:25.650 --> 31:29.810] of the stuff on the back end may require some significant post processing depending on what [31:29.810 --> 31:37.010] you're doing. Okay. So this stuff becomes fairly easy to do. We talked about the Arduino. How many [31:37.010 --> 31:42.950] of you guys have ever done any Arduino work? Okay. All right. You guys can do this. Grab the demo [31:42.950 --> 31:50.490] stuff and start from there. My college professors told me all good programmers reuse code. Doesn't [31:50.490 --> 31:56.970] necessarily need to be your code. Give credit where credit's due. So really easy for us to [31:56.970 --> 32:02.830] implement. The libraries are there. There's some great examples. And sure enough, take one of the [32:02.830 --> 32:12.930] examples, flash them to a pair of Arduinos, and it's that simple. And communication works. I'm [32:12.930 --> 32:17.190] the challenges that I ran into with the Mid-Atlantic CCDC badges that I didn't realize [32:17.190 --> 32:22.430] until half the badges were already built is that they'll make a pseudo mesh as part of [32:22.430 --> 32:29.670] shock burst enhanced. But the mesh will really only support effectively six devices. I created [32:29.830 --> 32:38.390] a mesh and it had 110 devices. It didn't work very well. It worked well enough for the students [32:38.390 --> 32:42.130] to have fun with it. But that was one of the things that we ended up telling them about. [32:42.130 --> 32:48.290] You can create cascaded meshes so that you can do routing and fault tolerance over the [32:48.290 --> 32:53.750] meshes as well with enhanced shock burst. So you could have conceivably multiple meshes [32:53.750 --> 32:58.590] with six or five or six devices and route through those meshes as well. [32:58.590 --> 33:02.530] I didn't know that at the time. I just gave everything the same address and [33:02.530 --> 33:09.370] sent all the traffic to broadcast. It did not work out so well. There were lots of crashed aircraft. [33:10.170 --> 33:15.650] But so it can be loads of fun with too many nodes, potential denial of service conditions. [33:15.650 --> 33:21.330] So that might be something to look at as well. I specifically talked about using it with the [33:21.330 --> 33:28.910] Arduino. That was where a lot of my experience lied. However, it's a standard SPI bus. So any [33:28.910 --> 33:34.030] microcontroller that you can do SPI with, you can use this radio on. You want to do that on the [33:34.030 --> 33:40.750] Arduino, sure. You want to do it on a Raspberry Pi, great, no problem. You can even use the Bus [33:40.750 --> 33:47.510] Pirate, which if I recall is MSP430 based. Same thing with the GoodFET from Travis Goodspeed. [33:47.650 --> 33:55.970] Also MSP430. Parallax from your DEF CON badge this year. If it does SPI, you can interface [33:55.970 --> 34:00.110] with the radio. And there are likely libraries that you can use. And here's some of the standard [34:00.110 --> 34:05.330] pinouts to be able to interface with the radios. Readily available on the internet. So very easy [34:05.330 --> 34:13.270] for us to get to. So this is how you change a tire like a boss. I have no idea. I told you. [34:13.270 --> 34:21.190] Google image search. Easy mods. And this came up. This looks like the Chinese army learning [34:21.190 --> 34:27.530] how to change a tire while driving on their motorcycle with sidecar. I've actually seen [34:27.530 --> 34:31.710] one of these videos and it's pretty damn impressive that they change the tire on the [34:31.710 --> 34:38.370] sidecar while they're driving. Yes, you too can do this very easily. We can modify the libraries [34:38.370 --> 34:44.510] to change the various settings, change frequency channels, change whether we're going to use [34:44.510 --> 34:51.470] shock burst in direct mode, set our rates right within our Arduino libraries. However, if you're [34:51.470 --> 34:56.390] going to change it within a library, the Arduino will use that same library in that same setting. [34:56.390 --> 35:02.590] So you may want to have multiple instances of libraries or modify those libraries to assign [35:02.590 --> 35:10.390] all of those from a variable from your main program. Fairly easy to undertake. Standard [35:10.390 --> 35:16.050] programming practices about importing libraries and referencing libraries. So it doesn't exist [35:16.050 --> 35:21.830] currently, but that's something that would be relatively easy to undertake. So for example, [35:21.830 --> 35:31.710] here are some of the items within the RF24 libraries for us accessing some of the registers [35:31.710 --> 35:36.870] within the radio. The libraries will handle all of this for us. You tell it to initialize the radio, [35:36.870 --> 35:40.750] it goes and initializes the radio with all of these default settings, just like we'd expect. [35:40.750 --> 35:47.130] You do two of them and they do the same things. Some additional registers so that we know what [35:47.130 --> 35:52.890] the default values are. Go and read the spec sheet from Nordic. Find out what some of the [35:52.890 --> 35:57.970] values you may want to change are depending on your application. And again, easily changeable [35:57.970 --> 36:06.950] within the modules. Okay. All right. We talked about Arduino. That was really easy. You fire [36:06.950 --> 36:13.650] up the Arduino IDE, you load some demo code, you put some stuff on there, and hey, look, it works! [36:13.650 --> 36:20.750] Let's go down a little bit more advanced application. And I will admit, when I say [36:20.750 --> 36:26.730] advanced application, it wasn't terribly bad. We talk about ‑‑ I talked a little bit about having [36:26.730 --> 36:33.010] one too many projects. I did my advanced implementation stuff. I wrote these slides [36:33.650 --> 36:41.770] Tuesday. Because I actually got a chance to do it on Tuesday. So I wrote the slides and did these [36:41.770 --> 36:50.690] on Tuesday right before DEF CON. And I had some of the stuff sort of preloaded. But it was just a [36:50.690 --> 36:55.890] matter of putting the pieces together and it didn't turn out too bad. Okay. So as we mentioned, [36:56.330 --> 37:03.610] Travis Goodspeed found a way for us to be able to capture data with the Nordic radio with some [37:03.610 --> 37:08.150] promiscuity giving us a raw stream of data. Now why don't we leverage some tools to take that raw [37:08.150 --> 37:15.050] data and do some post processing. His implementation sets some of those registers for an [37:15.050 --> 37:21.170] invalid mode to give us raw data and disables all of the CRC calculations and checking so that it's [37:21.170 --> 37:29.650] not modifying any of that data on the way inbound. So his hackery was great. Send us all this raw [37:29.650 --> 37:38.130] data. The data is going to look like data. But when we've got noise, it is typically ‑‑ the [37:38.130 --> 37:48.970] 00 in hex or FF in hex. So let's throw all of the 00s and FFs in hex away and or search for very [37:48.970 --> 37:55.570] specific strings for a device that we're looking for. In the case of Logitech and Microsoft [37:55.570 --> 38:02.350] keyboards, the sync word and or start of some of the headers for some of the packets start with [38:02.350 --> 38:08.910] 55 in hex or AA in hex. So if you see a packet that's ‑‑ or a value that starts 55, [38:08.910 --> 38:14.410] maybe this is a packet. Were there 0s and FFs before it? Yes. Throw that stuff away. This is [38:14.410 --> 38:18.490] likely the start of a packet. Now let's start capturing that and take a look at that. That's [38:18.490 --> 38:29.470] pretty darn neat. So why would Larry consider this advanced? Well, it requires the use of a [38:30.210 --> 38:38.370] that you can actually purchase a good FET from Adafruit industries. They're 50 bucks. To me [38:38.370 --> 38:43.770] that's kind of pricey for what it is. However, you can assemble your own. How many of you guys [38:43.770 --> 38:49.330] have done surface mount soldering work? This is a great opportunity to go try to start with. This [38:49.330 --> 38:56.590] was my first surface mount job. Which I got it to work. I used it to program my IME pink pager [38:56.590 --> 39:03.210] and that was the only time it ever worked. It was my first surface mount solder job. It was horrible. [39:03.610 --> 39:08.130] And I wanted to use it. This is the only one I had for this. So I had to take it down to the [39:08.130 --> 39:14.730] basement to the soldering iron and put on the loop. And I had to reflow every single joint [39:14.730 --> 39:18.870] on the board. I don't have a reflow oven. I don't have a hot plate. It's all by hand. [39:19.590 --> 39:25.110] So to me, that's one of the reasons why it's advanced. The hardware assembly is a little bit [39:25.110 --> 39:31.790] more complex. But Travis's design uses the MSP430 and there's SPI libraries with that. And [39:31.790 --> 39:37.750] Travis has done a lot of the heavy lifting for us. He's got some applications for us to be able [39:37.750 --> 39:47.710] to interact with the MSP430 and trigger the radio for us to capture packets. There's also a port [39:47.710 --> 39:54.890] that I discovered on Tuesday of the GoodFET software to the Arduino with the same functionality. [39:55.170 --> 40:01.130] So you can do all the same stuff that you can do with the GoodFET with an Arduino by having the [40:01.130 --> 40:07.950] libraries ported to an Arduino as well. And the reason for that was the gentleman had more [40:07.950 --> 40:14.350] experience with the Arduino, didn't have the ability to get his hands on or assemble a GoodFET. [40:14.350 --> 40:21.450] So he ported that to the Arduino with the idea to be able to sniff packets from keyboards using [40:22.450 --> 40:31.230] Travis's promiscuity hack. Great. I found out about this one Wednesday afternoon at 2 o'clock. [40:31.310 --> 40:36.210] Like, I'm trying to pack to go to DEF CON and I'm still updating slides for this talk. [40:37.470 --> 40:43.910] Because there was a post that got made on Hackaday Wednesday morning. I didn't stumble [40:43.910 --> 40:49.970] upon it until 2 o'clock. I had to go to work on Wednesday and found it at 2 o'clock right after [40:49.970 --> 40:58.570] lunch. And a gentleman had created an Arduino sketch and some plug-ins for Wireshark and a [40:58.570 --> 41:04.890] Windows-based application to do a named pipe to interact with the Arduino to pass data to a named [41:04.890 --> 41:11.610] pipe to Wireshark on Windows. So we can now use Wireshark to directly sniff using Travis's [41:11.610 --> 41:18.590] promiscuity hack right into Wireshark. And he wrote some protocol dissectors for the Nordic [41:21.190 --> 41:28.930] NRF24L01 packets. So we've got a module there, post-processing module, as well as the underlying [41:28.930 --> 41:35.090] protocol for a device called MySensors. They do temperature monitoring and home control type of [41:35.090 --> 41:38.310] stuff, open source type of things as well. And that's really what he wanted to do with it. He [41:38.310 --> 41:44.090] wanted to be able to interact with that with the Arduino. So he did. All of the stuff is available [41:44.090 --> 41:55.130] at these three blog spot links here. I apologize. It's a little eye chart. We'll get to that. But [41:55.670 --> 42:02.130] limited analysis as far as the protocol dissectors go. But we've got PCAPs. Like stuff that we know [42:02.130 --> 42:08.190] how to deal with with all sorts of various tools. And directly within Wireshark. The problem is, I [42:08.190 --> 42:14.410] set this up to give you guys a demo. And it requires Windows. And Wireshark on Windows. And [42:14.410 --> 42:22.590] application with name pipes. And I'm missing some redistributable.net objects on that Windows VM. [42:22.590 --> 42:27.390] And I just didn't have enough time to make it happen. So it's a little buggy on the install. [42:27.570 --> 42:32.370] And there's some comments on one of these blog posts on some of the issues that are still going. [42:32.370 --> 42:39.610] But still incredibly possible. Okay. We can also do software defined radio stuff for some [42:39.610 --> 42:42.570] sniffing. However, many of the software defined radios that you're going to find that are [42:42.570 --> 42:50.010] affordable such as the RTLSTR real tech type dongles, the digital DV tuner stuff, do not [42:50.010 --> 42:56.070] accurately do in many cases 2.4 gigahertz. So you now need to use a down converter, something that [42:56.070 --> 43:00.490] will capture 2.4 gigahertz and then sort of retransmit that at a lower frequency within the [43:01.010 --> 43:10.890] dongles. There are some plug-ins for I think SDR sharp as well as we can do this with GNU radio [43:10.890 --> 43:16.810] and GNU radio companion to be able to decode enhanced shock burst packets. So all of the [43:16.810 --> 43:22.350] stuff is there. It's just a matter of being able to capture that. This may be interesting for you [43:22.350 --> 43:31.250] that are working on challenges, CTF. So I have some of the software defined radios. I don't [43:31.250 --> 43:39.430] have a down converter yet. It's just too many projects, not enough time. And the CFO has yet [43:39.430 --> 43:44.250] to approve additional purchases because I've already got enough hardware to play with. And [43:44.250 --> 43:51.510] by CFO, chief financial officer, I do not mean the CFO at my day job. I mean my wife. Okay. [43:51.510 --> 43:56.710] She does the, honey, would you rather this neat new tech toy or diapers? [43:59.370 --> 44:04.530] Yeah, let's do the diapers. Because I don't want to clean the carpet. Let's do the diapers. [44:04.990 --> 44:10.270] So, yeah, and it can be done relatively inexpensive. Under $75, including the [44:10.270 --> 44:14.470] software defined radio. Folks that like hack shop or get them direct from China. [44:14.870 --> 44:20.510] Down converters and cables direct from China, places like deal extreme. Have you guys done [44:20.510 --> 44:25.170] deal extreme before? That place is like the easiest place for me to part with my money. [44:25.410 --> 44:29.030] You go to deal extreme and you're looking for one thing and like, hey, this is cool. [44:29.150 --> 44:37.690] Android tablet, $20. Smart watch, $6. Give me three. Yeah. Next thing I know, I'm checking out [44:37.790 --> 44:43.490] a deal extreme and I got a $300 order of just cheap Chinese stuff that's awesome to play with. [44:43.490 --> 44:48.110] And when am I going to have time to play with it? Yeah. So, for example, when we do the demos, [44:48.110 --> 44:55.070] I've got this solar powered battery, 30,000 milliamp hour solar rechargeable battery. [44:55.410 --> 44:59.570] I lost my other one, so I went to deal extreme to buy this one. Turns out they were so cheap, [44:59.570 --> 45:06.870] I bought four. So I can lose it three more times. Okay. Turns out they're really handy, [45:06.870 --> 45:10.170] especially when you come to DEF CON, because one can be in your hotel room charging while [45:10.170 --> 45:15.790] you're charging your phone with the other one. Okay. So, yeah, we can do this fairly inexpensively [45:15.790 --> 45:22.470] and use software to find radio to tune into some of the stuff as well. All right. So as promised [45:22.470 --> 45:27.890] from the talk description, I'm going to do some demonstration, hopefully, and I'm going to tempt [45:27.890 --> 45:33.710] the 2.4 gigahertz demo unicorns. And for those of you who have seen the Photoshop version of this [45:33.710 --> 45:39.770] with Dave Kennedy's head, it's significantly better. Okay. So now let's see if we can [45:39.770 --> 45:45.290] actually make something work. But before we get into that, the first one that we're going to do, [45:45.290 --> 45:49.310] I know this is definitely high chart. I am going to give you guys a location where you can go grab [45:49.310 --> 45:57.930] the slides. This is the code as part of the two halves of the Mid-Atlantic CCDC badge for the [45:57.930 --> 46:04.730] badges that we did. This one happens to be the ADSB receiver. So I've got an Arduino with one [46:04.730 --> 46:08.830] of these radios just sitting here listening for beacons, and I'm going to show you sort of the [46:08.830 --> 46:14.470] output for that. Pretty short for code. I know it's a little crunched, so I could get it all [46:14.470 --> 46:20.910] on one slide and make it somewhat readable. It will be better in the PDF, I promise. And here's [46:20.910 --> 46:28.430] the transmitter, the ADSB beacon. You can actually read that one on the slide. It's what? 30 lines [46:28.430 --> 46:33.930] of code, if that. And the sad part is, some of these lines of code don't even need to be there. [46:33.930 --> 46:40.270] I was in a rush, and it worked. So if it ain't broke, don't fix it. When I was going through [46:40.270 --> 46:43.450] and cleaning some of it up to actually make it take out some of the extra spaces, I'm like, [46:43.450 --> 46:48.130] I don't need that. But, you know, in a matter of full disclosure, I'm going to tell you guys that [46:48.130 --> 46:56.630] I screw up. And, yeah, there's some screw-ups in here. But it works. For example, we do not need [46:56.630 --> 47:03.110] the type def enumeral. It's about the seventh line down. The role ping out equals one. [47:03.710 --> 47:09.090] Doesn't do anything. It's defining a variable that we don't even reference. So one line down. [47:09.090 --> 47:21.230] Okay. All right. Let's try this. All right. So serial application tied to the receiver in the [47:21.230 --> 47:30.190] purple case. It's connected over serial. And now we'll power up the badge. And, again, thank you [47:30.190 --> 47:36.270] for loaning me the micro USB cable. Remind me to give this back to you. To prove that I'm not [47:36.270 --> 47:45.950] doing anything funny standalone. Plug this in. Let it boot up. And it should immediately start [47:45.950 --> 47:55.010] spitting out tail number. And we gave it a fun tail number. Okay. The aircraft beacon is DEF CON [47:55.010 --> 48:06.470] 22 wifi village NRF54L01 plus. No, it's the 24L01 plus. Low bandwidth radio. Processing for the [48:06.470 --> 48:17.710] Arduino is eh. But it will have some issues. So it is actually the DC wifi village NRF24L01 radio. [48:17.710 --> 48:24.790] But in some of the cases it's received as 54. Why? No idea. But it is. It started doing this at [48:24.790 --> 48:31.350] home to me, too. So maybe I screwed something up. It is actually the 24. It is 24 in the code when I [48:31.350 --> 48:38.250] programmed it. That was easy. Go flash two Arduino examples. Plug them in. And you're doing data [48:38.250 --> 48:47.490] transfer at 1 meg for $1 radios and connect it to, like, $25 Arduinos. It's pretty cool. All right. [48:47.570 --> 48:54.770] Now let's go for the advanced one. All right. Let's just disconnect that. No. All right. [48:54.790 --> 49:12.950] For the advanced one. All right. So I need to unplug that. And need to plug this in. So this [49:12.950 --> 49:19.430] is the unifying receiver from Logitech that I'm going to plug in here. And hopefully that will [49:19.430 --> 49:28.230] work just fine. Keyboard is on. And working. So I've got one of these Nordic NRF radios attached [49:28.230 --> 49:33.710] to GoodFET according to Travis's wiring. And the GoodFET is actually working. The reflow [49:33.710 --> 49:40.190] actually worked. So we can now use the GoodFET applications. Travis has given us some nice [49:40.190 --> 49:46.290] scripts. The GoodFET.NRF script. And if we run that without some commands, he's going to tell [49:46.290 --> 49:53.250] us all the different fun things that we can do. Capture spark fun, dongle traffic, open beacon [49:53.250 --> 49:59.890] traffic. We can do some auto tune for radios to try to discover stuff that's on specific channels. [50:00.170 --> 50:06.070] However, if we do that with the sniff Microsoft keyboard. We're going to sniff Microsoft [50:06.070 --> 50:12.730] keyboards with specific HID applications. If we have the Microsoft keyboard, it will determine [50:12.730 --> 50:19.330] all of the USB human interface device codes and will convert those to keystrokes. This is [50:19.330 --> 50:24.450] unfortunately not a Microsoft keyboard. It is a Logitech keyboard. So it doesn't know how to [50:24.450 --> 50:29.290] decode them into the keystrokes. It will, however, give us the raw packets. And then we can [50:29.290 --> 50:35.710] potentially do some magic with those packets as well. It does take a little bit of time because [50:35.710 --> 50:43.150] the radios on these devices turn on to a pseudo random frequency every time it turns on. So it [50:43.150 --> 50:48.850] attempts to do sniffing on all channels. But it cannot do that. It has to go through each [50:48.850 --> 50:55.150] channel at a time. And when it sees stuff that are interesting based on various headers, either [50:55.150 --> 51:01.070] 55 or AA, it says, hey, we've seen some stuff that looks like it might be a packet. And we're going [51:01.070 --> 51:08.310] to see... so we saw one. This one looks like a valid packet coming from a device of AAA. And [51:08.310 --> 51:15.070] quite honestly, this may be the guys over doing CTF totally screwing with me. So it's going to [51:15.070 --> 51:20.190] step through all the various channels. It takes some time. And eventually we'll start seeing [51:20.190 --> 51:27.750] stuff that end up looking like packets. This is totally impressive, right? Hey, look. It tuned to [51:27.850 --> 51:33.110] a channel. Yeah. There's not a lot of way I can make it speed up. I'm like, oh, great. I'll just [51:33.110 --> 51:38.210] find out what channel this keyboard talks on and set it to tune to that channel automatically. [51:38.210 --> 51:42.130] Don't do any of this auto tune stuff and just have it spit packets. The problem is every time [51:42.130 --> 51:48.210] you turn on the keyboard, it does a different channel. So we saw some different stuff on [51:48.910 --> 51:56.590] 2403. Again, lots of AAA stuff. So likely noise. Probably some more noise there. We had lots of [51:56.590 --> 52:03.110] fives in a row. And 2403 as well. It now starts spitting us out packets. When we see stuff that [52:03.110 --> 52:10.790] ends up being valid over a longer period of time, we can take the address cell, tell it, hey, just [52:10.790 --> 52:17.930] sniff for this address. And then it starts dumping us keystrokes. So with the Microsoft [52:17.930 --> 52:24.010] keyboard, it gives us actual converted keystrokes. With this one, I haven't had the opportunity to [52:24.010 --> 52:29.130] figure out how to make that work. Again, I was working on this on Tuesday. Made this work on [52:29.130 --> 52:33.630] Tuesday and into Wednesday morning. So haven't had the opportunity to start reversing that. [52:34.030 --> 52:38.870] But fun stuff. Didn't take a heck of a lot to make that happen. Of course, now all the guys [52:38.870 --> 52:49.090] at CTF are turning around going, huh. No. All right. We'll let that stop. Hey, guess what? [52:49.810 --> 52:56.970] No demo unicorns. All right. And now I get to admit something kind of embarrassing. [52:59.170 --> 53:03.210] Well, that's all I've got for you guys in some pretty good time. [53:03.210 --> 53:11.650] But so the demo unicorns were tempted and they didn't show up. So he-man on a flying unicorn, [53:11.650 --> 53:19.010] your argument is invalid. However, I take issue. This is not a unicorn. A unicorn has a horn and [53:19.010 --> 53:28.640] no wings. A pegasus has wings and no horn. So what is a flying unicorn called? An alicorn. [53:29.160 --> 53:35.620] Why do I know this? My 6-year-old daughter is obsessed with My Little Pony. I'm like a closet [53:35.620 --> 53:40.660] brony and I don't know it. That's all that we watch in our house is My Little Pony. Please, [53:40.660 --> 53:47.100] God, save me. To the point that I knew that this was an alicorn. And I actually went and made sure [53:47.100 --> 53:51.900] I looked it up. So, yeah, it is not a unicorn. It could be. It's not a unicorn. It's either an [53:51.900 --> 54:03.280] alicorn or, according to some sci-fi authors, it is also a pegacorn or a unipeg. So, yes. And my [54:03.280 --> 54:11.540] boss so kindly filled me in when, even better, that this is neither an alicorn, a unipeg, a [54:11.540 --> 54:23.020] pegasus, a unicorn, or a pegacorn. This is, in fact, Strider from He-Man. All right. So thank you guys [54:23.020 --> 54:28.440] very much for getting up nice and early on Saturday. Hopefully I didn't bore you too much. [54:28.440 --> 54:32.760] And, you know, go forth and conquer. Some really neat stuff. Really inexpensive to start getting [54:32.760 --> 54:37.660] involved with. And has some pretty interesting application. You guys can build a keyboard [54:37.660 --> 54:44.220] sniffer for Microsoft Logitech 2.4 gigahertz keyboards and take this back to your organization, [54:44.220 --> 54:50.220] do some auditing and say, get rid of these damn things. Unless you really want to have some fun. [54:50.840 --> 54:54.660] These radios will transmit. So now take what you've learned about the receive [54:54.660 --> 55:00.640] and start crafting packets and injecting keystrokes. Exercise left to the reader. [55:02.040 --> 55:05.420] Some of these slides, text is a little bit hard to read. If you want to go back and look at this, [55:05.420 --> 55:10.760] I know they're recording it. So it will likely be at irongeek.com later and various places. [55:12.940 --> 55:19.080] The slides, as soon as I get home, and by home, I mean probably late next week, [55:19.080 --> 55:23.480] because I go directly from DEF CON to a client site. I hope they like the hair. [55:25.080 --> 55:29.580] So I'm literally leaving from DEF CON to go to a client site after I go home. I'm going home for [55:29.580 --> 55:34.600] about six hours, pack a suitcase and leaving again. So I will put the PDFs up on my website [55:34.600 --> 55:41.820] at hacksterthematrix.com. It's my blog. There's a total of five entries. You'll be able to find it. [55:41.820 --> 55:45.480] So I won't give you a specific link to a specific entry. You'll be able to find it. [55:45.700 --> 55:49.760] And there's all sorts of other fun stuff up there as well. Great. So thank you for spending some [55:49.760 --> 55:53.860] time with me this morning. I'm going to stick around for a while if you guys have got questions, [55:53.860 --> 55:58.220] cool fun things. I actually want to see if I can capture some stuff with some software [55:58.220 --> 56:04.220] defined radio as part of the CTF and get some practice. So good time to do that. Thanks [56:04.220 --> 56:09.360] for coming. And thank you. Enjoy the rest of your DEF CON. And we'll see you all for [56:09.360 --> 56:10.760] ham radio exams tomorrow, right?