1 00:00:00,000 --> 00:00:02,140 Good afternoon everyone and thank you for coming. 2 00:00:02,860 --> 00:00:06,620 I'm going to present the Beetlejuice, 3 00:00:08,460 --> 00:00:10,460 Beetlejuice tool I've developed and 4 00:00:11,880 --> 00:00:16,320 especially the man-in-the-middle attack it implements. 5 00:00:18,260 --> 00:00:21,880 So, just to start, I am Damien Coquille, 6 00:00:22,100 --> 00:00:25,300 a French senior researcher at CERTUBIC, 7 00:00:25,440 --> 00:00:28,340 which is part of the digital security company, 8 00:00:28,340 --> 00:00:29,840 a French digital security company, 9 00:00:30,380 --> 00:00:33,980 and this company is owned by Econocom, 10 00:00:34,080 --> 00:00:37,880 maybe some of you know about it. 11 00:00:38,220 --> 00:00:45,780 Anyway, I started studying Bluetooth low energy security 12 00:00:46,340 --> 00:00:50,180 back in 2013, so it's quite a while. 13 00:00:50,320 --> 00:00:54,000 I've been testing stuff in the BLE field 14 00:00:54,000 --> 00:00:57,340 and this is my main focus since then. 15 00:00:58,340 --> 00:01:00,040 So you can find me on Twitter. 16 00:01:02,500 --> 00:01:06,920 What we are going to talk about here in this talk 17 00:01:06,920 --> 00:01:10,520 is mainly the basic stuff in Bluetooth classic, 18 00:01:10,780 --> 00:01:12,340 but very, very shortly, 19 00:01:12,500 --> 00:01:15,280 and Bluetooth low energy, also called Bluetooth smart. 20 00:01:16,080 --> 00:01:20,380 And I will also discuss the fact that 21 00:01:20,380 --> 00:01:23,520 Bluetooth low energy sniffing really sucks. 22 00:01:24,420 --> 00:01:27,880 I don't know if some of you perform some kind of 23 00:01:28,340 --> 00:01:30,140 sniffing with specific devices, 24 00:01:30,220 --> 00:01:32,620 like a Bluetooth or something like this, 25 00:01:32,740 --> 00:01:36,020 but it's really difficult in certain conditions 26 00:01:36,020 --> 00:01:44,040 to get valid data or something very useful from these tools. 27 00:01:44,840 --> 00:01:47,560 And we will go through the man-in-the-middle attack 28 00:01:47,560 --> 00:01:51,040 I designed and the tool associated with it, 29 00:01:51,120 --> 00:01:54,980 that I call the Beetlejuice. 30 00:01:55,380 --> 00:01:57,760 Well, great reference to a movie. 31 00:01:58,340 --> 00:02:01,260 And we will end the talk with live demos. 32 00:02:01,580 --> 00:02:04,960 So I spent all the morning 33 00:02:04,960 --> 00:02:07,180 to pray the demo girls, of course, 34 00:02:07,260 --> 00:02:09,200 in order to have all the demo... 35 00:02:10,500 --> 00:02:11,720 That went well, but... 36 00:02:12,340 --> 00:02:15,420 In fact, since there is a lot of people here, 37 00:02:15,700 --> 00:02:18,840 maybe there may be some interferences with your devices. 38 00:02:19,260 --> 00:02:21,880 And I will show you with my tool 39 00:02:21,880 --> 00:02:27,680 that every device I can identify with this tool. 40 00:02:27,680 --> 00:02:32,720 And maybe some problems with it, 41 00:02:32,760 --> 00:02:34,900 if there are too much trackers 42 00:02:35,260 --> 00:02:37,180 or something like this available on it. 43 00:02:39,260 --> 00:02:42,340 So first of all, the Bluetooth Smart 101. 44 00:02:43,920 --> 00:02:47,700 So you are all aware of Bluetooth Classic, 45 00:02:47,940 --> 00:02:52,000 which has been very, very used in the last years. 46 00:02:52,580 --> 00:02:56,300 But defined in the Bluetooth specifications, 47 00:02:56,300 --> 00:03:00,280 the Bluetooth Low Energy Protocol, 48 00:03:00,660 --> 00:03:03,940 which is not so new protocol, 49 00:03:04,100 --> 00:03:06,820 but it has been widely deployed 50 00:03:06,820 --> 00:03:09,240 since two years on many devices. 51 00:03:09,500 --> 00:03:12,940 So it's a very, very, very common protocol now. 52 00:03:13,160 --> 00:03:16,280 And it's implemented in a lot of devices. 53 00:03:16,660 --> 00:03:19,340 And the Bluetooth Smart Protocol 54 00:03:19,340 --> 00:03:22,500 was designed in order to be implemented 55 00:03:22,500 --> 00:03:25,080 in very innovative devices. 56 00:03:25,080 --> 00:03:28,840 In fact, in devices that requires low power 57 00:03:28,840 --> 00:03:35,640 and with all the capability of Bluetooth. 58 00:03:36,040 --> 00:03:37,360 So it's widely used. 59 00:03:40,660 --> 00:03:43,040 If you search on the internet 60 00:03:43,040 --> 00:03:45,880 about Bluetooth Smart enabled devices, 61 00:03:46,140 --> 00:03:47,360 you will find a lot of them. 62 00:03:47,600 --> 00:03:50,700 And some of them are very, very freaky. 63 00:03:50,960 --> 00:03:52,660 You have the Smart Mattress. 64 00:03:52,780 --> 00:03:53,320 It's... 65 00:03:53,320 --> 00:03:55,980 Well, it doesn't show very well here, 66 00:03:56,100 --> 00:03:57,560 but this is a kind of device 67 00:03:57,560 --> 00:03:58,800 you can put under your mattress. 68 00:03:59,020 --> 00:04:02,640 And that device monitors the movement of the mattress. 69 00:04:02,900 --> 00:04:05,380 So I guess you can... 70 00:04:05,380 --> 00:04:09,360 I guess you see what we can do with this kind of stuff. 71 00:04:11,160 --> 00:04:15,400 Well, anyway, there is also the Smart Dapers. 72 00:04:16,120 --> 00:04:20,660 It's a dapper that tweets when your baby pees. 73 00:04:21,360 --> 00:04:23,240 Also very, very cool. 74 00:04:23,320 --> 00:04:23,780 I think everyone needs it. 75 00:04:23,920 --> 00:04:25,980 And just to conclude, 76 00:04:26,180 --> 00:04:27,500 some kind of security stuff 77 00:04:28,020 --> 00:04:29,800 like smart alarms 78 00:04:30,140 --> 00:04:31,480 or even smart dogs 79 00:04:32,320 --> 00:04:33,640 or bad dogs. 80 00:04:34,280 --> 00:04:36,560 I have some of them here to demonstrate. 81 00:04:36,920 --> 00:04:39,680 So I've heard about another talk 82 00:04:40,260 --> 00:04:43,220 at DEF CON about pointing smart dogs. 83 00:04:43,380 --> 00:04:44,340 It can be... 84 00:04:45,100 --> 00:04:47,500 Maybe the same in a way, but... 85 00:04:47,500 --> 00:04:48,240 Anyway. 86 00:04:50,320 --> 00:04:52,000 The Bluetooth stack 87 00:04:52,000 --> 00:04:55,100 is divided in two, 88 00:04:55,260 --> 00:04:58,620 because there is a traditional model 89 00:04:58,620 --> 00:05:01,240 called the Bluetooth Smart Ready. 90 00:05:02,140 --> 00:05:06,320 But basically, the lower protocols are the same 91 00:05:07,160 --> 00:05:11,640 from the physical layer to the L2 cap 92 00:05:11,640 --> 00:05:15,500 with some changes, of course, between it. 93 00:05:15,540 --> 00:05:19,400 But the upper layers are totally different 94 00:05:19,400 --> 00:05:21,840 between Bluetooth Classic and Bluetooth Low Energy. 95 00:05:24,200 --> 00:05:27,020 Bluetooth Smart provides a lot of features, 96 00:05:27,160 --> 00:05:27,880 or new features. 97 00:05:28,240 --> 00:05:30,520 So, not so new, 98 00:05:30,700 --> 00:05:33,020 the frequency-hopping spectrum mechanism 99 00:05:33,020 --> 00:05:35,640 is still used in Bluetooth Smart 100 00:05:35,640 --> 00:05:38,440 to avoid the interferences between devices. 101 00:05:39,360 --> 00:05:42,700 It also supports uncompleted communication through bonding. 102 00:05:42,900 --> 00:05:46,100 So if you create a bond 103 00:05:46,100 --> 00:05:47,980 between your mobile application, 104 00:05:48,200 --> 00:05:48,940 your smartphone, 105 00:05:49,240 --> 00:05:51,640 and some BLE-enabled device, 106 00:05:51,640 --> 00:05:54,280 it secures the communication. 107 00:05:55,220 --> 00:05:57,820 This is covered by the SMP, 108 00:05:57,980 --> 00:05:59,020 the Security Manager Protocol. 109 00:05:59,640 --> 00:06:01,920 So we'll cover this later. 110 00:06:03,360 --> 00:06:05,520 One of the most important things 111 00:06:05,520 --> 00:06:07,200 about Bluetooth Smart 112 00:06:07,200 --> 00:06:10,520 is the fact that we are not creating sockets 113 00:06:10,520 --> 00:06:11,760 to communicate with devices, 114 00:06:12,000 --> 00:06:14,740 but basically use what they call 115 00:06:14,740 --> 00:06:16,360 services and characteristics. 116 00:06:16,800 --> 00:06:20,000 So you have basically a device 117 00:06:20,000 --> 00:06:20,760 that provides 118 00:06:21,640 --> 00:06:23,280 one, two, three, or more services. 119 00:06:23,520 --> 00:06:24,800 And for each service, 120 00:06:25,500 --> 00:06:26,800 each service provides 121 00:06:26,800 --> 00:06:28,680 one or more characteristics. 122 00:06:29,240 --> 00:06:30,460 You can see this, 123 00:06:30,780 --> 00:06:32,400 like some kind of registers 124 00:06:32,400 --> 00:06:35,480 you can write in it and read from 125 00:06:35,480 --> 00:06:38,140 to put data on the device 126 00:06:38,140 --> 00:06:39,640 and get data from the device. 127 00:06:40,380 --> 00:06:43,420 And this communication 128 00:06:44,400 --> 00:06:46,600 is covered by the GAP and GAT 129 00:06:46,600 --> 00:06:48,280 layer of the protocol, 130 00:06:48,440 --> 00:06:50,240 so it's pretty cool. 131 00:06:50,240 --> 00:06:54,280 I will not go too deep 132 00:06:54,760 --> 00:06:56,800 in the description of this protocol. 133 00:06:57,200 --> 00:06:59,660 So if you guys want more information, 134 00:06:59,840 --> 00:07:02,100 you can read the Bluetooth specifications. 135 00:07:02,420 --> 00:07:03,060 Good luck. 136 00:07:03,560 --> 00:07:05,860 But it may be very useful 137 00:07:05,860 --> 00:07:07,380 to understand how things work 138 00:07:07,380 --> 00:07:10,020 with this kind of stuff. 139 00:07:11,380 --> 00:07:14,980 One more thing about Bluetooth Smart. 140 00:07:15,180 --> 00:07:16,440 Bluetooth Smart devices, 141 00:07:16,580 --> 00:07:18,120 for most of them, 142 00:07:18,160 --> 00:07:20,220 accepts only one type 143 00:07:20,240 --> 00:07:21,040 of connection at a time. 144 00:07:21,120 --> 00:07:24,580 The specifications say that 145 00:07:25,340 --> 00:07:26,980 normally a device 146 00:07:26,980 --> 00:07:28,500 may be able to accept 147 00:07:28,500 --> 00:07:30,060 more than one connection. 148 00:07:31,180 --> 00:07:32,450 But in fact, 149 00:07:32,880 --> 00:07:34,220 in most of all devices, 150 00:07:34,420 --> 00:07:35,800 a single connection is supported. 151 00:07:36,120 --> 00:07:38,540 So this is important for the attack. 152 00:07:40,780 --> 00:07:42,040 The frequency 153 00:07:42,040 --> 00:07:44,000 opening spectrum 154 00:07:44,000 --> 00:07:45,880 is a feature you may know, 155 00:07:46,040 --> 00:07:46,840 already know. 156 00:07:46,980 --> 00:07:49,960 It's basically a way to avoid 157 00:07:50,240 --> 00:07:51,320 differences between devices 158 00:07:51,320 --> 00:07:53,460 since all devices use 159 00:07:53,460 --> 00:07:56,360 the 2.4 GHz bandwidth. 160 00:07:56,660 --> 00:07:58,240 So this is quite 161 00:07:59,120 --> 00:08:00,300 not new, 162 00:08:00,900 --> 00:08:02,060 but it's still present 163 00:08:02,060 --> 00:08:03,600 in the Bluetooth Smart protocol. 164 00:08:03,940 --> 00:08:05,380 So basically, 165 00:08:05,560 --> 00:08:07,740 when you're using some sniffer, 166 00:08:07,920 --> 00:08:09,300 it's very difficult 167 00:08:09,300 --> 00:08:11,100 to get valid data 168 00:08:11,100 --> 00:08:13,140 because you have to sniff 169 00:08:13,140 --> 00:08:14,960 the synchronization step 170 00:08:14,960 --> 00:08:16,880 that is performed first 171 00:08:16,880 --> 00:08:20,100 to be able to follow the same 172 00:08:20,240 --> 00:08:22,280 hops and get data from it. 173 00:08:22,440 --> 00:08:23,220 So basically, 174 00:08:23,440 --> 00:08:25,900 when you're in a laboratory environment, 175 00:08:26,340 --> 00:08:27,220 this is perfect. 176 00:08:27,420 --> 00:08:28,580 You have everything you need 177 00:08:28,580 --> 00:08:30,280 for the cages and so on. 178 00:08:30,400 --> 00:08:31,480 But in the wild, 179 00:08:31,560 --> 00:08:33,040 this is very difficult to perform. 180 00:08:33,440 --> 00:08:36,360 I gave a talk last year 181 00:08:36,360 --> 00:08:38,140 at the Chaos Communication Camp 182 00:08:38,140 --> 00:08:39,260 in Germany. 183 00:08:40,520 --> 00:08:43,620 I planned to make a demo 184 00:08:43,620 --> 00:08:45,820 about BLE sniffing 185 00:08:45,820 --> 00:08:46,900 right on stage. 186 00:08:48,680 --> 00:08:49,780 This year, 187 00:08:50,240 --> 00:08:51,060 I had the great idea 188 00:08:51,060 --> 00:08:52,340 to provide all the attendees 189 00:08:52,340 --> 00:08:53,660 with some kind of 190 00:08:53,660 --> 00:08:54,960 HackerRef badge. 191 00:08:56,400 --> 00:08:59,280 Maybe some of you got one. 192 00:08:59,580 --> 00:09:00,600 But basically, 193 00:09:01,380 --> 00:09:03,100 I was in front of thousands of people 194 00:09:03,100 --> 00:09:04,440 with an HackerRef. 195 00:09:04,640 --> 00:09:06,900 And this badge communicates 196 00:09:06,900 --> 00:09:09,520 through the 2.4 GHz band 197 00:09:09,520 --> 00:09:11,700 and it was very difficult 198 00:09:11,700 --> 00:09:13,720 to perform a valid capture 199 00:09:13,720 --> 00:09:15,940 of BLE data, of course. 200 00:09:16,120 --> 00:09:17,740 So this is difficult to sniff. 201 00:09:19,500 --> 00:09:20,220 To perform 202 00:09:20,240 --> 00:09:22,280 I just found this 203 00:09:22,280 --> 00:09:23,220 on Twitter. 204 00:09:24,000 --> 00:09:25,180 It's Samy Kamkar 205 00:09:26,800 --> 00:09:28,700 posting a picture 206 00:09:28,700 --> 00:09:30,080 of what he called 207 00:09:30,080 --> 00:09:32,320 the new Faraday cache technology 208 00:09:32,320 --> 00:09:33,140 from Ikea. 209 00:09:34,400 --> 00:09:36,380 It's a way to do this. 210 00:09:36,540 --> 00:09:37,360 It works, 211 00:09:37,560 --> 00:09:38,820 in a way, 212 00:09:38,920 --> 00:09:40,920 but you can also use 213 00:09:40,920 --> 00:09:42,360 a microwave oven. 214 00:09:44,400 --> 00:09:45,840 So basically, 215 00:09:45,860 --> 00:09:47,240 it's much more 216 00:09:47,240 --> 00:09:48,020 MacGyver style. 217 00:09:50,240 --> 00:09:51,440 Maybe used to 218 00:09:51,940 --> 00:09:53,100 get accurate data 219 00:09:53,100 --> 00:09:54,360 from BLE sniffing. 220 00:09:55,820 --> 00:09:57,740 At Digital Security, 221 00:09:58,060 --> 00:09:59,660 we have the professional 222 00:10:00,240 --> 00:10:02,100 Faraday cache that looks like this. 223 00:10:02,160 --> 00:10:03,300 It costs a lot. 224 00:10:04,440 --> 00:10:05,200 Many, 225 00:10:06,260 --> 00:10:07,020 many, 226 00:10:07,020 --> 00:10:08,640 many thousands of euros 227 00:10:08,640 --> 00:10:09,460 or dollars. 228 00:10:09,840 --> 00:10:11,260 It's not affordable 229 00:10:11,260 --> 00:10:13,520 for a single researcher. 230 00:10:16,720 --> 00:10:17,680 Some information 231 00:10:17,680 --> 00:10:18,560 about the SMP, 232 00:10:20,240 --> 00:10:21,260 I showed you that 233 00:10:21,260 --> 00:10:22,580 the Bluetooth smart 234 00:10:22,580 --> 00:10:24,260 implements some kind of 235 00:10:24,260 --> 00:10:24,980 encryptions. 236 00:10:25,160 --> 00:10:27,400 So between mobile 237 00:10:27,400 --> 00:10:29,360 smartphone and device 238 00:10:29,360 --> 00:10:30,140 we can have 239 00:10:30,140 --> 00:10:33,880 we can set up an encryption 240 00:10:33,880 --> 00:10:36,320 and have an encrypted 241 00:10:36,320 --> 00:10:36,700 communication. 242 00:10:37,040 --> 00:10:38,660 So this is performed this way. 243 00:10:39,180 --> 00:10:40,580 When you are connecting 244 00:10:40,580 --> 00:10:42,100 your smartphone to a device, 245 00:10:42,260 --> 00:10:43,380 bounding your smartphone 246 00:10:43,380 --> 00:10:46,780 to a device, you send a pairing request, 247 00:10:50,240 --> 00:10:52,120 what kind of bounding you support. 248 00:10:52,400 --> 00:10:54,400 So if you read the specifications, 249 00:10:54,620 --> 00:10:55,260 Bluetooth specifications, 250 00:10:55,540 --> 00:10:56,280 there are many of them. 251 00:10:56,940 --> 00:10:58,680 The first one is just works. 252 00:10:58,740 --> 00:10:59,560 No pin code. 253 00:10:59,780 --> 00:11:01,460 It just works. 254 00:11:01,540 --> 00:11:05,160 Like its name says. 255 00:11:05,400 --> 00:11:07,960 And you can also provide a pin code. 256 00:11:08,240 --> 00:11:10,540 And the other one 257 00:11:10,540 --> 00:11:11,580 is the OOB 258 00:11:12,520 --> 00:11:13,080 bounding, 259 00:11:13,080 --> 00:11:15,180 which requires a net of bound 260 00:11:15,180 --> 00:11:17,280 communication means to provide 261 00:11:17,280 --> 00:11:20,160 both the device and smartphone with a bounding 262 00:11:20,240 --> 00:11:20,460 information. 263 00:11:21,520 --> 00:11:23,080 Then they agree on 264 00:11:23,080 --> 00:11:25,480 what is called a STK, 265 00:11:25,600 --> 00:11:27,980 a short term key used to encrypt 266 00:11:27,980 --> 00:11:30,260 the following step. 267 00:11:30,500 --> 00:11:32,000 And during this following 268 00:11:32,000 --> 00:11:33,720 step, the long term key 269 00:11:33,720 --> 00:11:36,040 is provided to the device 270 00:11:36,040 --> 00:11:37,540 and also some information about 271 00:11:37,540 --> 00:11:38,760 identity and revocation. 272 00:11:39,060 --> 00:11:41,880 So this can be used to check 273 00:11:41,880 --> 00:11:43,560 if the device that 274 00:11:44,100 --> 00:11:45,900 uses encryption is a valid one. 275 00:11:46,340 --> 00:11:47,440 And of course to 276 00:11:48,440 --> 00:11:49,440 encrypt all the 277 00:11:50,240 --> 00:11:50,520 communication. 278 00:11:51,740 --> 00:11:53,740 Again, this is a problem 279 00:11:53,740 --> 00:11:56,000 when we want to 280 00:11:56,000 --> 00:11:57,280 sniff some 281 00:11:58,120 --> 00:11:58,940 BLE communication. 282 00:12:00,520 --> 00:12:01,720 But many 283 00:12:02,240 --> 00:12:03,940 security researchers found 284 00:12:03,940 --> 00:12:05,340 a way to bypass it. 285 00:12:05,580 --> 00:12:07,680 A tool called 286 00:12:08,120 --> 00:12:08,420 CrackID. 287 00:12:08,660 --> 00:12:11,480 Also BTPin, which is 288 00:12:11,480 --> 00:12:13,340 a tool that performs the same attack. 289 00:12:13,620 --> 00:12:15,460 So basically you sniff all the traffic 290 00:12:15,460 --> 00:12:17,400 between a smartphone 291 00:12:17,400 --> 00:12:19,980 and a device and then you break 292 00:12:20,240 --> 00:12:21,820 the encryption once you 293 00:12:21,820 --> 00:12:23,780 get all the data. 294 00:12:24,900 --> 00:12:26,140 So the keys 295 00:12:26,140 --> 00:12:27,120 can be recovered this way. 296 00:12:27,300 --> 00:12:30,240 So this is basically how we perform 297 00:12:30,240 --> 00:12:32,040 Bluetooth smart 298 00:12:32,040 --> 00:12:32,780 security 299 00:12:34,160 --> 00:12:35,720 assessments since then. 300 00:12:35,840 --> 00:12:37,460 By using mainly 301 00:12:38,240 --> 00:12:39,840 sniffing to guess 302 00:12:39,840 --> 00:12:41,640 all the devices in the smartphone 303 00:12:41,640 --> 00:12:43,580 exchange data. 304 00:12:43,780 --> 00:12:45,580 And what is the data exchange between them. 305 00:12:46,540 --> 00:12:47,220 So 306 00:12:48,220 --> 00:12:48,560 many 307 00:12:50,240 --> 00:12:50,560 things to 308 00:12:50,560 --> 00:12:53,240 tell about it. 309 00:12:53,320 --> 00:12:56,020 First of all is that few 310 00:12:56,020 --> 00:12:57,960 devices use encryption. 311 00:12:58,380 --> 00:12:59,640 So if you buy 312 00:13:00,170 --> 00:13:01,680 many BLE enabled 313 00:13:02,190 --> 00:13:03,660 devices, few of them 314 00:13:03,660 --> 00:13:04,920 use bounding. 315 00:13:05,440 --> 00:13:07,700 And this is very interesting because 316 00:13:08,240 --> 00:13:10,540 bounding provides a way to encrypt 317 00:13:10,540 --> 00:13:11,780 communication but also 318 00:13:11,780 --> 00:13:13,280 to perform strong authentication. 319 00:13:13,680 --> 00:13:16,100 So almost 320 00:13:16,100 --> 00:13:18,000 all devices are not strongly 321 00:13:18,000 --> 00:13:18,820 authenticated. 322 00:13:20,240 --> 00:13:21,560 This is a problem. 323 00:13:21,840 --> 00:13:23,940 Some of them performs authentication 324 00:13:23,940 --> 00:13:25,820 but only on the 325 00:13:25,820 --> 00:13:27,920 BD address which is basically a MAC 326 00:13:27,920 --> 00:13:29,440 address of the 327 00:13:29,940 --> 00:13:31,280 Bluetooth device. 328 00:13:31,760 --> 00:13:34,040 So sniffing attacks are difficult to perform 329 00:13:34,040 --> 00:13:35,760 but there are many 330 00:13:35,760 --> 00:13:38,180 many weaknesses, non-weaknesses 331 00:13:38,180 --> 00:13:40,320 in the devices we want to test. 332 00:13:42,480 --> 00:13:43,840 And here comes 333 00:13:43,840 --> 00:13:45,280 the man in the middle attack. 334 00:13:46,020 --> 00:13:47,900 It was an attack 335 00:13:48,700 --> 00:13:49,420 ummm 336 00:13:50,240 --> 00:13:51,720 which was theoretical 337 00:13:52,240 --> 00:13:54,200 and it was 338 00:13:54,200 --> 00:13:55,840 mentioned by many 339 00:13:55,840 --> 00:13:56,760 security researchers. 340 00:13:57,320 --> 00:13:58,680 Especially some 341 00:13:59,760 --> 00:14:02,180 researchers who presented here at DEF CON 342 00:14:02,180 --> 00:14:03,640 in the precedented edition. 343 00:14:04,180 --> 00:14:05,220 It's ummm 344 00:14:05,220 --> 00:14:07,840 it's not an easy attack to 345 00:14:07,840 --> 00:14:10,220 set up but as you're going to see 346 00:14:10,220 --> 00:14:11,040 it's 347 00:14:11,040 --> 00:14:13,820 we managed to get it 348 00:14:13,820 --> 00:14:15,900 working on many devices. 349 00:14:18,700 --> 00:14:19,880 Why BD 350 00:14:19,880 --> 00:14:21,120 sniffing sucks. 351 00:14:21,520 --> 00:14:23,820 First, because of the devices you need 352 00:14:23,820 --> 00:14:25,300 to perform sniffing. 353 00:14:25,940 --> 00:14:27,740 You are maybe aware 354 00:14:27,740 --> 00:14:28,660 of the Ubertus 355 00:14:28,660 --> 00:14:30,760 which is a USB 356 00:14:31,680 --> 00:14:33,100 adapter you can plug 357 00:14:33,100 --> 00:14:35,380 in your computer that provides 358 00:14:35,380 --> 00:14:37,680 many many many ways to 359 00:14:37,680 --> 00:14:39,680 get information. So it performs 360 00:14:39,680 --> 00:14:41,180 the synchronization step and 361 00:14:41,620 --> 00:14:43,420 follow every apps to get information 362 00:14:43,420 --> 00:14:45,140 from the BD exchange. 363 00:14:47,640 --> 00:14:49,560 Many, some of you have used the 364 00:14:49,880 --> 00:14:51,040 I've already used the 365 00:14:51,040 --> 00:14:52,980 Adafruit Bluefruit Sniffer 366 00:14:53,880 --> 00:14:54,400 yeah 367 00:14:55,630 --> 00:14:56,720 which is ummm 368 00:14:56,720 --> 00:14:59,760 which works. It's a very 369 00:14:59,760 --> 00:15:01,220 awesome tool. The 370 00:15:02,200 --> 00:15:03,860 only non-limitation 371 00:15:03,860 --> 00:15:04,780 is that it 372 00:15:04,780 --> 00:15:07,500 creates some 373 00:15:07,500 --> 00:15:09,540 non-standard pick up files. 374 00:15:09,860 --> 00:15:11,000 So it's ummm 375 00:15:11,000 --> 00:15:13,320 quite difficult to analyze the 376 00:15:13,320 --> 00:15:15,120 exchange between the two devices. 377 00:15:15,600 --> 00:15:17,220 So it's uh 378 00:15:17,220 --> 00:15:19,240 cheaper than the Ubertus but uh 379 00:15:19,880 --> 00:15:21,740 the drawback as you have to 380 00:15:21,740 --> 00:15:23,080 use some 381 00:15:23,080 --> 00:15:25,040 some specific 382 00:15:25,700 --> 00:15:27,420 plug-ins for Wireshark in order to 383 00:15:27,420 --> 00:15:29,680 some of these sectors to be able to 384 00:15:29,680 --> 00:15:31,780 analyze what data is 385 00:15:31,780 --> 00:15:33,740 exchanged and what operations are made 386 00:15:33,740 --> 00:15:34,560 on the GAT stack. 387 00:15:36,720 --> 00:15:37,780 BT Proxy 388 00:15:37,780 --> 00:15:39,920 well known 389 00:15:39,920 --> 00:15:41,640 tool used for Bluetooth 390 00:15:41,640 --> 00:15:42,060 classic. 391 00:15:43,520 --> 00:15:44,760 Obviously they 392 00:15:44,760 --> 00:15:47,760 they do not plan to 393 00:15:47,760 --> 00:15:49,240 work on Bluetooth low energy. 394 00:15:49,880 --> 00:15:51,780 It works perfectly for 395 00:15:51,780 --> 00:15:53,060 Bluetooth classic but 396 00:15:53,060 --> 00:15:55,140 it has absolutely nothing to 397 00:15:55,140 --> 00:15:57,780 to provide for 398 00:15:57,780 --> 00:15:58,820 Bluetooth low energy. 399 00:16:01,600 --> 00:16:03,700 I did not modify BT Proxy but 400 00:16:03,700 --> 00:16:09,740 So basically when you have 401 00:16:09,740 --> 00:16:10,760 when you face encryption 402 00:16:10,760 --> 00:16:13,560 the strategy, the attack strategy is to 403 00:16:13,560 --> 00:16:15,580 sniff first and then decrypt. 404 00:16:15,680 --> 00:16:17,180 So you cannot interact 405 00:16:17,880 --> 00:16:19,620 you cannot modify on the fly. 406 00:16:19,880 --> 00:16:21,000 The data. You only 407 00:16:21,000 --> 00:16:23,560 you can only monitor what is exchanged 408 00:16:23,560 --> 00:16:24,380 between two devices. 409 00:16:26,380 --> 00:16:27,140 So 410 00:16:27,880 --> 00:16:29,660 it's a pain in the ass 411 00:16:29,660 --> 00:16:31,820 to get something sniffing 412 00:16:31,820 --> 00:16:33,700 and to get information by 413 00:16:33,700 --> 00:16:35,280 sniffing between 414 00:16:35,880 --> 00:16:37,900 between two BTLE 415 00:16:37,900 --> 00:16:38,900 enabled devices. 416 00:16:39,280 --> 00:16:40,860 So Magnum Middle is a 417 00:16:40,860 --> 00:16:43,460 way to bypass all of these 418 00:16:43,460 --> 00:16:44,140 limitations. 419 00:16:45,720 --> 00:16:47,760 It's very very simple to 420 00:16:47,760 --> 00:16:49,000 to set up 421 00:16:49,880 --> 00:16:51,060 on paper but 422 00:16:51,060 --> 00:16:53,920 to get it working on my computer 423 00:16:53,920 --> 00:16:54,220 it was 424 00:16:54,220 --> 00:16:56,700 a lot difficult. 425 00:16:58,400 --> 00:16:59,400 So basically 426 00:16:59,400 --> 00:17:01,360 how can we perform 427 00:17:01,360 --> 00:17:03,480 some kind of Magnum Middle using 428 00:17:03,480 --> 00:17:05,200 on Bluetooth smart. 429 00:17:05,460 --> 00:17:06,980 First of all we set up 430 00:17:07,700 --> 00:17:09,480 what I call a proxy 431 00:17:09,480 --> 00:17:11,140 which is the central here. 432 00:17:11,380 --> 00:17:12,740 The central is simply 433 00:17:12,740 --> 00:17:15,720 a kind of service that will connect 434 00:17:15,720 --> 00:17:17,860 to BT or Bluetooth smart 435 00:17:17,860 --> 00:17:19,760 device. So using 436 00:17:19,880 --> 00:17:22,120 a classic BT4 437 00:17:22,120 --> 00:17:24,140 adapter you can plug in 438 00:17:24,140 --> 00:17:25,760 with some kind of USB. 439 00:17:25,900 --> 00:17:27,880 It also works with your embedded 440 00:17:27,880 --> 00:17:29,500 adapter in your laptop so 441 00:17:29,500 --> 00:17:30,860 it's very easy to perform. 442 00:17:31,120 --> 00:17:33,840 And this central communicates 443 00:17:33,840 --> 00:17:36,100 with the dummy device. 444 00:17:36,440 --> 00:17:37,620 This dummy device 445 00:17:37,620 --> 00:17:39,940 it's again a service 446 00:17:39,940 --> 00:17:41,360 that will 447 00:17:41,880 --> 00:17:43,660 create or simulate 448 00:17:43,660 --> 00:17:45,880 a real BTLD device 449 00:17:45,880 --> 00:17:47,720 with the exact same 450 00:17:47,720 --> 00:17:49,580 characteristics that the one 451 00:17:49,880 --> 00:17:51,280 you are going to interact with. 452 00:17:52,480 --> 00:17:53,800 So first we connect 453 00:17:53,800 --> 00:17:54,320 to the device 454 00:17:55,620 --> 00:17:57,840 then we create this dummy device 455 00:17:57,840 --> 00:17:59,840 which is in fact a clone 456 00:17:59,840 --> 00:18:01,020 of the first one 457 00:18:01,020 --> 00:18:03,140 with the exact same services and 458 00:18:03,140 --> 00:18:05,600 characteristics and so on. 459 00:18:06,940 --> 00:18:07,740 And then 460 00:18:07,740 --> 00:18:09,780 we wait for a connection to the dummy device 461 00:18:09,780 --> 00:18:11,320 from a smart phone, mobile application 462 00:18:11,320 --> 00:18:12,900 and so on. And then we forward 463 00:18:12,900 --> 00:18:15,260 the information between the 464 00:18:15,640 --> 00:18:17,120 smart phone and the target device 465 00:18:17,120 --> 00:18:18,420 in a 466 00:18:19,280 --> 00:18:20,300 bidirectional way. 467 00:18:20,460 --> 00:18:21,200 So it's 468 00:18:22,120 --> 00:18:24,000 quite straightforward to set 469 00:18:24,000 --> 00:18:25,160 up on paper. 470 00:18:25,500 --> 00:18:27,560 It's the basics of 471 00:18:28,220 --> 00:18:29,420 man-in-the-middle and proxy. 472 00:18:30,100 --> 00:18:30,820 So 473 00:18:32,640 --> 00:18:34,520 why not create a tool 474 00:18:34,520 --> 00:18:36,220 that allows people 475 00:18:36,220 --> 00:18:38,060 to do the same attack 476 00:18:38,060 --> 00:18:39,260 very easily. 477 00:18:40,600 --> 00:18:42,180 This is very 478 00:18:42,180 --> 00:18:44,180 easy to write on paper 479 00:18:44,180 --> 00:18:45,380 but to do it 480 00:18:45,380 --> 00:18:48,100 it was quite difficult 481 00:18:48,420 --> 00:18:48,840 but in fact 482 00:18:48,840 --> 00:18:51,900 there are many libraries 483 00:18:51,900 --> 00:18:52,800 well known libraries 484 00:18:52,800 --> 00:18:54,100 called Noble and Blino 485 00:18:54,100 --> 00:18:57,120 and these libraries were developed 486 00:18:57,120 --> 00:18:58,980 by Sunday Mystery 487 00:18:58,980 --> 00:19:00,160 and put on Github 488 00:19:00,160 --> 00:19:01,760 so it's totally open source. 489 00:19:02,240 --> 00:19:04,060 Noble is in charge of 490 00:19:04,060 --> 00:19:06,560 all the connection operations 491 00:19:06,560 --> 00:19:07,940 so when you want to connect 492 00:19:07,940 --> 00:19:09,960 to a BTLD device 493 00:19:09,960 --> 00:19:12,240 you can use it 494 00:19:12,240 --> 00:19:13,980 and perform all the discovery 495 00:19:13,980 --> 00:19:16,300 and the interaction with the device. 496 00:19:18,420 --> 00:19:19,600 It's very good to create 497 00:19:19,600 --> 00:19:20,260 a dummy device. 498 00:19:20,500 --> 00:19:24,000 You can create Bluetooth smart peripherals 499 00:19:24,000 --> 00:19:25,440 and provide services and characteristics. 500 00:19:25,940 --> 00:19:28,300 So you have in one hand 501 00:19:28,300 --> 00:19:30,260 Noble which 502 00:19:30,260 --> 00:19:32,040 provides all the stuff 503 00:19:32,040 --> 00:19:33,260 to connect to a target device 504 00:19:33,260 --> 00:19:34,720 and in other hand 505 00:19:34,720 --> 00:19:36,840 you have Blino library 506 00:19:36,840 --> 00:19:38,600 allowing all the stuff 507 00:19:38,600 --> 00:19:41,480 providing all the stuff to create 508 00:19:41,480 --> 00:19:43,120 and simulate a device. 509 00:19:43,320 --> 00:19:44,780 So we have everything 510 00:19:44,780 --> 00:19:47,660 we need to perform 511 00:19:48,420 --> 00:19:48,560 to create a dummy device. 512 00:19:48,560 --> 00:19:48,720 and this is a manual attack. 513 00:19:49,300 --> 00:19:51,960 This manual attack relies on 514 00:19:51,960 --> 00:19:54,500 standard BT4 adapters. 515 00:19:54,660 --> 00:19:56,360 There is no expensive 516 00:19:57,960 --> 00:19:59,360 hardware to buy 517 00:19:59,360 --> 00:20:01,180 so it's very interesting. 518 00:20:01,420 --> 00:20:02,780 The communication between 519 00:20:02,780 --> 00:20:04,940 the dummy device and the proxy 520 00:20:04,940 --> 00:20:06,660 is made through web circuits. 521 00:20:07,000 --> 00:20:08,160 So this is again 522 00:20:08,160 --> 00:20:09,080 some kind of standard 523 00:20:09,080 --> 00:20:10,580 that can be used to communicate 524 00:20:10,580 --> 00:20:12,300 with a web browser or something like that. 525 00:20:18,420 --> 00:20:19,400 This is a Linux kernel configuration 526 00:20:19,400 --> 00:20:21,740 so you have to use 527 00:20:21,740 --> 00:20:24,280 a version of Linux kernel 528 00:20:24,280 --> 00:20:26,280 4.x, 4.2 529 00:20:26,280 --> 00:20:28,560 and a specific version of 530 00:20:28,560 --> 00:20:28,940 BlueZid. 531 00:20:29,060 --> 00:20:30,720 So the fact 532 00:20:30,720 --> 00:20:33,960 this attack relies on 533 00:20:33,960 --> 00:20:35,140 BlueZid version 5 534 00:20:36,280 --> 00:20:37,820 it may cause problems 535 00:20:37,820 --> 00:20:38,920 on some distros 536 00:20:38,920 --> 00:20:41,660 because BlueZid 5 is not 537 00:20:42,020 --> 00:20:44,040 deployed widely on many distros 538 00:20:44,040 --> 00:20:46,280 so if you are using Debian 539 00:20:46,280 --> 00:20:46,820 for instance 540 00:20:48,420 --> 00:20:48,980 BlueZid 4 by default 541 00:20:48,980 --> 00:20:50,540 and if you are using Ubuntu 542 00:20:50,540 --> 00:20:51,820 it's a BlueZid 5 543 00:20:51,820 --> 00:20:55,520 you can upgrade BlueZid if you want 544 00:20:55,520 --> 00:20:57,900 but it's up to you to do it well 545 00:20:57,900 --> 00:20:58,920 in order not to 546 00:20:59,960 --> 00:21:01,540 put a mess on your system. 547 00:21:03,680 --> 00:21:05,240 The architecture is the following 548 00:21:05,240 --> 00:21:06,860 so we have the proxy 549 00:21:06,860 --> 00:21:09,500 using Noble to connect to the target device 550 00:21:09,500 --> 00:21:12,020 and the core CS service 551 00:21:12,020 --> 00:21:14,060 which uses Blinu 552 00:21:14,060 --> 00:21:15,460 to create a dummy device 553 00:21:15,460 --> 00:21:17,700 so we are creating a fake device 554 00:21:18,420 --> 00:21:19,520 the core and proxy communicate 555 00:21:19,520 --> 00:21:20,260 through a web circuit 556 00:21:20,260 --> 00:21:23,440 and the core service also provides 557 00:21:23,440 --> 00:21:24,500 a web interface 558 00:21:24,500 --> 00:21:27,800 which is basically a burp like interface 559 00:21:28,420 --> 00:21:30,220 allowing the user to 560 00:21:30,220 --> 00:21:32,080 see what happens in the 561 00:21:32,080 --> 00:21:33,460 Bluetooth smart communication 562 00:21:33,460 --> 00:21:35,680 and also to interact with the device 563 00:21:35,680 --> 00:21:37,280 I will demonstrate it later 564 00:21:38,800 --> 00:21:41,040 I also provide bindings 565 00:21:41,040 --> 00:21:42,460 for Python 566 00:21:42,460 --> 00:21:44,900 and Node.js 567 00:21:44,900 --> 00:21:45,900 but 568 00:21:46,300 --> 00:21:47,500 I had a surprise 569 00:21:48,420 --> 00:21:49,480 I got an email 570 00:21:49,480 --> 00:21:50,480 from someone 571 00:21:51,440 --> 00:21:52,480 telling me 572 00:21:52,480 --> 00:21:54,380 hey I made the same tool 573 00:21:54,380 --> 00:21:55,740 and presented it at Blackhat 574 00:21:56,840 --> 00:21:57,640 wow 575 00:21:59,080 --> 00:22:01,020 he is just here 576 00:22:02,020 --> 00:22:03,780 so I told him 577 00:22:03,780 --> 00:22:04,820 yeah let's meet 578 00:22:04,820 --> 00:22:06,780 let's discuss about it 579 00:22:06,780 --> 00:22:08,280 let's see 580 00:22:08,280 --> 00:22:10,940 what we did 581 00:22:10,940 --> 00:22:13,480 and what we did differently 582 00:22:14,220 --> 00:22:14,620 obviously 583 00:22:14,620 --> 00:22:16,460 but in fact 584 00:22:18,420 --> 00:22:20,480 it was based 585 00:22:20,480 --> 00:22:21,860 on the same technologies 586 00:22:22,420 --> 00:22:23,280 wow 587 00:22:23,280 --> 00:22:23,940 so 588 00:22:25,920 --> 00:22:27,520 this is 589 00:22:27,520 --> 00:22:29,720 the exact same setup 590 00:22:30,420 --> 00:22:31,400 that he designed 591 00:22:31,400 --> 00:22:32,900 and this is quite interesting 592 00:22:32,900 --> 00:22:34,580 because it means 593 00:22:34,580 --> 00:22:35,760 I did the right way 594 00:22:35,760 --> 00:22:37,840 what I wanted to do 595 00:22:37,840 --> 00:22:38,880 so 596 00:22:39,860 --> 00:22:41,420 this tool is called 597 00:22:41,420 --> 00:22:42,940 gethack 598 00:22:42,940 --> 00:22:46,100 and there is a website gethack.io 599 00:22:48,920 --> 00:22:50,300 with a cool logo 600 00:22:50,300 --> 00:22:50,620 yeah 601 00:22:52,220 --> 00:22:52,980 and 602 00:22:54,900 --> 00:22:55,660 obviously 603 00:22:56,120 --> 00:22:58,480 this tool implements more tricks 604 00:22:58,480 --> 00:22:59,940 about Noble and Brino 605 00:22:59,940 --> 00:23:02,140 I mean this guy modified 606 00:23:02,140 --> 00:23:03,520 Brino and Noble libraries 607 00:23:03,520 --> 00:23:05,320 to get it working better 608 00:23:06,120 --> 00:23:07,440 so it 609 00:23:07,440 --> 00:23:09,720 improved these libraries to 610 00:23:10,320 --> 00:23:11,640 do the 611 00:23:11,640 --> 00:23:12,300 attack 612 00:23:12,300 --> 00:23:15,120 so when I started my development 613 00:23:15,120 --> 00:23:18,120 I didn't want to modify 614 00:23:18,420 --> 00:23:19,620 these libraries because I wanted to 615 00:23:19,620 --> 00:23:21,680 be easily instable 616 00:23:21,680 --> 00:23:23,420 through NPM or something like this 617 00:23:23,420 --> 00:23:25,280 well anyway 618 00:23:25,280 --> 00:23:27,040 so this other tool exists 619 00:23:27,040 --> 00:23:28,640 which have some 620 00:23:28,640 --> 00:23:32,020 many differences between 621 00:23:32,020 --> 00:23:34,340 between mine 622 00:23:34,340 --> 00:23:34,540 and 623 00:23:34,540 --> 00:23:38,520 his approach is a bit different 624 00:23:38,520 --> 00:23:39,920 from the 625 00:23:39,920 --> 00:23:41,380 attack strategy 626 00:23:41,380 --> 00:23:44,320 we will see this later 627 00:23:44,320 --> 00:23:45,920 so hopefully 628 00:23:45,920 --> 00:23:47,480 I thought 629 00:23:48,500 --> 00:23:49,980 I had enough time 630 00:23:49,980 --> 00:23:51,060 to put it on NPM 631 00:23:51,060 --> 00:23:53,320 I was quite busy yesterday 632 00:23:53,320 --> 00:23:56,060 stressing with this tool 633 00:23:56,060 --> 00:23:57,620 I was not aware 634 00:23:57,620 --> 00:23:59,200 before writing this slide 635 00:23:59,200 --> 00:24:00,840 so it took me some time 636 00:24:00,840 --> 00:24:03,620 I've set up all the Github 637 00:24:03,620 --> 00:24:05,760 I will give all the URLs later 638 00:24:05,760 --> 00:24:08,660 but all the code is already open source 639 00:24:08,660 --> 00:24:09,700 and available 640 00:24:10,540 --> 00:24:12,060 and in fact 641 00:24:12,060 --> 00:24:14,300 I will publish it on NPM 642 00:24:14,300 --> 00:24:15,420 right after this talk 643 00:24:15,420 --> 00:24:16,420 with the slides 644 00:24:18,420 --> 00:24:19,320 through NPM 645 00:24:22,060 --> 00:24:22,620 what? 646 00:24:27,360 --> 00:24:29,260 you have to reserve a name on NPM? 647 00:24:30,860 --> 00:24:31,420 nope 648 00:24:32,440 --> 00:24:33,940 be kind guys 649 00:24:35,480 --> 00:24:36,040 well 650 00:24:36,040 --> 00:24:37,980 maybe the name will change on NPM 651 00:24:37,980 --> 00:24:39,860 so it depends on the availability 652 00:24:41,060 --> 00:24:41,620 well 653 00:24:42,160 --> 00:24:43,540 that's what we call a fail 654 00:24:43,540 --> 00:24:44,740 I see 655 00:24:46,040 --> 00:24:47,160 anyway so 656 00:24:48,580 --> 00:24:50,660 the idea was to provide an easy setup 657 00:24:50,660 --> 00:24:51,140 through NPM 658 00:24:51,140 --> 00:24:53,020 also for the bindings 659 00:24:53,020 --> 00:24:54,480 through NPM and PIPI 660 00:24:54,480 --> 00:24:56,380 the web UI 661 00:24:56,380 --> 00:24:59,420 user interface is very basic 662 00:24:59,420 --> 00:25:00,760 and provides all the information 663 00:25:00,760 --> 00:25:02,020 you need 664 00:25:02,020 --> 00:25:04,140 it sadly uses 665 00:25:04,140 --> 00:25:07,340 the exe notation 666 00:25:07,340 --> 00:25:09,020 designed by Angel Batanis 667 00:25:09,020 --> 00:25:11,100 I don't know if you know this guy 668 00:25:11,100 --> 00:25:14,040 I think he has already presented 669 00:25:14,040 --> 00:25:14,660 to Defcon 670 00:25:14,660 --> 00:25:16,460 we presented to Defcon 671 00:25:16,460 --> 00:25:17,020 many years ago 672 00:25:17,020 --> 00:25:20,020 this is a mix of 673 00:25:20,380 --> 00:25:21,620 eggs and ASCII 674 00:25:21,620 --> 00:25:23,400 and this is very 675 00:25:23,400 --> 00:25:26,120 it was useful in my web interface 676 00:25:26,120 --> 00:25:28,520 because I wanted to see the 677 00:25:28,520 --> 00:25:30,320 strings pop up 678 00:25:30,320 --> 00:25:32,260 on the interface 679 00:25:32,260 --> 00:25:34,420 as well as the eggs 680 00:25:34,420 --> 00:25:36,200 so it was a compromise 681 00:25:36,200 --> 00:25:37,360 I made 682 00:25:37,360 --> 00:25:39,660 to get it working 683 00:25:39,660 --> 00:25:41,500 to get nice demos 684 00:25:41,500 --> 00:25:42,440 later 685 00:25:44,660 --> 00:25:45,520 which is not a big deal 686 00:25:45,520 --> 00:25:47,100 the features 687 00:25:47,100 --> 00:25:49,600 this Betelgeuse tool 688 00:25:49,600 --> 00:25:50,140 provides 689 00:25:50,140 --> 00:25:53,440 a kind of monitor 690 00:25:53,440 --> 00:25:54,400 and navigate operations 691 00:25:54,400 --> 00:25:56,420 and data exchange 692 00:25:56,420 --> 00:25:58,520 between different devices 693 00:25:58,520 --> 00:26:00,800 it is designed like 694 00:26:00,800 --> 00:26:03,240 not so 695 00:26:03,240 --> 00:26:04,740 full features 696 00:26:04,740 --> 00:26:06,380 but it's basically 697 00:26:06,380 --> 00:26:07,360 the same idea 698 00:26:07,360 --> 00:26:09,580 I mean you 699 00:26:09,580 --> 00:26:13,240 you can use this tool 700 00:26:14,660 --> 00:26:15,340 on the fly 701 00:26:15,340 --> 00:26:16,420 data modification 702 00:26:16,420 --> 00:26:18,200 you can put some hooks 703 00:26:18,200 --> 00:26:20,180 I will demonstrate it later 704 00:26:20,180 --> 00:26:20,720 with the interface 705 00:26:20,720 --> 00:26:22,660 but it's quite easy to use 706 00:26:22,660 --> 00:26:24,340 and you can also do 707 00:26:24,340 --> 00:26:25,540 some replay attacks 708 00:26:25,540 --> 00:26:27,580 and replay some operations 709 00:26:27,580 --> 00:26:31,480 there are bindings 710 00:26:31,480 --> 00:26:32,560 for Python 2 711 00:26:32,560 --> 00:26:33,440 Python 3 712 00:26:33,440 --> 00:26:34,240 and NodeJS 713 00:26:34,840 --> 00:26:36,100 intended to be used 714 00:26:36,100 --> 00:26:36,700 very easily 715 00:26:45,020 --> 00:26:46,000 there's no problem 716 00:26:47,820 --> 00:26:48,980 the requirements 717 00:26:48,980 --> 00:26:50,120 you need 718 00:26:50,590 --> 00:26:51,780 two machines set up 719 00:26:51,780 --> 00:26:52,520 to get it working 720 00:26:52,520 --> 00:26:54,440 it's better than making 721 00:26:54,440 --> 00:26:55,700 Blinu and Noble 722 00:26:55,700 --> 00:26:56,720 working on the same machine 723 00:26:56,720 --> 00:26:58,240 it's very difficult at this time 724 00:26:58,920 --> 00:27:00,580 it's possible but difficult 725 00:27:00,580 --> 00:27:03,120 I didn't manage to get it working 726 00:27:03,120 --> 00:27:03,440 with the 727 00:27:05,720 --> 00:27:06,620 lucky you 728 00:27:08,340 --> 00:27:09,860 so as I said 729 00:27:09,860 --> 00:27:11,160 it still has some 730 00:27:11,640 --> 00:27:13,020 some improvements 731 00:27:14,300 --> 00:27:15,100 well 732 00:27:15,100 --> 00:27:17,380 the best is 733 00:27:17,380 --> 00:27:19,440 by using a virtual machine 734 00:27:19,440 --> 00:27:21,720 this is the setup I have 735 00:27:21,720 --> 00:27:23,800 here to make all my demos 736 00:27:23,800 --> 00:27:25,820 and you only need 737 00:27:25,820 --> 00:27:27,200 two bluetooth 738 00:27:27,600 --> 00:27:29,200 4 adapters 739 00:27:30,320 --> 00:27:31,700 looks like this 740 00:27:31,700 --> 00:27:33,380 if you can find some 741 00:27:33,380 --> 00:27:34,740 CSO adapters 742 00:27:34,740 --> 00:27:36,760 this is good to go 743 00:27:36,760 --> 00:27:39,180 because this adapters 744 00:27:39,860 --> 00:27:41,840 provides a way to modify the MAC address 745 00:27:41,840 --> 00:27:42,980 or be the address of it 746 00:27:42,980 --> 00:27:44,780 so you can spoof the MAC address 747 00:27:45,660 --> 00:27:47,100 and of course Node 748 00:27:47,100 --> 00:27:48,160 to make it 749 00:27:48,160 --> 00:27:49,340 to get it running 750 00:27:51,340 --> 00:27:52,340 so let's see 751 00:27:54,100 --> 00:27:54,900 all of this 752 00:27:54,900 --> 00:27:56,380 this is the web interface 753 00:27:56,380 --> 00:27:57,800 running on the machine 754 00:27:57,800 --> 00:27:59,540 so to get it working 755 00:27:59,540 --> 00:28:01,260 I have to start a proxy 756 00:28:01,260 --> 00:28:02,520 on the virtual machine 757 00:28:02,520 --> 00:28:04,900 and to start the core service 758 00:28:04,900 --> 00:28:05,540 on mine 759 00:28:09,860 --> 00:28:10,160 like this 760 00:28:17,740 --> 00:28:19,360 I don't know if it's ok 761 00:28:19,860 --> 00:28:20,660 sounds good 762 00:28:23,140 --> 00:28:24,300 so first of all 763 00:28:24,300 --> 00:28:25,160 I start the proxy 764 00:28:25,160 --> 00:28:26,560 on this virtual machine 765 00:28:26,560 --> 00:28:29,140 then I make sure 766 00:28:29,140 --> 00:28:30,820 the bluetooth service is down 767 00:28:32,620 --> 00:28:33,200 because 768 00:28:33,200 --> 00:28:35,080 I have some problems sometimes 769 00:28:35,670 --> 00:28:36,420 it's ok 770 00:28:37,500 --> 00:28:38,440 I have a 771 00:28:40,360 --> 00:28:41,400 bluetooth adapter 772 00:28:41,400 --> 00:28:42,700 up and running 773 00:28:42,700 --> 00:28:44,200 so let's go 774 00:28:46,120 --> 00:28:48,060 I'm starting the interface 775 00:28:48,060 --> 00:28:49,880 and obviously 776 00:28:49,880 --> 00:28:51,760 this is not a good IP address 777 00:28:51,760 --> 00:28:54,080 so here it is 778 00:28:56,520 --> 00:28:57,640 I can 779 00:28:58,300 --> 00:28:59,500 sniff for devices 780 00:28:59,500 --> 00:29:00,740 as I said 781 00:29:00,740 --> 00:29:02,080 there are a lot of them 782 00:29:02,820 --> 00:29:03,740 as you can see 783 00:29:05,200 --> 00:29:06,760 well this is not a problem 784 00:29:06,760 --> 00:29:08,000 I'm going to use 785 00:29:09,860 --> 00:29:10,000 this device 786 00:29:10,000 --> 00:29:11,320 which is a BLE tracker 787 00:29:12,340 --> 00:29:15,200 available in many stores 788 00:29:15,860 --> 00:29:17,080 just to see if we can 789 00:29:17,080 --> 00:29:17,860 impersonate this 790 00:29:18,940 --> 00:29:19,500 well 791 00:29:20,700 --> 00:29:22,100 going to be a challenge 792 00:29:22,100 --> 00:29:22,440 because 793 00:29:25,140 --> 00:29:26,640 should be this one 794 00:29:28,560 --> 00:29:29,500 I have 795 00:29:29,500 --> 00:29:31,060 many of them 796 00:29:31,060 --> 00:29:31,800 right here 797 00:29:31,800 --> 00:29:33,120 so picking the good one 798 00:29:33,120 --> 00:29:34,620 is always a problem 799 00:29:36,660 --> 00:29:38,240 so basically the proxy 800 00:29:43,360 --> 00:29:47,020 the proxy connects to the device 801 00:29:47,020 --> 00:29:48,020 the target device 802 00:29:48,020 --> 00:29:50,440 perform all the discovery 803 00:29:50,440 --> 00:29:51,400 and then 804 00:29:52,760 --> 00:29:54,640 communicates with my core service 805 00:29:54,640 --> 00:29:55,800 and this core service 806 00:29:55,800 --> 00:29:57,160 creates a dummy device 807 00:29:57,160 --> 00:29:59,620 with the exact same information 808 00:30:00,640 --> 00:30:02,880 so if I use my smartphone 809 00:30:02,880 --> 00:30:04,880 to discover this 810 00:30:04,880 --> 00:30:05,940 this device 811 00:30:05,940 --> 00:30:06,820 and communicate with it 812 00:30:06,820 --> 00:30:07,980 I will be able to 813 00:30:07,980 --> 00:30:09,500 to intercept all the information 814 00:30:09,500 --> 00:30:09,840 so if I use my smartphone 815 00:30:13,120 --> 00:30:14,200 let's use it 816 00:30:15,040 --> 00:30:15,840 so 817 00:30:16,820 --> 00:30:18,400 this is my smartphone 818 00:30:18,400 --> 00:30:20,260 my real smartphone 819 00:30:20,260 --> 00:30:20,800 so 820 00:30:20,800 --> 00:30:23,140 I'm going to launch 821 00:30:23,140 --> 00:30:25,960 a BLE scanner 822 00:30:32,240 --> 00:30:33,400 connect to the 823 00:30:33,400 --> 00:30:35,660 the simulated device 824 00:30:35,660 --> 00:30:36,320 the dummy device 825 00:30:36,320 --> 00:30:37,400 and everything 826 00:30:39,860 --> 00:30:40,660 here it is 827 00:30:40,660 --> 00:30:43,120 of course you have a notification 828 00:30:43,120 --> 00:30:45,520 showing that the dummy device 829 00:30:45,520 --> 00:30:47,340 accepted the connection from my smartphone 830 00:30:47,340 --> 00:30:48,140 so it's good 831 00:30:49,680 --> 00:30:51,180 and here the 832 00:30:51,860 --> 00:30:52,680 connection information 833 00:30:52,680 --> 00:30:55,080 I'm going to read 834 00:30:55,080 --> 00:30:56,040 a characteristic 835 00:30:56,040 --> 00:30:58,240 from this device 836 00:30:59,560 --> 00:31:00,800 we have two of them 837 00:31:00,800 --> 00:31:01,580 here 838 00:31:02,500 --> 00:31:04,780 first one should 839 00:31:04,780 --> 00:31:07,780 return the version of the firmware 840 00:31:07,780 --> 00:31:08,940 as the world 841 00:31:09,860 --> 00:31:10,420 0106 842 00:31:10,420 --> 00:31:11,860 and the second one 843 00:31:14,880 --> 00:31:15,560 the 844 00:31:15,560 --> 00:31:18,220 a kind of timestamp 845 00:31:18,220 --> 00:31:18,600 the date 846 00:31:18,600 --> 00:31:22,020 when the firmware was compiled 847 00:31:22,020 --> 00:31:22,760 or built 848 00:31:22,760 --> 00:31:24,680 so this is quite interesting 849 00:31:24,680 --> 00:31:26,380 but if you go back 850 00:31:26,380 --> 00:31:27,660 to the web interface 851 00:31:27,660 --> 00:31:29,400 everything has been logged 852 00:31:29,400 --> 00:31:31,180 and you can use it 853 00:31:33,700 --> 00:31:35,420 furthermore we can put hooks 854 00:31:35,420 --> 00:31:36,540 on this 855 00:31:36,540 --> 00:31:39,460 if I try again 856 00:31:39,860 --> 00:31:41,560 to read the date 857 00:31:41,560 --> 00:31:43,240 I will be notified 858 00:31:43,240 --> 00:31:44,160 on the web interface 859 00:31:44,160 --> 00:31:46,220 and I can modify the data 860 00:31:46,220 --> 00:31:48,540 that will be sent to the mobile application 861 00:31:48,540 --> 00:31:51,040 so just have a look 862 00:31:51,760 --> 00:31:52,960 I'm asking for 863 00:31:53,840 --> 00:31:54,540 this information 864 00:31:54,540 --> 00:31:56,440 so it pops here 865 00:31:57,560 --> 00:31:58,200 set 866 00:31:59,420 --> 00:32:00,520 modify the year 867 00:32:00,520 --> 00:32:03,200 and if you look at the information display here 868 00:32:03,200 --> 00:32:04,620 you have 2016 869 00:32:04,620 --> 00:32:06,640 instead of 2015 870 00:32:06,640 --> 00:32:09,400 so it's very easy to modify this 871 00:32:09,860 --> 00:32:11,340 if you want to remove the hook 872 00:32:11,760 --> 00:32:13,220 just right click, disable hook 873 00:32:13,220 --> 00:32:14,240 and that's it 874 00:32:14,240 --> 00:32:16,260 there is another button here 875 00:32:16,260 --> 00:32:19,700 this button enables global interception 876 00:32:19,700 --> 00:32:21,280 so for every operation 877 00:32:21,280 --> 00:32:22,080 you will be notified 878 00:32:22,080 --> 00:32:25,120 and you can choose to perform the read 879 00:32:25,120 --> 00:32:27,060 perform the write or dismiss it 880 00:32:27,060 --> 00:32:28,460 so you can easily 881 00:32:29,580 --> 00:32:30,820 modify the behavior 882 00:32:30,820 --> 00:32:31,980 of the device 883 00:32:31,980 --> 00:32:35,100 and you also can tamper with 884 00:32:35,100 --> 00:32:37,580 the data exchange between two devices 885 00:32:38,600 --> 00:32:39,240 it's 886 00:32:39,860 --> 00:32:42,000 also easy to perform fuzzing 887 00:32:42,000 --> 00:32:43,420 manual fuzzing with it 888 00:32:43,420 --> 00:32:45,920 because we have some kind of replay attacks 889 00:32:45,920 --> 00:32:47,640 like this 890 00:32:48,380 --> 00:32:49,620 we can 891 00:32:49,620 --> 00:32:50,900 perform some read 892 00:32:50,900 --> 00:32:54,020 by using this 893 00:32:54,020 --> 00:32:54,760 just to 894 00:32:55,540 --> 00:32:56,940 prove this is working 895 00:32:56,940 --> 00:32:59,380 I removed the previous data 896 00:32:59,380 --> 00:33:01,600 but in fact we can get information 897 00:33:01,600 --> 00:33:02,780 from the device 898 00:33:02,780 --> 00:33:04,820 you can read whenever you want 899 00:33:04,820 --> 00:33:06,180 and whatever you want 900 00:33:06,180 --> 00:33:08,520 you can write whenever you want and whatever you want 901 00:33:09,860 --> 00:33:11,320 you can interact with the device 902 00:33:11,810 --> 00:33:14,240 even with mobile applications connected to it 903 00:33:14,240 --> 00:33:14,860 so it's 904 00:33:15,550 --> 00:33:16,740 quite interesting to 905 00:33:16,740 --> 00:33:18,620 try to find vulnerabilities 906 00:33:18,620 --> 00:33:20,480 or maybe glitches 907 00:33:20,480 --> 00:33:22,140 in this device 908 00:33:25,820 --> 00:33:27,780 and we also have 909 00:33:27,780 --> 00:33:29,320 some kind of notification 910 00:33:29,510 --> 00:33:30,360 I don't know if 911 00:33:30,360 --> 00:33:32,660 I have it here 912 00:33:32,660 --> 00:33:35,120 but it also supports notification 913 00:33:35,120 --> 00:33:37,700 you can decide to 914 00:33:37,700 --> 00:33:39,620 forward or dismiss 915 00:33:39,860 --> 00:33:41,680 notification to perform an attack 916 00:33:41,680 --> 00:33:42,180 say 917 00:33:42,180 --> 00:33:51,160 so the benefits 918 00:33:51,160 --> 00:33:53,080 of this system 919 00:33:53,080 --> 00:33:55,400 is that it works with any 920 00:33:55,400 --> 00:33:57,560 Bluetooth 4 adapters 921 00:33:57,560 --> 00:33:59,380 you can use any 922 00:33:59,380 --> 00:34:01,100 CSR compatible device 923 00:34:01,700 --> 00:34:03,360 adapter or even your 924 00:34:03,360 --> 00:34:04,900 embedded Broadcom 925 00:34:04,900 --> 00:34:07,140 Bluetooth adapter it's working 926 00:34:07,140 --> 00:34:09,420 you can intercept every gate operation 927 00:34:09,860 --> 00:34:11,040 notification write or read 928 00:34:11,040 --> 00:34:13,520 and it also supports bounding 929 00:34:13,520 --> 00:34:15,800 encryption on a newer version of 930 00:34:15,800 --> 00:34:17,060 Bluetooth and Linux kernel 931 00:34:17,060 --> 00:34:19,700 if your mobile application tries 932 00:34:19,700 --> 00:34:21,720 to create a bound between 933 00:34:21,720 --> 00:34:23,520 the simulated device 934 00:34:23,520 --> 00:34:25,680 and the mobile application this is possible 935 00:34:25,680 --> 00:34:26,940 you can do it 936 00:34:26,940 --> 00:34:29,000 and this is supported by 937 00:34:29,000 --> 00:34:32,080 the NodeJS library 938 00:34:33,660 --> 00:34:35,280 it's also compatible with tests 939 00:34:35,280 --> 00:34:37,100 made with a forwarded cage 940 00:34:37,720 --> 00:34:39,680 like we do at digital 941 00:34:39,860 --> 00:34:41,600 security because since you need 942 00:34:41,600 --> 00:34:43,580 two machines to 943 00:34:44,860 --> 00:34:47,120 perform this manual attack 944 00:34:47,120 --> 00:34:48,160 you can put a machine 945 00:34:48,160 --> 00:34:50,980 say a Raspberry Pi for instance 946 00:34:50,980 --> 00:34:52,240 in the forwarded cage 947 00:34:52,240 --> 00:34:53,760 and the 948 00:34:53,760 --> 00:34:56,800 another Raspberry Pi outside 949 00:34:56,800 --> 00:34:59,240 to advertise the same device 950 00:34:59,240 --> 00:34:59,860 so it's 951 00:34:59,860 --> 00:35:02,940 compatible with 952 00:35:02,940 --> 00:35:04,040 this kind of test 953 00:35:04,040 --> 00:35:07,720 Bluetooth device address proofing 954 00:35:07,720 --> 00:35:08,700 is also possible 955 00:35:10,180 --> 00:35:11,500 this because of 956 00:35:11,500 --> 00:35:12,740 some features 957 00:35:12,740 --> 00:35:14,920 of the Bluetooth smart 958 00:35:14,920 --> 00:35:15,720 protocol 959 00:35:16,820 --> 00:35:18,340 creating the perfect dummy 960 00:35:18,340 --> 00:35:20,520 when we want to clone and 961 00:35:20,520 --> 00:35:22,320 make a real clone of a device 962 00:35:22,320 --> 00:35:24,680 we want to use the same address 963 00:35:24,680 --> 00:35:26,180 the same MAC address for device 964 00:35:26,180 --> 00:35:28,760 I want to provide the device 965 00:35:28,760 --> 00:35:30,100 with the exact same characteristic 966 00:35:30,100 --> 00:35:30,600 and service 967 00:35:30,600 --> 00:35:34,500 I will show you some tricks 968 00:35:34,500 --> 00:35:37,080 I found to create a perfect clone 969 00:35:37,820 --> 00:35:38,840 by abusing some 970 00:35:39,860 --> 00:35:40,400 characteristics of the 971 00:35:40,400 --> 00:35:41,640 Bluetooth specification 972 00:35:41,640 --> 00:35:44,400 so first of all we connect 973 00:35:44,400 --> 00:35:45,880 to the target device 974 00:35:46,820 --> 00:35:49,040 since the device only supports 975 00:35:49,040 --> 00:35:50,200 one active connection 976 00:35:51,700 --> 00:35:53,680 there is no more advertisement 977 00:35:53,680 --> 00:35:55,900 each Bluetooth smart device 978 00:35:55,900 --> 00:35:56,640 advertises 979 00:35:58,020 --> 00:36:00,240 specifying some manufacturer data 980 00:36:00,240 --> 00:36:00,900 and so on 981 00:36:01,520 --> 00:36:03,800 once we are connected to it 982 00:36:03,800 --> 00:36:05,700 it doesn't advertise anymore 983 00:36:05,700 --> 00:36:07,520 so it's not visible 984 00:36:07,520 --> 00:36:09,300 from a smartphone 985 00:36:09,860 --> 00:36:11,220 or mobile application 986 00:36:11,860 --> 00:36:13,940 and also frequency hopping is active 987 00:36:13,940 --> 00:36:16,260 so that means 988 00:36:16,260 --> 00:36:17,960 the Bluetooth device 989 00:36:17,960 --> 00:36:19,620 hops from channel to channel 990 00:36:19,620 --> 00:36:20,720 and it's 991 00:36:20,720 --> 00:36:23,040 the frequency hopping system 992 00:36:23,040 --> 00:36:25,580 has been designed to avoid interferences 993 00:36:25,580 --> 00:36:26,940 that means 994 00:36:28,100 --> 00:36:29,200 we can 995 00:36:29,810 --> 00:36:31,600 set up another Bluetooth adapter 996 00:36:31,600 --> 00:36:33,280 with the exact same address 997 00:36:33,860 --> 00:36:35,720 advertising all the information 998 00:36:35,720 --> 00:36:37,500 about some kind of device 999 00:36:37,500 --> 00:36:39,480 and it won't interfere 1000 00:36:39,860 --> 00:36:41,840 with the active connection 1001 00:36:41,840 --> 00:36:43,140 we have with the device 1002 00:36:43,140 --> 00:36:45,960 so it's possible to create 1003 00:36:45,960 --> 00:36:47,360 another device with the same 1004 00:36:47,360 --> 00:36:49,760 configuration, same services, same characteristics 1005 00:36:49,760 --> 00:36:50,920 and Bluetooth address 1006 00:36:50,920 --> 00:36:52,880 than the original one 1007 00:36:52,880 --> 00:36:55,420 while keeping the original one busy 1008 00:36:55,420 --> 00:36:56,620 so this is 1009 00:36:56,620 --> 00:36:59,280 possible to create 1010 00:36:59,280 --> 00:37:00,580 the perfect dummy 1011 00:37:01,980 --> 00:37:03,340 the bindings 1012 00:37:03,340 --> 00:37:05,620 in Python provide some classes 1013 00:37:05,620 --> 00:37:07,200 you can use to perform 1014 00:37:07,200 --> 00:37:09,060 some operations 1015 00:37:09,860 --> 00:37:11,180 some modification of data 1016 00:37:11,180 --> 00:37:13,360 you have many callbacks you can use 1017 00:37:13,360 --> 00:37:15,420 and it's quite easy to 1018 00:37:15,420 --> 00:37:16,320 set up 1019 00:37:16,320 --> 00:37:19,240 an application 1020 00:37:19,240 --> 00:37:21,500 I will demonstrate many attacks 1021 00:37:21,500 --> 00:37:23,920 using Python bindings 1022 00:37:23,920 --> 00:37:25,460 and not JS bindings 1023 00:37:26,180 --> 00:37:27,180 it's easy 1024 00:37:27,780 --> 00:37:29,780 the code on 1025 00:37:29,780 --> 00:37:30,100 GitHub 1026 00:37:31,120 --> 00:37:33,040 has some documentation inside 1027 00:37:33,040 --> 00:37:34,080 you can 1028 00:37:36,540 --> 00:37:37,540 read it 1029 00:37:37,540 --> 00:37:38,280 read the documentation 1030 00:37:39,860 --> 00:37:40,380 and explain 1031 00:37:40,380 --> 00:37:42,040 on GitHub 1032 00:37:42,040 --> 00:37:44,020 about how to create 1033 00:37:44,020 --> 00:37:44,820 this kind of applications 1034 00:37:44,820 --> 00:37:47,300 so this bindings 1035 00:37:47,300 --> 00:37:49,140 require the core and proxy 1036 00:37:49,140 --> 00:37:49,740 to be running 1037 00:37:49,740 --> 00:37:51,180 in order to perform the 1038 00:37:51,180 --> 00:37:51,640 in the middle 1039 00:37:52,600 --> 00:37:54,040 we have the same in not JS 1040 00:37:55,740 --> 00:37:57,560 and of course we can perform 1041 00:37:57,560 --> 00:37:59,000 on the fly data modification 1042 00:37:59,000 --> 00:38:01,300 so here is an example 1043 00:38:01,300 --> 00:38:03,120 of battery service 1044 00:38:04,060 --> 00:38:05,420 hooked by the 1045 00:38:09,860 --> 00:38:11,080 un-before read callback 1046 00:38:11,080 --> 00:38:13,220 we modify the information 1047 00:38:13,220 --> 00:38:16,040 returned by the proxy 1048 00:38:16,040 --> 00:38:17,500 if you are with the code 1049 00:38:17,500 --> 00:38:19,140 for a given service 1050 00:38:19,140 --> 00:38:21,360 18.0.f and a given 1051 00:38:21,360 --> 00:38:23,220 characteristics to 8.19 1052 00:38:23,820 --> 00:38:25,500 we modify 1053 00:38:25,500 --> 00:38:26,380 the battery level 1054 00:38:26,380 --> 00:38:28,840 and force the response 1055 00:38:28,840 --> 00:38:31,700 that means the read operation 1056 00:38:31,700 --> 00:38:33,540 is never 1057 00:38:33,540 --> 00:38:35,140 forwarded to the target device 1058 00:38:35,540 --> 00:38:36,600 we answer 1059 00:38:38,120 --> 00:38:39,720 we provide 1060 00:38:39,860 --> 00:38:41,820 the answer to this operation 1061 00:38:41,820 --> 00:38:43,520 so this is 1062 00:38:43,520 --> 00:38:44,440 pretty interesting 1063 00:38:44,440 --> 00:38:45,680 and of course 1064 00:38:45,680 --> 00:38:46,860 the un-before subscribe 1065 00:38:49,100 --> 00:38:49,860 callback 1066 00:38:49,860 --> 00:38:52,540 raise hook force response 1067 00:38:52,540 --> 00:38:54,320 that cause a dismiss 1068 00:38:54,320 --> 00:38:56,480 so there is no more 1069 00:38:56,480 --> 00:38:58,460 subscription possible for notification 1070 00:38:58,460 --> 00:39:01,540 this may be interesting 1071 00:39:01,540 --> 00:39:03,200 in various attacks 1072 00:39:05,740 --> 00:39:07,080 anyway there are some limitations 1073 00:39:07,860 --> 00:39:09,500 with this tool 1074 00:39:09,860 --> 00:39:10,920 because noble does not support 1075 00:39:10,920 --> 00:39:11,980 long writes 1076 00:39:11,980 --> 00:39:13,040 if you try to write 1077 00:39:13,040 --> 00:39:14,400 more than 22 bytes 1078 00:39:14,400 --> 00:39:15,860 in a characteristic 1079 00:39:15,860 --> 00:39:19,060 it hangs all the adapters 1080 00:39:19,060 --> 00:39:19,940 and all the stuff 1081 00:39:19,940 --> 00:39:22,400 it's a drawback I found 1082 00:39:22,400 --> 00:39:25,100 maybe I didn't try yet 1083 00:39:25,100 --> 00:39:26,400 the Gattaca tool 1084 00:39:26,400 --> 00:39:27,800 but since this tool 1085 00:39:27,800 --> 00:39:29,680 performs low level reads 1086 00:39:29,680 --> 00:39:30,260 and writes 1087 00:39:30,260 --> 00:39:32,100 maybe it's not impacted by this 1088 00:39:32,100 --> 00:39:32,620 I don't know 1089 00:39:39,860 --> 00:39:41,260 this is a problem I noticed 1090 00:39:41,740 --> 00:39:43,560 while testing my tool 1091 00:39:43,560 --> 00:39:44,940 there is also 1092 00:39:44,940 --> 00:39:46,100 an induced latency 1093 00:39:46,100 --> 00:39:48,840 I mean there is a delay 1094 00:39:48,840 --> 00:39:51,500 caused by the communication process 1095 00:39:51,500 --> 00:39:53,040 since we are communicating 1096 00:39:53,040 --> 00:39:53,860 through BTLE 1097 00:39:53,860 --> 00:39:56,220 then everything goes through web sockets 1098 00:39:56,220 --> 00:39:57,880 and then back to BTLE 1099 00:39:57,880 --> 00:39:59,580 it includes 1100 00:39:59,580 --> 00:40:02,100 induced some delay 1101 00:40:02,100 --> 00:40:04,120 and this can be detected 1102 00:40:04,120 --> 00:40:04,980 by a device 1103 00:40:04,980 --> 00:40:07,340 to determine if 1104 00:40:09,860 --> 00:40:11,200 manual attack is in progress 1105 00:40:12,200 --> 00:40:13,340 and sometimes 1106 00:40:13,340 --> 00:40:15,460 it may be very tricky to 1107 00:40:16,120 --> 00:40:17,260 intercept the communication 1108 00:40:17,260 --> 00:40:18,600 between the device and the smartphone 1109 00:40:18,600 --> 00:40:21,280 because of the device itself 1110 00:40:21,280 --> 00:40:23,280 sometimes the device only stays up 1111 00:40:23,580 --> 00:40:24,780 or advertises itself 1112 00:40:24,780 --> 00:40:26,600 for a very short amount of time 1113 00:40:26,600 --> 00:40:29,400 so you have a very short 1114 00:40:31,100 --> 00:40:31,740 window 1115 00:40:31,740 --> 00:40:33,680 to communicate 1116 00:40:33,680 --> 00:40:34,360 with the device 1117 00:40:34,360 --> 00:40:35,760 and perform your attack 1118 00:40:38,260 --> 00:40:39,540 so let's 1119 00:40:39,860 --> 00:40:41,180 demonstrate this framework 1120 00:40:41,650 --> 00:40:43,040 I will start with 1121 00:40:43,040 --> 00:40:44,180 this device 1122 00:40:45,040 --> 00:40:46,120 which is a 1123 00:40:47,080 --> 00:40:48,340 BTLE enabled robot 1124 00:40:48,340 --> 00:40:50,720 I don't know if some of you guys 1125 00:40:50,720 --> 00:40:51,800 have this device 1126 00:40:51,800 --> 00:40:55,380 it's not very common 1127 00:40:55,380 --> 00:40:56,560 but a Chinese one 1128 00:40:57,900 --> 00:40:58,640 widespread 1129 00:40:58,640 --> 00:41:01,140 I will put it on 1130 00:41:01,860 --> 00:41:03,440 make some sound 1131 00:41:04,640 --> 00:41:05,720 it's pretty cool 1132 00:41:05,720 --> 00:41:09,120 this robot is like 1133 00:41:09,860 --> 00:41:10,340 a gyro pod 1134 00:41:10,340 --> 00:41:12,360 you just put it on the floor 1135 00:41:12,360 --> 00:41:13,040 until it stands 1136 00:41:13,040 --> 00:41:14,920 I don't know if I can put it 1137 00:41:14,920 --> 00:41:15,700 right here 1138 00:41:15,700 --> 00:41:19,620 it doesn't make much noise 1139 00:41:21,660 --> 00:41:22,320 don't fall 1140 00:41:25,020 --> 00:41:25,920 yeah sounds good 1141 00:41:25,920 --> 00:41:27,200 I'm going to 1142 00:41:27,760 --> 00:41:29,220 create a manual middle 1143 00:41:29,700 --> 00:41:30,520 proxy with this 1144 00:41:30,520 --> 00:41:32,720 maybe on the table 1145 00:41:32,720 --> 00:41:32,980 yeah 1146 00:41:40,020 --> 00:41:41,220 sounds better 1147 00:41:42,420 --> 00:41:43,240 alright we'll see 1148 00:41:43,620 --> 00:41:45,280 so this device 1149 00:41:47,580 --> 00:41:48,580 advertises itself 1150 00:41:48,580 --> 00:41:49,880 this is a Huawei 1151 00:41:50,540 --> 00:41:51,140 MIP 1152 00:41:54,180 --> 00:41:55,780 and we are going to 1153 00:41:55,780 --> 00:41:56,140 create 1154 00:41:56,760 --> 00:41:58,460 to create a proxy 1155 00:41:59,120 --> 00:42:00,180 with all of this 1156 00:42:00,180 --> 00:42:01,100 so the proxy is configured 1157 00:42:01,100 --> 00:42:01,940 and ready to relay 1158 00:42:01,940 --> 00:42:04,080 so normally I will be able to 1159 00:42:05,000 --> 00:42:07,160 to communicate with my 1160 00:42:09,860 --> 00:42:09,880 smartphone 1161 00:42:09,880 --> 00:42:11,860 so let's see if 1162 00:42:11,860 --> 00:42:14,160 everything goes well 1163 00:42:15,820 --> 00:42:17,220 what the 1164 00:42:17,550 --> 00:42:19,620 ok so I'll start the application 1165 00:42:21,600 --> 00:42:22,680 sorry because 1166 00:42:22,680 --> 00:42:24,500 there is a drawback 1167 00:42:24,500 --> 00:42:25,560 with the previous test 1168 00:42:25,560 --> 00:42:26,080 but anyway 1169 00:42:26,080 --> 00:42:28,160 so I try to go to 1170 00:42:28,160 --> 00:42:30,960 which is in fact 1171 00:42:30,960 --> 00:42:33,300 a problem we 1172 00:42:33,860 --> 00:42:34,420 experienced 1173 00:42:34,420 --> 00:42:36,580 when designing the 1174 00:42:36,580 --> 00:42:37,140 the 1175 00:42:40,520 --> 00:42:41,080 device 1176 00:42:41,080 --> 00:42:44,040 I was 1177 00:42:44,040 --> 00:42:44,240 there 1178 00:42:46,680 --> 00:42:47,240 the 1179 00:42:49,360 --> 00:42:50,860 are not with me 1180 00:42:57,360 --> 00:42:58,500 this is a problem 1181 00:42:58,500 --> 00:43:00,120 when you have a lot of devices 1182 00:43:00,120 --> 00:43:00,900 in the room 1183 00:43:04,660 --> 00:43:05,220 yeah 1184 00:43:05,220 --> 00:43:09,760 it should be 1185 00:43:09,860 --> 00:43:09,940 good 1186 00:43:12,640 --> 00:43:13,440 um 1187 00:43:15,540 --> 00:43:16,400 no of course 1188 00:43:16,400 --> 00:43:17,040 um 1189 00:43:18,740 --> 00:43:20,460 so here it is 1190 00:43:20,460 --> 00:43:23,520 and the load of all the devices detected 1191 00:43:26,840 --> 00:43:27,640 damn 1192 00:43:45,400 --> 00:43:46,280 let's do it again 1193 00:43:52,100 --> 00:43:53,200 where it is 1194 00:44:01,400 --> 00:44:03,180 I knew this demo was on 1195 00:44:03,180 --> 00:44:09,040 I saw it working 1196 00:44:09,040 --> 00:44:09,840 half an hour ago 1197 00:44:32,660 --> 00:44:35,420 I've got it working 1198 00:44:35,420 --> 00:44:36,860 it is connected on my 1199 00:44:36,860 --> 00:44:37,680 dummy device 1200 00:44:37,680 --> 00:44:38,620 um 1201 00:44:38,620 --> 00:44:39,840 so right now 1202 00:44:39,840 --> 00:44:49,340 hopefully it will uh perform some gut operations red and white here it is and the fun fact is 1203 00:44:49,620 --> 00:44:56,780 the designers of this of this robot uh included many sounds in it uh you heard of some one of 1204 00:44:56,780 --> 00:45:05,240 them uh I'm going to be very quick but uh in fact this is the uh this line that causes the sound 1205 00:45:05,240 --> 00:45:12,160 to be played on the robot and um I started some kind of replay to see if uh there were if is 1206 00:45:12,160 --> 00:45:25,020 there were many sounds on it and if I can make some uh nice sounds with it. So first of all I'm 1207 00:45:25,020 --> 00:45:33,580 going to pick the uh the second sound in the of the bank and uh and let you hear about hear the 1208 00:45:33,580 --> 00:45:34,000 sound and 1209 00:45:35,380 --> 00:45:46,800 um yeah uh sounds like a test beep uh put on it. Uh wait wait there's more. Because the 1210 00:45:46,800 --> 00:45:59,920 developers had a had a great idea. Um let me uh play the uh third sound on the robot. Uh 1211 00:45:59,920 --> 00:46:13,540 so it disconnected. Uh luckily. I'll do it again. Uh holy crap. So uh. 1212 00:46:15,960 --> 00:46:23,200 Oh. Time problem. Well breaks everything. It was also not so 1213 00:46:27,980 --> 00:46:28,740 Ux. 1214 00:46:29,140 --> 00:46:29,900 So the sound is not so good. So I'm going to do a test beep. So I'm going to do a test beep. So 1215 00:46:29,920 --> 00:46:32,680 wait there's so many sounds on it. Uh um and it's still really uh uh it's a the sound is still 1216 00:46:32,680 --> 00:46:34,080 I have some improvements to make to uh 1217 00:46:34,080 --> 00:46:34,760 Ohhhh. 1218 00:46:35,920 --> 00:46:39,520 Oh. What a favorite. 1219 00:46:40,020 --> 00:46:41,360 Alright I'm going to 1220 00:46:42,580 --> 00:46:43,880 Do the same. 1221 00:46:45,400 --> 00:46:46,380 This will work. 1222 00:46:46,600 --> 00:46:46,720 Ah! 1223 00:46:48,960 --> 00:46:49,520 Hoh! 1224 00:46:52,580 --> 00:46:53,900 Is it up again? 1225 00:46:56,960 --> 00:46:57,520 Yeah. 1226 00:46:58,340 --> 00:46:58,900 Oh. 1227 00:46:59,340 --> 00:46:59,900 Oh. 1228 00:47:07,580 --> 00:47:19,440 This is very effective. Oh, shit. Demo, demo, demo. Um, I will spend, uh, one minute, one 1229 00:47:19,440 --> 00:47:29,880 minute more to see if I can get it, I can get it working. But, uh, anyway. Okay. So, 1230 00:47:29,900 --> 00:47:58,140 too much, too much devices. Ah, maybe. Good. Yeah. Uh, no, it's not done. Wait a bit. So, here it is. 1231 00:47:59,900 --> 00:48:13,920 So, third sound is the following. Oh. Well, I forgot, I forgot about it. Uh, there are many 1232 00:48:13,920 --> 00:48:29,620 sounds that can be played, uh, this way. Uh, sad. It's, uh, was a sound of burp. Anyway. So, 1233 00:48:29,900 --> 00:48:34,940 uh, I designed another attack on this robot, um, uh, that performs, uh, some kind of 1234 00:48:34,940 --> 00:48:40,700 modification on the flight, data modification. So, I modified the left and the right in the 1235 00:48:40,700 --> 00:48:46,900 command just to invert all the, uh, this command. So, if you ask the robot to turn right, it 1236 00:48:46,900 --> 00:48:52,300 turns left and so on. Oh, it's pretty useless, but, uh, just to show you how it's done. 1237 00:49:00,500 --> 00:49:25,820 So, I'll set it up. So, it's set up, uh, proxy automatically. And if I take my remote 1238 00:49:25,820 --> 00:49:29,880 control here on my phone, and I, uh, set it up, uh, it's set up. Uh, it's set up. Uh, 1239 00:49:29,880 --> 00:49:35,420 ask the robot to go forward or backward. Uh, all the commands are, uh, are inverted. So, 1240 00:49:36,740 --> 00:49:43,060 if, uh, someone wants to try it and drive the robot without making it, making it fall off the 1241 00:49:43,060 --> 00:49:53,440 table, of course. Uh, well. Yeah, it works perfectly again. Oh, shit. 1242 00:49:55,240 --> 00:49:57,620 Uh, let's forget about this robot. This is crap. 1243 00:49:59,300 --> 00:50:05,500 But, in fact, yeah. But, in fact, you saw it, uh, working with the correct interception. So, 1244 00:50:05,520 --> 00:50:12,560 the demo here, pretty difficult to perform because of the number of devices. And, uh, this, um, 1245 00:50:12,800 --> 00:50:17,960 normally the frequency-hopping spectrum system is made to, uh, is designed to avoid 1246 00:50:17,960 --> 00:50:22,760 interferences. But, uh, with the Bluetooth smart protocol, this sometimes happens. Well, 1247 00:50:22,900 --> 00:50:23,960 anyway, back to the presentation. 1248 00:50:27,620 --> 00:50:34,840 So, uh, there are no limitations about it. Uh, I made a lot of tests on my test devices. Uh, 1249 00:50:35,060 --> 00:50:40,080 which are some kind of Gables, which is a tracker. Uh, Wistikey, another tracker. Uh, MasterLock 1250 00:50:41,640 --> 00:50:48,280 4400D, which is, uh, uh, this kind of, uh, smart lock. Uh, last one provided by MasterLock. And, 1251 00:50:48,380 --> 00:50:54,400 uh, also, uh, another padlock. Uh, I, I shouldn't, uh, give the name because it's very lame and, uh, 1252 00:50:54,400 --> 00:51:00,240 it's, uh, it's weak. But this kind of padlock has some problems, too. We are going to, to see, uh, 1253 00:51:00,400 --> 00:51:07,540 what these problems are by using the, the framework. And, uh, last year, I presented, uh, at, uh, 1254 00:51:07,580 --> 00:51:13,860 various scans, uh, my research about, uh, a specific smart lock. And, uh, I will, uh, just, uh, 1255 00:51:13,940 --> 00:51:18,780 give, uh, give some feedback about, uh, its security and what can be done with this kind of, uh, 1256 00:51:18,780 --> 00:51:24,280 of tool. So, first of all, the Gables. Uh, this is the one, uh, I used, uh, for my demonstration. My 1257 00:51:24,280 --> 00:51:30,220 first demonstration using some kind of, uh, of red. And, uh, this, uh, this, uh, this tracker, uh, 1258 00:51:30,500 --> 00:51:36,520 has absolutely no bonding. So, you can, uh, uh, create a perfect dummy, uh, with the exact same 1259 00:51:36,520 --> 00:51:42,440 MAC address and so on. And, uh, it works perfectly, uh, with, uh, with a proxy. There is 1260 00:51:42,440 --> 00:51:48,400 absolutely no authentication. So, it's very easy to spoof or to, uh, to create, uh, an exact 1261 00:51:48,400 --> 00:51:54,260 same, uh, Gables. Uh, just to give more information about the Gables. Uh, the Gables is, uh, 1262 00:51:54,280 --> 00:52:01,920 uh, this is, um, a tracker. So, uh, your phone is normally connected, uh, 24 by 7 on it. So, 1263 00:52:02,020 --> 00:52:08,980 um, you should need to disconnect the Gables, uh, before performing the mandibular attack. So, 1264 00:52:09,040 --> 00:52:16,020 this is, uh, not a really critical threat for this, uh, uh, this, uh, tracker. But, uh, anyone 1265 00:52:16,020 --> 00:52:22,800 may make this Gables, uh, bips, uh, because it's, uh, uh, you only need to write, uh, a specific 1266 00:52:22,800 --> 00:52:24,260 value in, uh, in the, uh, in the, uh, in the, uh, uh, in the, uh, in the, uh, in the, uh, in the, uh, 1267 00:52:24,280 --> 00:52:30,620 in the characteristics. But I found a denial-of-service attack on it. So it was a denial-of-service 1268 00:52:30,620 --> 00:52:37,200 vulnerability that can be used to, uh, render the Gables down. Uh, and I found it by, uh, 1269 00:52:37,260 --> 00:52:42,460 testing this tool, uh, especially by testing the replay feature. So, this is something that can 1270 00:52:42,460 --> 00:52:52,440 be done. Uh, yes, um, maybe I'm, uh, I will try to demo the Gableys lite and the denial-of-service. 1271 00:52:52,660 --> 00:52:54,260 If not, still do not give me the touch for that. Alright. So, by default the Gables Loyalty features 1272 00:52:54,280 --> 00:53:24,000 demagogues. Since I'm very lucky for this uh, for this talk. Oh yeah. 1273 00:53:24,280 --> 00:53:36,540 Let's go. So uh, I um, created a uh, fake gablis uh, on my uh, computer. I'm going to 1274 00:53:36,540 --> 00:53:43,480 connect it with the correct application. Uh, on this and if everything works fine you will see 1275 00:53:43,480 --> 00:53:54,160 what happens on, on this screen. But uh, sometime a bit messy but uh. So here it is. So 1276 00:53:54,280 --> 00:54:11,640 uh, to add it to my smartphone. Sound like it was already added. It's uh, my smartphone connected 1277 00:54:11,640 --> 00:54:16,540 to, or maybe someone connected to this gablis too. I don't know if there are some uh, some of 1278 00:54:16,540 --> 00:54:24,260 you have this application. Let's start. Uh, where is it? Uh, I don't know. I don't know. 1279 00:54:33,280 --> 00:54:39,920 Well definitely the demos are completely uh, very difficult to perform here in, in live. So 1280 00:54:40,580 --> 00:54:48,040 let's continue with uh, the rest. Uh, so gablis line is the bonding. There is uh, the 1281 00:54:48,040 --> 00:54:54,120 whiskey key. Uh, this one is bonding used so uh, it can provide strong authentication. And it 1282 00:54:54,120 --> 00:54:59,080 is a tag is declared uh, last when connection is lost. So it's uh, pretty cool. Uh, other 1283 00:54:59,080 --> 00:55:05,700 devices. Uh, the master lock 4,400. Uh, I made a lot of test with it. Uh, but I wasn't about to 1284 00:55:06,360 --> 00:55:11,880 forward the uh, read and write operations to it. Uh, there is pretty no vulnerability, no 1285 00:55:11,880 --> 00:55:20,180 vulnerability, maybe no vulnerability in it. So can be uh, uh. We'll find out. Yeah. But uh, 1286 00:55:20,340 --> 00:55:24,100 maybe for another talk. Uh, let's see. Uh, uh, yeah. Oh, I'm sorry. Uh, I'm sorry. Uh, uh, uh, 1287 00:55:25,400 --> 00:55:29,500 short amount of time so it's a, you have to be very quick to 1288 00:55:29,500 --> 00:55:34,680 interact with this padlock, smart padlock to perform all of 1289 00:55:34,680 --> 00:55:41,800 these attacks. And also I found another padlock, I won't give 1290 00:55:41,800 --> 00:55:48,440 the name, this is this one, that can be used to, let's start 1291 00:55:48,440 --> 00:55:53,600 again, if you set up a manual attack you will find that the 1292 00:55:53,600 --> 00:55:58,420 pin code used by the application is stored and exchanged in 1293 00:55:58,420 --> 00:56:02,240 ClioTech so it's no big deal to get the pin code and through 1294 00:56:03,020 --> 00:56:05,740 Bluetooth MAC address duplicating it's very easy to 1295 00:56:05,740 --> 00:56:10,700 create a fake, a fake lock and get it working. I will show you 1296 00:56:10,700 --> 00:56:17,800 with the, I need to pray the demo goes again because still then 1297 00:56:17,800 --> 00:56:23,580 only one demo works. But if I remember to create a pin code 1298 00:56:23,600 --> 00:56:43,100 effect device, this will be possible. So, uh, here my 1299 00:56:43,100 --> 00:56:53,360 smartphone again. So, uh, I'm going to show you how to use 1300 00:56:55,900 --> 00:56:59,820 it. So, this device, uh, shows up when you push a button so you 1301 00:56:59,820 --> 00:57:03,120 have to, to, to push a, uh, the, uh, I have to push a push the 1302 00:57:03,120 --> 00:57:10,680 button on the, the padlock to make it appear. So here it is. 1303 00:57:15,500 --> 00:57:18,880 I'm going to create a perfect clone, uh, not so perfect because 1304 00:57:18,880 --> 00:57:23,580 the MAC address, uh, is not, uh, faked. That was proofed. But, uh, 1305 00:57:23,600 --> 00:57:29,240 here it is. I, uh, I'm launching. I am launching the 1306 00:57:29,240 --> 00:57:32,060 normal application. So this lock, uh, has already been 1307 00:57:32,060 --> 00:57:35,560 registered in my application so, uh, my application discovered 1308 00:57:35,560 --> 00:57:41,180 the, the available devices connects to this smart lock, uh, 1309 00:57:41,440 --> 00:57:46,620 since we created the perfect, uh, quite perfect dummy and I can 1310 00:57:46,620 --> 00:57:52,560 ask the application to unlock the lock. And here it is. If you 1311 00:57:52,560 --> 00:57:58,040 you look at the web interface I intercepted everything exchanged between my smart 1312 00:57:58,040 --> 00:58:05,020 appli- my uh smartphone and the lock. And the default password on this lock is 1, 2, 3, 4, 5, 1313 00:58:05,060 --> 00:58:13,160 6, 7, 8. Uh which is very very complex. But uh in fact if you uh if you look at the uh data 1314 00:58:13,160 --> 00:58:21,400 captured here you can see this one uh so the exit format uh um is not very perfect to see it 1315 00:58:21,400 --> 00:58:44,840 here. But uh it's uh 12 and character 4 v x. If you put it in x this gives you the pin code. 1316 00:58:45,020 --> 00:58:51,380 So basically what an attacker can do with this is set up uh a manual attack. So basically 1317 00:58:51,400 --> 00:58:58,520 uh wait for the owner of the lock to unlock this uh his lock. But obviously the smartphone 1318 00:58:58,520 --> 00:59:07,060 will connect to the uh spoofed uh uh here our fake lock our dummy uh device. We intercept the pin 1319 00:59:07,060 --> 00:59:12,700 code by using this uh this attack. And uh the the beauty of this attack and of this device is 1320 00:59:12,700 --> 00:59:19,320 that you don't need you need sorry the pin code this pin code to be able to add this lock to 1321 00:59:19,320 --> 00:59:21,380 your uh to your application. So uh the uh the uh the uh the uh the uh the uh the uh the uh the uh 1322 00:59:21,380 --> 00:59:25,880 Because there is no bundling and no strong authentication. There was no information 1323 00:59:25,880 --> 00:59:32,000 put by the mobile application into the lock to say that this lock belongs to this user on to 1324 00:59:32,000 --> 00:59:38,200 this phone. And this is quite interesting to see. So uh once you have the pin code you can 1325 00:59:38,200 --> 00:59:45,480 interact live lock and unlock it without any problem. So this is uh not so not so cool in 1326 00:59:45,480 --> 00:59:51,280 terms of security but uh it shows that many of these locks are very poorly designed. And this 1327 00:59:51,280 --> 00:59:51,360 case that we've found is kind of через Zone authors had a private crypto So it's just an uh it's 1328 00:59:51,380 --> 01:00:04,320 can be uh revealed by uh uh Monday Media Attack and Beetlejuice in particular. So for this 1329 01:00:04,320 --> 01:00:08,440 padlock everything uh was sent in plain text. Authentication is based on the bluetooth 1330 01:00:08,440 --> 01:00:16,220 address of the device address uh I showed uh that it was possible to fake this uh this 1331 01:00:16,220 --> 01:00:21,580 bluetooth address so this is not a big deal to get a perfect clone of this uh padlock and it 1332 01:00:21,580 --> 01:00:29,220 stays active uh once a client is connected and it stays in uh active enabled a very long time. 1333 01:00:29,400 --> 01:00:36,300 Uh once you get connected to this padlock it can take uh uh four, five, six minutes for the 1334 01:00:36,300 --> 01:00:42,440 padlock to shut down the bluetooth interface. So uh bluetooth service. So this is a very very 1335 01:00:43,140 --> 01:00:46,120 very easy to create uh to perform a manual 1336 01:00:46,120 --> 01:00:52,560 attack. Uh if you compare this padlock to the master lock uh which stays active only for 1337 01:00:53,300 --> 01:01:02,620 say 10 or 12 seconds max this is very this is easier to to assess. So the master lock is 1338 01:01:02,620 --> 01:01:08,040 pretty good with a strong authentication but the padlock is not. Uh we can do interception 1339 01:01:08,040 --> 01:01:12,760 at uh interception and replay attacks on this padlock with absolutely no problem like on the 1340 01:01:12,760 --> 01:01:16,100 goblets. And the smart lock uh I I'm not sure I'm not sure I'm not sure I'm not sure I'm not 1341 01:01:16,100 --> 01:01:23,840 allowed to really to to give the name of the bundle but uh this smart lock is was planed to be 1342 01:01:23,840 --> 01:01:29,820 widespread in Europe and in France in particular. Uh and all the data was uh transmitted uh 1343 01:01:29,820 --> 01:01:37,680 most some of them are unencrypted. Especially the log the logs uh of uh the smart lock stored 1344 01:01:37,680 --> 01:01:42,680 in smart lock. And authentication was based uh sometimes on the advertisement data we can 1345 01:01:42,680 --> 01:01:43,640 End Contacts wake up mid 4 by Framework or check with 5. If you want the experience often you can 1346 01:01:43,640 --> 01:01:46,080 fake er or you can fake a lock without er adding sort of a date sort of a number uh thought help theي 1347 01:01:46,100 --> 01:01:52,260 having to spoof the Bluetooth device address. I mean the mobile application finds the lock 1348 01:01:52,260 --> 01:01:59,420 by looking at the data advertised on the Bluetooth smart protocol. So it's very easy to create 1349 01:01:59,420 --> 01:02:05,540 a clone of it without cloning the Bluetooth address. And also no bonding was required so 1350 01:02:05,540 --> 01:02:12,260 you can just create it and spoof the device without absolutely no problem. The fun, the fun 1351 01:02:12,260 --> 01:02:22,060 part of it is that the unlock and lock operations were based on the AES 128 bit military grade 1352 01:02:22,060 --> 01:02:30,920 encryption. Well in fact I found that there were some problems with four more bytes they used to 1353 01:02:30,920 --> 01:02:38,060 exhaust something and implementations is very important. Implementation of an encryption 1354 01:02:38,060 --> 01:02:42,180 algorithm is very important. So I found many flaws in it. 1355 01:02:42,260 --> 01:02:51,980 With this cryptographic approach. So basically uh this smart lock uh was authenticated only on 1356 01:02:51,980 --> 01:02:58,660 the data advertised at the Bluetooth smart layer. So it was very easy to create a fake one. And of 1357 01:02:58,660 --> 01:03:04,260 course this smart lock was been able to intercept and replay attacks. So I was able to open it, 1358 01:03:04,360 --> 01:03:12,240 close it, uh steal some uh some uh authentication tokens and uh some tokens used to uh um uh 1359 01:03:12,260 --> 01:03:19,220 tool lock or unlock this uh this smart lock. Uh to sum it up uh beta juice can be seen as a 1360 01:03:19,220 --> 01:03:24,460 security tool to access uh security of various devices. So it's uh maybe useful to determine 1361 01:03:24,460 --> 01:03:31,000 device behavior through sub 64 Α data sniffing and also manipulation uh as uh I show you the 1362 01:03:31,440 --> 01:03:38,740 the webinar faces are um is uh a some features for replay attacks and uh and uh for data 1363 01:03:38,740 --> 01:03:42,240 visualisation. And uh you can do uh we probably cons nov止 Space coffee but pressure check users to 1364 01:03:42,260 --> 01:03:47,280 uh replay attacks and this tool supports bounding since uh blinus uh the blinu library 1365 01:03:47,280 --> 01:03:55,420 supports bounding. It can also be seen as an attack tool uh for bad guys uh since it can 1366 01:03:55,420 --> 01:03:59,720 bypass uh all the authentication based on Bluetooth device address and can be 1367 01:03:59,720 --> 01:04:04,740 instrumented to automate attacks. Yes I provide bindings for further usages uh for the uh 1368 01:04:04,740 --> 01:04:11,760 for the tools if uh your guys want to um base an attack or create a new uh uh an exploit 1369 01:04:11,760 --> 01:04:17,220 based on Beetlejuice this is possible through the bindings and uh it doesn't require uh 1370 01:04:17,220 --> 01:04:22,580 specific hardware but at least two machines or a virtual machine to to create to have this 1371 01:04:22,580 --> 01:04:27,680 working. Uh there is also no limitations due to noble and blinu uh implementations and 1372 01:04:27,680 --> 01:04:35,100 limitations so uh this uh some of these limitations have been uh solved by the Gattaca 1373 01:04:35,100 --> 01:04:41,740 tool and uh by the it's author it's author and uh uh he found some tricks to uh uh to 1374 01:04:41,760 --> 01:04:50,020 to um cope with uh the problems I had uh with the these libraries in particular. So 1375 01:04:50,020 --> 01:04:56,320 future work improve Beetlejuice proxy reliability uh and maybe uh see with the author of uh 1376 01:04:56,320 --> 01:05:03,240 Gattaca if we can do something. Take the best of our tools. Yeah and take the best of the of 1377 01:05:03,240 --> 01:05:11,640 these two tools maybe uh because uh the decision is not uh up to me but uh yeah we'll see. And 1378 01:05:11,760 --> 01:05:17,860 also improve user interface and binding because they are very very uh basics uh at the 1379 01:05:17,860 --> 01:05:23,680 moment. Uh I did not uh took time to take time to implement the um all the features I 1380 01:05:23,680 --> 01:05:30,520 wanted to implement on it. So um I had I have more work to do with the interface and uh I 1381 01:05:30,520 --> 01:05:41,740 will uh implement all the features uh very soon just to provide a uh you with a uh a good tool. And of course, uh we need motives like a 1382 01:05:41,760 --> 01:05:47,180 testing. More and more testing because uh uh it took us 6 months to develop this tool and uh 1383 01:05:47,530 --> 01:05:56,240 we tested uh at we tested it at digital security but uh we only we were only 3 persons uh using 1384 01:05:56,240 --> 01:06:00,440 this tool and we need more and more testers. So if you're interested in this tool uh with uh 1385 01:06:00,440 --> 01:06:05,940 in this uh in its approach and uh what can be performed as uh what attacks can be performed 1386 01:06:05,940 --> 01:06:18,640 with it uh feel free to test it and uh to get it. So uh. If you're looking for the code on 1387 01:06:18,640 --> 01:06:31,020 Gator. It's uh the main code is located uh here so the Gator.com digital security with the 1388 01:06:31,020 --> 01:06:35,920 capital D capital S and Beetlejuice. Uh uh uh uh uh uh uh uh uh uh uh uh uh uh uh uh uh uh uh uh 1389 01:06:35,940 --> 01:06:41,940 yeah there's a an introduction on how to set up, how to set it up or install it. You can use 1390 01:06:41,940 --> 01:06:48,460 the uh basically this uh repository uh until I publish it on uh NPM uh if the name is displayed 1391 01:06:48,460 --> 01:06:55,700 uh is available of course. But anyway uh this is uh the code is here, the bindings also with 1392 01:06:55,700 --> 01:07:05,920 uh I will publish all of this uh with the pre-found bindings uh that. I'll show you in 1393 01:07:10,780 --> 01:07:14,900 all the bindings with a lot of uh example code uh how to use it 1394 01:07:14,900 --> 01:07:19,500 how to connect to it uh how to set up an attack and so on. So 1395 01:07:19,500 --> 01:07:25,260 feel free to try it. Is there any questions about uh this 1396 01:07:25,260 --> 01:07:28,980 tool? Yeah? Uh so I'm sorry if you already used it but how do 1397 01:07:28,980 --> 01:07:35,720 you uh do the uh uh by using a CSR combat uh CSR uh VT adapter 1398 01:07:35,940 --> 01:07:40,540 uh this is a uh Cambridge Silicon Radio adapter uh which 1399 01:07:40,540 --> 01:07:45,220 uh prove um which uh implements a vendor command that can be used 1400 01:07:45,220 --> 01:07:51,820 to specify the MAC address. Uh it was previously done by uh by 1401 01:07:51,820 --> 01:07:56,980 some people. So uh there is a tool called BD adder BD ADDR uh 1402 01:07:57,380 --> 01:08:02,760 yeah uh that can be used to uh spoof the uh Bluetooth device 1403 01:08:02,760 --> 01:08:05,720 address with it. Hmm? 1404 01:08:06,960 --> 01:08:10,400 Yeah it's a part of Blues. If you uh install the Blue library 1405 01:08:10,400 --> 01:08:14,400 it uh it's provided by uh by this uh this is the very way. Uh 1406 01:08:18,220 --> 01:08:23,440 currently I uh run it on uh Ubuntu but uh I get it working on Debian and 1407 01:08:23,440 --> 01:08:30,280 I should work on uh most of the recent distribution that use uh Blues 1408 01:08:30,280 --> 01:08:35,920 Head. Blues library version 5 and more and uh Linux kernel version 4.2. So 1409 01:08:35,940 --> 01:08:43,020 at least. So, it's very common. I guess if you use some Kali Linux there shouldn't be any 1410 01:08:43,020 --> 01:08:52,840 problem with it. Some requirements is BlueHydra for instance. So, it's the only problem you can 1411 01:08:52,840 --> 01:09:00,400 have with the setup is the setup of the Noble and Blino libraries which on some machines are 1412 01:09:00,400 --> 01:09:12,920 very difficult to install. Depends on the node setup and the NPM tool. Other questions? No? 1413 01:09:13,480 --> 01:09:14,400 Thank you for listening.