1 00:00:07,160 --> 00:00:11,640 GSM hacking, access point stuff, but today he's going to talk about smart cards. 2 00:00:11,840 --> 00:00:14,160 So I'm going to hand the mic over to him. Take it away. 3 00:00:24,320 --> 00:00:25,500 Thanks a lot, Carlos. 4 00:00:32,260 --> 00:00:36,000 I'm not sure how this is going to work because this cable barely reaches over to this laptop, 5 00:00:36,140 --> 00:00:40,880 and I have to switch between all these, so if there's like big pauses where things just 6 00:00:40,880 --> 00:00:42,840 fall apart randomly, please forgive me. 7 00:00:43,820 --> 00:00:48,120 My name is David Holton, and I'm giving a talk on smart cards today. 8 00:00:48,800 --> 00:00:53,780 I'm a researcher with Doc Bowden Labs, just a small little group in San Diego, and I'm 9 00:00:53,780 --> 00:00:56,900 the chairman of TourCon, in case any of you have been there or heard of it. 10 00:00:57,320 --> 00:00:57,720 Hello. 11 00:00:58,080 --> 00:00:58,480 Hello. 12 00:01:00,000 --> 00:01:04,760 Just as a disclaimer before we get started, this is educational purposes only, all that 13 00:01:04,760 --> 00:01:12,260 crap, curiosity, not fraud, all those ideals, and full disclosure, all the information here 14 00:01:12,260 --> 00:01:18,220 I'm planning on releasing in a frack article, like in the next frack, because I've got most 15 00:01:18,220 --> 00:01:18,640 of it done. 16 00:01:18,780 --> 00:01:22,760 If anybody wants a copy of it, just let me know, and I'll give it to you later on or 17 00:01:22,760 --> 00:01:29,980 something like that, but yeah, all this information will be posted later, and this talk will be 18 00:01:29,980 --> 00:01:36,060 covered, give you a basic introduction to smart cards, basic technical knowledge of 19 00:01:36,060 --> 00:01:41,880 how smart cards work, how to analyze proprietary cards, reverse engineer the protocols that 20 00:01:41,880 --> 00:01:46,580 they use for both asynchronous and synchronous cards, and we're going to give an example 21 00:01:46,580 --> 00:01:52,280 with GSM SIM cards and parking meter cards, and finally show you methods on how to break 22 00:01:52,280 --> 00:01:54,960 it or, you know, do naughty stuff. 23 00:01:56,860 --> 00:01:58,520 So, what do we know about smart cards? 24 00:01:58,840 --> 00:01:59,960 There's a thing called the iCard. 25 00:01:59,960 --> 00:02:05,060 It's an ISO 7816 standard that defines what a smart card is, and it's a very loose standard. 26 00:02:05,240 --> 00:02:12,000 It basically just has durability requirements, pin layouts, and defines a little bit of the 27 00:02:12,000 --> 00:02:12,840 asynchronous protocols. 28 00:02:13,920 --> 00:02:19,740 For the durability requirements, it's really basic crap, like UV light protection and electrical 29 00:02:19,740 --> 00:02:24,820 resistance and magnetic field resistance and stuff like that, and really boring stuff. 30 00:02:25,060 --> 00:02:28,560 The pin layout, though, tells you exactly where all the pins should be. 31 00:02:28,560 --> 00:02:32,620 And so, it just makes it so, you know, like all the smart cards have the right pin outs 32 00:02:32,620 --> 00:02:34,600 and all the readers have the right pin outs and stuff like that. 33 00:02:36,600 --> 00:02:41,520 And we're mainly going to be focusing on the reset pin, the clock, and the I.O., and 34 00:02:41,520 --> 00:02:43,340 those are the main ones that you want to know about. 35 00:02:44,260 --> 00:02:47,860 VCC is where all of your power comes into the card, and then there's, you know, the 36 00:02:47,860 --> 00:02:51,960 ground for zero voltage, and there's a couple of reserved pins that they don't really define. 37 00:02:55,480 --> 00:02:57,380 So, for asynchronous cards... 38 00:02:59,160 --> 00:03:04,400 What, how they work is there's a couple of different protocols that they use, but mainly 39 00:03:04,400 --> 00:03:09,140 it's just, it acts as a serial device, and so you create a 9600 baud connection to the 40 00:03:09,140 --> 00:03:11,360 device, and then you can do challenge response sort of stuff. 41 00:03:11,800 --> 00:03:14,400 And it's very common with processor cards. 42 00:03:14,760 --> 00:03:18,800 With synchronous cards, they're mainly used for memory cards, and so it's really simple 43 00:03:18,800 --> 00:03:19,180 logic. 44 00:03:19,440 --> 00:03:23,740 The cards don't even have, like, their own internal clock, and so it's all supplied by 45 00:03:23,740 --> 00:03:24,020 the reader. 46 00:03:26,960 --> 00:03:28,540 So, first I'm going to talk about the process. 47 00:03:28,540 --> 00:03:29,400 I'm going to talk about asynchronous cards. 48 00:03:30,320 --> 00:03:36,980 Asynchronous cards are usually any type of processor card, so GSM SIM cards, bank cards, 49 00:03:37,520 --> 00:03:44,180 PKI token cards, Java cards, ones that are a little bit more complex and actually have 50 00:03:44,180 --> 00:03:45,280 challenge response to them. 51 00:03:46,220 --> 00:03:53,400 And synchronous protocol, yeah, just use I.O. pin to create a 9600 baud connection, and 52 00:03:53,400 --> 00:03:57,940 when the reset is set to high, it tells it to reset the card, and then you can just send 53 00:03:57,940 --> 00:03:58,460 simple commands. 54 00:04:00,260 --> 00:04:05,980 With APDU commands, you just have four bytes for your command on there, and one byte for 55 00:04:05,980 --> 00:04:09,200 the length, and then you can throw in arguments to whatever command you're sending to it. 56 00:04:09,700 --> 00:04:11,840 And then you receive a standard response back. 57 00:04:16,240 --> 00:04:23,760 So, how SIM cards work in phones is, we're mainly going to be looking at the KI on the 58 00:04:23,760 --> 00:04:28,440 cards, like the ESN, basically the key on your SIM card that identifies you on the 59 00:04:28,440 --> 00:04:28,540 network. 60 00:04:29,820 --> 00:04:34,740 And how this whole thing works is, let's say you want your phone to connect up to a GSM 61 00:04:34,740 --> 00:04:35,200 base station. 62 00:04:36,700 --> 00:04:39,060 You say, hey, base station, can I connect to you? 63 00:04:39,680 --> 00:04:40,940 This is my identifier. 64 00:04:41,280 --> 00:04:46,800 And then the base station's like, oh, well, here's a challenge. 65 00:04:46,980 --> 00:04:49,960 If you are actually who you say you are, you can provide me with the right response. 66 00:04:50,420 --> 00:04:55,420 And so what it does is it relays this challenge onto comp 128 on the SIM card, and whatever 67 00:04:55,420 --> 00:04:57,840 response it gets, it sends back to the base station, basically. 68 00:04:58,440 --> 00:05:05,460 And actually, comp 128 is also used for seeding, like, all the data encryption, the voice 69 00:05:05,460 --> 00:05:07,460 communication encryption, stuff like that. 70 00:05:07,600 --> 00:05:12,820 So they really try really hard to protect KI and make sure people can't get that. 71 00:05:15,320 --> 00:05:17,000 Different attacks on comp 128. 72 00:05:18,240 --> 00:05:23,640 There's a narrow pipe collision attack that Ian Goldberg, David Wagner, and Mark Borsano 73 00:05:23,640 --> 00:05:24,080 found out. 74 00:05:24,360 --> 00:05:28,360 And there's also a side channel attack that uses DPA to try and... 75 00:05:28,440 --> 00:05:28,940 Find KI. 76 00:05:29,840 --> 00:05:33,840 And if you can actually get the KI on the SIM card, what does it get you? 77 00:05:33,900 --> 00:05:38,900 You can clone phones, eavesdrop on calls, defund stuff like that. 78 00:05:39,400 --> 00:05:43,520 And the only downside is it attacks the SIM card, so you actually have to have the person's 79 00:05:43,520 --> 00:05:45,640 physical SIM card to perform this attack. 80 00:05:46,160 --> 00:05:48,400 And there's a possibility of killing the card. 81 00:05:49,400 --> 00:05:51,320 So there's some risks involved. 82 00:05:53,040 --> 00:05:56,300 In this presentation, I'm going to be doing a bunch of demonstrations and showing you 83 00:05:56,300 --> 00:05:58,300 how to use tools to interface with the cards. 84 00:05:58,440 --> 00:06:04,900 So in this demonstration, I'm using a Taui Toko chip drive, micro 130. 85 00:06:05,180 --> 00:06:08,620 It's just a USB smart card reader. 86 00:06:08,820 --> 00:06:10,480 You can buy them for about, like, 50 bucks online. 87 00:06:11,340 --> 00:06:16,180 And I just like it because there's really good software for it, and it works for virtually 88 00:06:16,180 --> 00:06:18,080 all the types of memory cards and stuff. 89 00:06:20,320 --> 00:06:26,240 And how you can interface with SIM cards is you just use standard APDU interfaces. 90 00:06:26,960 --> 00:06:27,620 There are... 91 00:06:29,260 --> 00:06:33,740 With the libraries that they provide, you can easily write software to interface with 92 00:06:33,740 --> 00:06:34,400 it really well. 93 00:06:35,320 --> 00:06:39,000 I just wrote a really simple command line app that, you know, is really easy to interface 94 00:06:39,000 --> 00:06:39,400 with it. 95 00:06:39,520 --> 00:06:41,340 And I'm going to be demonstrating that in a couple of minutes. 96 00:06:42,460 --> 00:06:43,760 You can also use a dumb mouse. 97 00:06:44,180 --> 00:06:44,660 It's really... 98 00:06:44,660 --> 00:06:45,900 Lots of people use this. 99 00:06:46,440 --> 00:06:51,480 All it does is it just ties your serial port over to the card, and so you can just create 100 00:06:51,480 --> 00:06:53,620 a serial connection and talk to it directly that way. 101 00:06:54,920 --> 00:06:58,420 And there's really good software for it that you can grab from FTL.com. 102 00:06:58,420 --> 00:07:00,940 It's http.ccc.de.gsm. 103 00:07:01,680 --> 00:07:05,040 And not too many people know about it, but there's lots of really good resources in there. 104 00:07:06,580 --> 00:07:10,900 And also, you could use a season, which is basically the same thing as a dumb mouse. 105 00:07:11,120 --> 00:07:12,660 And you can use it for tapping as well. 106 00:07:13,340 --> 00:07:16,660 And you can get schematics on that from FRAC 62.15. 107 00:07:20,020 --> 00:07:23,860 So, in this demonstration, I'm just going to connect to the card by inserting the card. 108 00:07:24,420 --> 00:07:27,380 And then I'm going to select the GSM directory on the card. 109 00:07:27,920 --> 00:07:28,400 I'll think about it later. 110 00:07:28,420 --> 00:07:31,060 And then I'm going to authenticate with the PIN and run Comp 128. 111 00:07:32,900 --> 00:07:33,460 So... 112 00:07:34,120 --> 00:07:34,660 Just a minute. 113 00:07:58,480 --> 00:07:59,620 Ah, it partially works. 114 00:08:14,200 --> 00:08:18,840 You can get a holder for your SIM card that allows you to put it in a smart card reader. 115 00:08:19,260 --> 00:08:22,060 And you can buy these for like two bucks online or something like that. 116 00:08:23,620 --> 00:08:24,540 Does Bodo have them? 117 00:08:25,820 --> 00:08:27,060 Oh, Bodo sells readers. 118 00:08:27,060 --> 00:08:30,720 Actually, for people that have really good questions at the end, Bodo gave me some smart 119 00:08:30,720 --> 00:08:31,900 card readers that I'm going to give away. 120 00:08:34,320 --> 00:08:35,300 So stick around. 121 00:08:47,280 --> 00:08:49,200 Okay, so first I'm going to reset the card. 122 00:08:50,340 --> 00:08:51,380 Just typing an R. 123 00:08:52,020 --> 00:08:53,220 And hopefully this will work. 124 00:08:54,100 --> 00:08:56,680 I'm going to issue a command to select the GSM directory. 125 00:09:07,800 --> 00:09:11,560 And so then I get this response back from the card and it's supposed to mean it's okay. 126 00:09:15,220 --> 00:09:17,260 How do you know what directories are on it? 127 00:09:18,920 --> 00:09:20,380 There's been a bunch of stuff published. 128 00:09:20,540 --> 00:09:25,060 Like if you read the Frack article, the guy published a bunch of the different directories 129 00:09:25,060 --> 00:09:25,580 that are on there. 130 00:09:27,960 --> 00:09:30,960 Yeah, yeah, like all the SIM cards have this one. 131 00:09:31,420 --> 00:09:34,800 And then there's different directories you can use for pulling down contact info, you 132 00:09:34,800 --> 00:09:38,740 know, contacts and SMS stuff or whatever else is stored on there. 133 00:09:39,120 --> 00:09:40,600 So yeah, read Frack 62. 134 00:09:41,220 --> 00:09:42,400 It has all the info on there. 135 00:09:46,040 --> 00:09:50,280 And so now this command tells it to pull down 19 bytes from the result. 136 00:09:50,980 --> 00:09:55,020 And so this is info from the GSM directory. 137 00:09:55,720 --> 00:09:58,620 But now that we're in there, I'm going to authenticate with the PIN. 138 00:09:59,640 --> 00:10:03,500 This is exactly what your phone does whenever you power it on and ask for the PIN. 139 00:10:08,520 --> 00:10:11,100 And this is actually Carlos' old SIM card. 140 00:10:11,340 --> 00:10:13,940 So if you look at this enough, you can find out what his PIN is. 141 00:10:14,140 --> 00:10:15,940 He probably uses it on his current cell phone, too. 142 00:10:28,700 --> 00:10:33,880 And so if you look closely on there, it says 38393839 and then a bunch of Fs. 143 00:10:34,320 --> 00:10:39,740 And that means that if you look at it in ASCII, then you'll know what his PIN is. 144 00:10:41,760 --> 00:10:46,820 So we're authenticated, and now I'm going to run Comp 128 on the card. 145 00:10:51,880 --> 00:10:52,240 00000. 146 00:10:54,060 --> 00:10:55,560 And I'm just going to feed it a bunch of zeros. 147 00:10:55,580 --> 00:10:56,380 Just for an example. 148 00:11:04,440 --> 00:11:06,380 So there's 12 bytes of response. 149 00:11:07,640 --> 00:11:08,620 I'm going to grab that. 150 00:11:17,380 --> 00:11:19,200 And there's a response from Comp 128. 151 00:11:20,000 --> 00:11:23,480 And so that's how you can use to pull Comp 128 on the card. 152 00:11:23,720 --> 00:11:25,360 So now that we have an interface, 153 00:11:25,580 --> 00:11:30,560 thanks to getting at Comp 128, I'm going to show you how Comp 128 works. 154 00:11:43,220 --> 00:11:48,820 By the way, thanks to CCC and Ender for providing lots of info about the G-SIM SIM cards. 155 00:11:50,200 --> 00:11:51,300 So there's the administration. 156 00:11:52,780 --> 00:11:55,320 And if you happen to not know the protocol, 157 00:11:55,320 --> 00:11:56,260 that the things we're using, 158 00:11:56,400 --> 00:12:01,080 you can always make your own by reading FRAC 62 or by a season, 159 00:12:01,220 --> 00:12:02,800 which you can grab from SDLogic. 160 00:12:02,960 --> 00:12:03,700 And they're actually, 161 00:12:06,260 --> 00:12:08,940 they've actually been involved in lawsuits with Prime Star and DirecTV, 162 00:12:09,240 --> 00:12:11,740 as you might have heard from the talk earlier. 163 00:12:12,120 --> 00:12:13,820 So if you buy something from there, 164 00:12:13,920 --> 00:12:16,560 then just be aware that they might try and sue you or something. 165 00:12:20,660 --> 00:12:23,120 But you can use that to log the connection and figure out the protocol. 166 00:12:23,120 --> 00:12:27,220 Now, I'm just going to cover the narrow pipe collision attack. 167 00:12:28,000 --> 00:12:29,720 How do you perform this attack? 168 00:12:30,500 --> 00:12:33,300 Ian Goldberg found that there's a narrow pipe in Comp 128, 169 00:12:34,060 --> 00:12:36,240 and he attacks the second round. 170 00:12:37,740 --> 00:12:40,720 Collisions in Comp 128 responses reveal key information. 171 00:12:41,620 --> 00:12:46,560 And you can crack Comp 128 using his method and about 115,000 queries, 172 00:12:46,700 --> 00:12:47,900 according to his article. 173 00:12:50,420 --> 00:12:53,100 Unfortunately, new SIM cards will die after some time. 174 00:12:53,100 --> 00:12:54,040 It's 65,000 queries. 175 00:12:54,720 --> 00:12:56,600 It's a new feature that they added in. 176 00:12:57,340 --> 00:13:02,880 And so most people won't be able to get to 115,000 and actually crack it. 177 00:13:03,480 --> 00:13:06,580 So I've been working on optimizations to speed this up to make it a little bit faster. 178 00:13:08,380 --> 00:13:10,100 This is what Comp 128 looks like. 179 00:13:10,240 --> 00:13:11,560 It's all like pseudocode and stuff. 180 00:13:11,760 --> 00:13:13,720 So I don't expect you to read it or understand it. 181 00:13:13,840 --> 00:13:17,980 But the cool thing is that at the very end, 182 00:13:18,080 --> 00:13:19,760 they all padded 10 bits at the end. 183 00:13:19,900 --> 00:13:22,980 And they think that it's because of the NSA just added in 184 00:13:23,100 --> 00:13:25,160 their own little feature to Comp 128. 185 00:13:26,020 --> 00:13:30,960 But it essentially reduces your voice security with your cell phone by 10 bits. 186 00:13:31,620 --> 00:13:32,500 So thanks, NSA. 187 00:13:34,380 --> 00:13:34,780 . 188 00:13:36,320 --> 00:13:37,780 Just the algorithms used in the U.S. 189 00:13:38,860 --> 00:13:42,420 Does that counter, the 65k counter, does that get reset? 190 00:13:42,680 --> 00:13:44,240 Or is that, like, the life of the card? 191 00:13:45,280 --> 00:13:46,360 It's for the life of the card. 192 00:13:47,180 --> 00:13:49,020 So, like, every time you power on your phone, 193 00:13:49,160 --> 00:13:51,020 associate with the base station and stuff like that, 194 00:13:51,020 --> 00:13:53,300 it uses, you know, text on the counter once. 195 00:13:53,660 --> 00:13:57,300 And so they assume that you aren't going to be using it 65,000 times 196 00:13:57,300 --> 00:13:59,800 and you'll upgrade in, like, a couple years or something like that. 197 00:14:03,580 --> 00:14:05,360 So, Comp 128 for dummies. 198 00:14:07,160 --> 00:14:12,180 What happens is, you know how I showed you feeding a challenge to Comp 128 199 00:14:12,700 --> 00:14:13,880 when we interface with it? 200 00:14:15,060 --> 00:14:17,700 What happens is there's this X array in the Comp 128 function 201 00:14:18,540 --> 00:14:20,800 that loads the secret key into, 202 00:14:21,020 --> 00:14:21,900 into the first 16 bytes. 203 00:14:22,640 --> 00:14:25,400 And then it takes the challenge and stuffs it in the next 16 bytes. 204 00:14:26,860 --> 00:14:28,860 And then it goes through this bit reduction routine 205 00:14:29,600 --> 00:14:30,680 I'm going to cover right now. 206 00:14:31,300 --> 00:14:33,640 So, for example, if you have a key that's all zeros 207 00:14:33,640 --> 00:14:35,440 and a challenge that's all zeros, 208 00:14:35,600 --> 00:14:37,480 what happens is, in this bit reduction, 209 00:14:38,360 --> 00:14:42,540 it ends up performing operations on, like, the zero bit, 210 00:14:42,600 --> 00:14:44,960 or zero byte and the 16th byte 211 00:14:45,960 --> 00:14:47,720 and uses both of those as inputs 212 00:14:47,720 --> 00:14:49,900 and then spits out results into those. 213 00:14:49,900 --> 00:14:52,480 And so it just performs operations on those 214 00:14:52,480 --> 00:14:55,380 and goes along until it's gone through every one, 215 00:14:55,420 --> 00:14:58,840 you know, at offset 16 for round one. 216 00:14:59,360 --> 00:15:01,640 Then in round two, it uses an offset of eight 217 00:15:01,640 --> 00:15:03,800 and does the same thing, 218 00:15:03,920 --> 00:15:05,620 only it reduces by seven bits 219 00:15:05,620 --> 00:15:07,420 and it uses lookup tables and all that kind of stuff. 220 00:15:07,700 --> 00:15:09,620 So if you want to learn more, just look into it, 221 00:15:09,680 --> 00:15:12,080 but I'm just kind of skimming through this. 222 00:15:12,720 --> 00:15:14,220 So in round two, it goes through 223 00:15:14,220 --> 00:15:18,320 and performs operations on all those. 224 00:15:18,320 --> 00:15:21,160 And it reduces them down to seven bits for each byte. 225 00:15:22,040 --> 00:15:25,260 In round three, it does the same thing with offset four. 226 00:15:25,420 --> 00:15:26,660 It reduces them down to six bits. 227 00:15:28,820 --> 00:15:31,380 Round four does it with offset two, 228 00:15:31,500 --> 00:15:32,460 reduces them to five bits. 229 00:15:33,300 --> 00:15:35,440 And then in round five, it reduces them down to four 230 00:15:36,060 --> 00:15:36,820 all the way through. 231 00:15:37,060 --> 00:15:39,160 And essentially what Comp 128 does is 232 00:15:39,160 --> 00:15:40,500 it's just like a checksum. 233 00:15:40,600 --> 00:15:42,700 It basically makes all the bytes dependent on each other. 234 00:15:42,820 --> 00:15:45,740 So if any byte changes, the result is supposed to change. 235 00:15:48,320 --> 00:15:50,340 And then it takes all those four-bit values, 236 00:15:50,520 --> 00:15:51,160 shifts them over, 237 00:15:53,780 --> 00:15:55,280 puts them at the end of x, 238 00:15:55,420 --> 00:15:59,320 and then feeds ki back into the beginning 239 00:15:59,320 --> 00:16:01,020 and then repeats it seven times, 240 00:16:01,160 --> 00:16:02,720 and so it iterates quite a lot. 241 00:16:04,480 --> 00:16:07,180 Then it reduces bytes, null pads the ten bits, 242 00:16:07,360 --> 00:16:08,440 and returns. 243 00:16:09,840 --> 00:16:12,060 So how this baseline attack works is 244 00:16:12,620 --> 00:16:14,300 if we look for different challenges, 245 00:16:14,340 --> 00:16:16,640 it ends up giving us the same response. 246 00:16:18,320 --> 00:16:20,380 And just kind of drill it down in the algorithm. 247 00:16:21,720 --> 00:16:23,380 In this example, I'm using this ki, 248 00:16:23,520 --> 00:16:26,020 which is one, two, three, four, five, six, seven, eight, nine, 249 00:16:26,100 --> 00:16:26,580 and so on. 250 00:16:27,820 --> 00:16:29,140 And if you look at a challenge 251 00:16:29,980 --> 00:16:31,680 where it's 23, a bunch of zeros, 252 00:16:31,800 --> 00:16:33,060 and then five, five, a bunch of zeros, 253 00:16:34,000 --> 00:16:35,580 and zero, d, a bunch of zeros, 254 00:16:35,660 --> 00:16:37,060 and e, seven, a bunch of zeros, 255 00:16:38,280 --> 00:16:40,580 in round one, you'll notice that 256 00:16:40,580 --> 00:16:42,480 of course there's going to be different values 257 00:16:42,480 --> 00:16:44,760 when it performs operations on the first byte. 258 00:16:46,460 --> 00:16:48,300 But all these other ones end up being the same. 259 00:16:48,320 --> 00:16:52,580 Because it's virtually the same function 260 00:16:52,580 --> 00:16:53,440 that's going on there. 261 00:16:54,000 --> 00:16:54,840 And then it goes on, 262 00:16:55,000 --> 00:16:57,600 and you'll notice that all of these are the same 263 00:16:57,600 --> 00:16:59,600 except for ones that offset zero 264 00:16:59,600 --> 00:17:00,420 and ones that offset eight. 265 00:17:01,500 --> 00:17:03,880 In the second round, look at that. 266 00:17:04,060 --> 00:17:06,120 It just happens to swap them 267 00:17:06,120 --> 00:17:07,660 with the exact same values. 268 00:17:07,800 --> 00:17:11,320 And so now we have all the same values 269 00:17:11,320 --> 00:17:12,120 in the very top row, 270 00:17:12,620 --> 00:17:14,700 and then it goes through to the bottom row 271 00:17:14,700 --> 00:17:16,560 and swaps them with the same values down there. 272 00:17:16,560 --> 00:17:18,740 And so once we get to that point, 273 00:17:18,820 --> 00:17:20,280 it'll end up having the exact same response. 274 00:17:22,580 --> 00:17:24,360 The cool thing about this property is that 275 00:17:24,360 --> 00:17:26,760 now we know that if we run comp 128 276 00:17:26,760 --> 00:17:29,060 with a challenge of 23, a bunch of zeros, 277 00:17:29,160 --> 00:17:30,640 and five, five, a bunch of zeros, 278 00:17:30,800 --> 00:17:32,240 it ends up with the same result 279 00:17:32,240 --> 00:17:34,020 as zero, d, a bunch of zeros, 280 00:17:34,120 --> 00:17:34,880 e, seven, a bunch of zeros. 281 00:17:35,020 --> 00:17:38,260 And we know that the keys in the byte 282 00:17:38,260 --> 00:17:39,940 are zero, one, and something, 283 00:17:40,080 --> 00:17:41,100 and then fe and something. 284 00:17:41,640 --> 00:17:43,760 And so we've just retrieved two bytes of the key. 285 00:17:45,200 --> 00:17:46,320 Then you can just repeat it 286 00:17:46,560 --> 00:17:48,020 eight times, and you have the whole key. 287 00:17:50,380 --> 00:17:53,060 So I was looking at trying to speed this up a little bit, 288 00:17:54,220 --> 00:17:57,620 and I tried brute-forcing all the different collisions 289 00:17:57,620 --> 00:18:00,180 and finding the collisions that happen the most often 290 00:18:00,180 --> 00:18:01,840 and then just choosing those first 291 00:18:01,840 --> 00:18:04,280 and optimizing it that way. 292 00:18:04,620 --> 00:18:06,400 And it makes it a bit faster, 293 00:18:06,520 --> 00:18:08,100 but it still isn't fast enough. 294 00:18:09,740 --> 00:18:11,060 So one thing that you can do 295 00:18:11,060 --> 00:18:12,260 is you can attack the third round, 296 00:18:12,700 --> 00:18:14,840 and because you already have some pieces of the puzzle 297 00:18:14,840 --> 00:18:15,580 for the third round, 298 00:18:16,560 --> 00:18:18,440 you can find certain collisions 299 00:18:18,440 --> 00:18:21,420 that reveal single bytes. 300 00:18:21,880 --> 00:18:24,420 And so instead of attacking two bytes at a time 301 00:18:24,420 --> 00:18:25,700 and brute-forcing 16 bits, 302 00:18:25,960 --> 00:18:28,240 you can virtually brute-force one byte at a time. 303 00:18:28,340 --> 00:18:32,760 And so it reduces the complexity a lot. 304 00:18:33,160 --> 00:18:34,660 The only problem is that you have to 305 00:18:35,580 --> 00:18:36,600 pre-compute everything, 306 00:18:36,860 --> 00:18:39,300 and it takes a lot of pre-computation. 307 00:18:40,360 --> 00:18:41,900 So you can do that with the third round 308 00:18:41,900 --> 00:18:42,940 to retrieve two bytes. 309 00:18:43,360 --> 00:18:45,540 Then in the fourth round, you can retrieve four more, 310 00:18:46,560 --> 00:18:46,980 and in the fifth round, 311 00:18:47,040 --> 00:18:48,160 you can retrieve the rest of them. 312 00:18:49,940 --> 00:18:52,340 And it's owned in less than 20,000 tries. 313 00:18:54,980 --> 00:18:57,800 So this works with most GSM carriers in the US, 314 00:18:58,020 --> 00:18:59,700 like T-Mobile, Singular, etc. 315 00:19:00,140 --> 00:19:03,520 And the new attack takes around 15 minutes 316 00:19:03,520 --> 00:19:04,920 with a pre-computed dictionary. 317 00:19:06,960 --> 00:19:09,260 So I haven't totally computed 318 00:19:09,260 --> 00:19:10,780 what the full dictionary is going to be, 319 00:19:10,900 --> 00:19:13,100 but it shouldn't be that bad. 320 00:19:14,100 --> 00:19:15,580 And once you have KI, 321 00:19:15,580 --> 00:19:17,900 you can emulate SIM card really easily with a PIC. 322 00:19:18,060 --> 00:19:19,640 There's all kinds of code out there for doing it. 323 00:19:19,780 --> 00:19:21,320 Gold wafer cards, stuff like that. 324 00:19:22,600 --> 00:19:24,920 And I'm going to release some open source tools pretty shortly. 325 00:19:25,360 --> 00:19:26,340 You can also download SIM scan, 326 00:19:26,520 --> 00:19:27,200 which implements this. 327 00:19:27,540 --> 00:19:29,460 And I think he's had it out for a little while. 328 00:19:29,600 --> 00:19:31,240 So check that out. 329 00:19:33,660 --> 00:19:36,360 Any questions so far on the GSM stuff? 330 00:19:36,760 --> 00:19:37,740 Can I have my card back? 331 00:19:39,660 --> 00:19:40,020 No. 332 00:19:45,700 --> 00:19:48,980 I think that Boost Mobile uses something totally different. 333 00:19:50,040 --> 00:19:53,260 I'm pretty sure they don't use GSM SIM cards. 334 00:19:54,080 --> 00:19:55,020 Yeah, yeah. 335 00:19:55,760 --> 00:19:57,080 So I don't think it'll work with Boost. 336 00:19:58,180 --> 00:19:59,320 Any other quick questions? 337 00:19:59,720 --> 00:20:03,500 Have you tried this on a card in a non-US GSM card? 338 00:20:03,860 --> 00:20:04,840 No, I haven't. 339 00:20:05,200 --> 00:20:08,760 They have three different types of encryption types 340 00:20:08,760 --> 00:20:09,440 you can use for it. 341 00:20:09,480 --> 00:20:11,300 There's one which is no encryption, 342 00:20:11,540 --> 00:20:12,680 which is really useful. 343 00:20:13,900 --> 00:20:15,560 There's another one that's, you know, 344 00:20:15,580 --> 00:20:17,700 like US, and then there's one they use in Europe, I think. 345 00:20:17,820 --> 00:20:18,660 There might be another one. 346 00:20:18,700 --> 00:20:19,800 I'm not sure, but... 347 00:20:21,860 --> 00:20:22,640 Anything else? 348 00:20:22,940 --> 00:20:24,980 Does this only work on GSM cards 349 00:20:24,980 --> 00:20:27,460 or does it work on all other ones, 350 00:20:27,540 --> 00:20:29,600 like SIM cards? 351 00:20:30,800 --> 00:20:31,340 Oh, no. 352 00:20:31,420 --> 00:20:32,500 It's just for GSM. 353 00:20:33,000 --> 00:20:34,360 Just GSM SIM cards. 354 00:20:35,160 --> 00:20:35,800 Anything else? 355 00:20:37,120 --> 00:20:37,880 Oh, yeah. 356 00:20:38,200 --> 00:20:39,660 Yeah, I played a round of the 357 00:20:40,620 --> 00:20:42,400 collision attacks and tested it. 358 00:20:42,520 --> 00:20:42,980 Uh-huh. 359 00:20:43,000 --> 00:20:44,640 And I found that some files didn't work 360 00:20:45,580 --> 00:20:47,500 with each other's byte pairs. 361 00:20:48,220 --> 00:20:49,600 Did you have that same result? 362 00:20:50,140 --> 00:20:51,520 Uh, yeah, yeah. 363 00:20:52,260 --> 00:20:53,260 It's actually kind of weird, 364 00:20:53,320 --> 00:20:55,260 because they end up shaving off a lot of stuff 365 00:20:55,260 --> 00:20:59,460 when they, like, when they put together 366 00:20:59,460 --> 00:21:00,460 the response at the end. 367 00:21:00,920 --> 00:21:02,460 Because it's only 12 bytes of response, 368 00:21:02,680 --> 00:21:04,540 and, you know, you're feeding a lot of input to it. 369 00:21:04,620 --> 00:21:05,940 So, I don't know. 370 00:21:05,980 --> 00:21:08,000 Yeah, I found that there's some collisions 371 00:21:08,000 --> 00:21:08,700 that end up doing that. 372 00:21:09,280 --> 00:21:12,400 And so, yeah, I... 373 00:21:12,860 --> 00:21:14,640 What I ended up doing was I just go through 374 00:21:14,640 --> 00:21:18,260 the algorithm and basically, like, 375 00:21:18,880 --> 00:21:20,940 find a right equation that makes it line up. 376 00:21:21,040 --> 00:21:22,360 And so, it's more kind of, like, 377 00:21:22,420 --> 00:21:24,060 making it line up in the second round 378 00:21:24,060 --> 00:21:25,280 than actually running it through 379 00:21:25,280 --> 00:21:26,060 and brute-forcing everything. 380 00:21:26,540 --> 00:21:27,780 And so, it's a little more accurate 381 00:21:27,780 --> 00:21:28,500 if you do it that way. 382 00:21:29,660 --> 00:21:30,220 I don't know. 383 00:21:30,260 --> 00:21:31,180 We can talk later or something. 384 00:21:32,000 --> 00:21:32,720 Anything else? 385 00:21:41,560 --> 00:21:42,580 What was that again? 386 00:21:44,080 --> 00:21:45,220 What was that? 387 00:21:45,460 --> 00:21:46,760 I said there is a fourth one. 388 00:21:47,100 --> 00:21:47,820 Oh, okay. 389 00:21:49,140 --> 00:21:49,600 . 390 00:21:53,440 --> 00:21:54,400 Ah, okay. 391 00:21:56,080 --> 00:21:58,320 Yeah, he said that there was a fourth one 392 00:21:58,320 --> 00:21:59,340 that nobody can crack, 393 00:21:59,400 --> 00:22:00,560 and so that's why nobody uses it. 394 00:22:04,300 --> 00:22:05,900 Yeah, there's some really good candidates 395 00:22:05,900 --> 00:22:08,000 for the new GSM encryption algorithms. 396 00:22:08,360 --> 00:22:08,560 So... 397 00:22:10,440 --> 00:22:11,200 Is that it? 398 00:22:11,200 --> 00:22:13,100 Yeah, we'll have more time for questions later. 399 00:22:14,120 --> 00:22:15,560 So, moving on to parking meters. 400 00:22:16,440 --> 00:22:17,780 What the fuck is a parking meter? 401 00:22:20,300 --> 00:22:21,680 Basic intro to parking meters. 402 00:22:22,040 --> 00:22:23,600 These are the types of parking meters 403 00:22:23,600 --> 00:22:24,300 we have in San Diego. 404 00:22:24,500 --> 00:22:25,680 There is a coin input, 405 00:22:25,900 --> 00:22:26,680 a coin output, 406 00:22:26,920 --> 00:22:27,700 which is very useful, 407 00:22:27,840 --> 00:22:30,160 and an input for a smart card. 408 00:22:32,900 --> 00:22:34,180 And if you look at the smart card, 409 00:22:34,420 --> 00:22:35,920 I have a couple right here. 410 00:22:36,520 --> 00:22:38,800 They're just real simple SIM cards. 411 00:22:39,200 --> 00:22:40,120 Yeah, smart cards. 412 00:22:40,120 --> 00:22:42,900 And what they say on the back is, 413 00:22:43,000 --> 00:22:43,860 parking meter debit card. 414 00:22:44,420 --> 00:22:45,840 Insert debit card into meter 415 00:22:45,840 --> 00:22:47,040 in direction shown by arrow. 416 00:22:47,380 --> 00:22:49,620 The meter will increment in six-minute segments. 417 00:22:49,920 --> 00:22:51,740 And actually, it's down to four-minute segments 418 00:22:51,740 --> 00:22:53,540 because they just raised the prices in San Diego. 419 00:22:55,080 --> 00:22:56,960 When desired time is displayed, remove card. 420 00:22:57,740 --> 00:22:59,000 Did you buy too much time? 421 00:22:59,520 --> 00:23:01,060 To obtain extra time, refund. 422 00:23:02,760 --> 00:23:03,920 Insert the same debit card 423 00:23:03,920 --> 00:23:05,700 that was used to purchase time in the meter. 424 00:23:05,960 --> 00:23:08,780 Four six-minute increments will be credited to the card. 425 00:23:08,940 --> 00:23:10,100 Increments of less than six minutes. 426 00:23:10,120 --> 00:23:10,660 Six minutes will be lost. 427 00:23:11,140 --> 00:23:13,360 And so there is a way to refund credits onto the card. 428 00:23:13,540 --> 00:23:16,340 And that's one important piece of information to know. 429 00:23:19,820 --> 00:23:22,040 These cards are synchronous smart cards, 430 00:23:22,120 --> 00:23:23,780 and they're just like memory cards, 431 00:23:23,980 --> 00:23:25,300 just like Kinko's cards, 432 00:23:25,900 --> 00:23:27,000 Internet Cafe cards, 433 00:23:27,680 --> 00:23:28,320 cash cards. 434 00:23:31,040 --> 00:23:34,180 And synchronous protocol is very, very simple. 435 00:23:34,840 --> 00:23:36,860 The clock sets the transfer speed. 436 00:23:37,020 --> 00:23:40,000 And so the reader just kind of moves the clock up and down 437 00:23:40,120 --> 00:23:41,020 from five volts to zero, 438 00:23:42,220 --> 00:23:45,800 and uses that to create the clock for the actual card. 439 00:23:48,020 --> 00:23:50,280 And if the reader wants to start reading information, 440 00:23:50,580 --> 00:23:53,100 it just sets the reset high to tell the card to reset, 441 00:23:53,500 --> 00:23:55,360 and then starts ticking the clock. 442 00:23:55,640 --> 00:23:57,800 And for each time that the clock goes high, 443 00:23:58,520 --> 00:24:00,180 the card will see that the clock's high, 444 00:24:00,220 --> 00:24:04,180 and so it'll set the data line to whatever the bit is. 445 00:24:04,300 --> 00:24:06,440 And so, like, for the first time the clock goes high, 446 00:24:07,220 --> 00:24:09,260 the card will set, you know, like, 447 00:24:09,260 --> 00:24:11,520 set the I-O line to whatever bit zero is. 448 00:24:11,700 --> 00:24:12,980 And then the second time it goes high, 449 00:24:13,060 --> 00:24:15,140 it'll set the I-O line to whatever bit one is. 450 00:24:15,740 --> 00:24:18,460 And just keep on going until the whole card is dumped. 451 00:24:21,700 --> 00:24:24,300 Parking meter cards are very similar to, like, 452 00:24:24,320 --> 00:24:27,140 European telecom cards that are actually covered in FRAC 48. 453 00:24:28,020 --> 00:24:29,580 And I have one here. 454 00:24:30,900 --> 00:24:34,080 And so you can use these in Europe to, like, 455 00:24:34,900 --> 00:24:36,760 pay for pay phones and stuff. 456 00:24:37,320 --> 00:24:38,800 And how these work is they implement 457 00:24:39,260 --> 00:24:39,540 a two-way counter. 458 00:24:41,620 --> 00:24:43,920 And basically what happens is in the factory they set 459 00:24:44,280 --> 00:24:46,140 exactly how many credits the card is supposed to have. 460 00:24:47,240 --> 00:24:49,100 So let's say the card's only supposed to have, like, 461 00:24:49,100 --> 00:24:49,880 $50 on it. 462 00:24:50,240 --> 00:24:51,680 They set that amount of bits on the card, 463 00:24:52,140 --> 00:24:53,420 and then they blow a fuse. 464 00:24:53,680 --> 00:24:56,300 And then from then on the bits can only go from one to zero. 465 00:24:56,540 --> 00:24:59,120 And so that's supposed to provide security that you don't, 466 00:24:59,120 --> 00:25:01,020 you know, put bits back onto the card somehow 467 00:25:02,080 --> 00:25:02,960 or reprogram them. 468 00:25:04,920 --> 00:25:06,740 And I'm just going to do a quick demonstration 469 00:25:06,740 --> 00:25:09,000 of reading some cards so you can kind of see what 470 00:25:09,480 --> 00:25:10,640 it looks like on them. 471 00:25:31,020 --> 00:25:32,500 There's this really nice tool that comes with 472 00:25:33,360 --> 00:25:35,300 Taui Toko Reader for reading stuff. 473 00:25:36,940 --> 00:25:39,200 It's kind of hard to find now because I think they took it off the website. 474 00:25:39,260 --> 00:25:41,460 But you can find it on the German site. 475 00:25:44,360 --> 00:25:45,180 No, no. 476 00:25:47,100 --> 00:25:49,340 Okay, so this is a European telecom card. 477 00:25:50,800 --> 00:25:52,480 And they actually use – 478 00:25:55,280 --> 00:25:57,720 they're actually able to round the bit deductions 479 00:25:57,720 --> 00:25:58,460 or something like that. 480 00:25:58,560 --> 00:26:00,040 So there's a lot less stuff on here. 481 00:26:00,860 --> 00:26:02,160 But that's all the data on there. 482 00:26:03,720 --> 00:26:06,600 If you look at parking meter card – 483 00:26:14,620 --> 00:26:16,680 you get a lot more info on here. 484 00:26:18,840 --> 00:26:22,520 And so there's all these kind of like empty spaces 485 00:26:22,520 --> 00:26:24,340 and full spaces of bits and stuff. 486 00:26:24,780 --> 00:26:26,320 So I'll be covering that a little bit later. 487 00:26:26,680 --> 00:26:29,620 But you can just drop in any memory card that you have. 488 00:26:29,760 --> 00:26:32,200 Like this is a Kinko Express Pay card. 489 00:26:32,540 --> 00:26:33,560 I haven't looked at these too much. 490 00:26:33,700 --> 00:26:35,600 So if anybody looks into these much, 491 00:26:36,280 --> 00:26:37,100 it's kind of interesting. 492 00:26:37,200 --> 00:26:37,640 There's like – 493 00:26:37,640 --> 00:26:39,460 it says cash customer down here. 494 00:26:40,220 --> 00:26:43,700 And I don't know, different things. 495 00:26:45,060 --> 00:26:46,880 And these types of cards actually use a pin 496 00:26:46,880 --> 00:26:48,220 for rewriting to them. 497 00:26:48,580 --> 00:26:49,760 And so if you can figure out the pin, 498 00:26:49,860 --> 00:26:51,660 then you can rewrite stuff on the cards 499 00:26:51,660 --> 00:26:53,240 or you can just get your own or whatever, 500 00:26:53,600 --> 00:26:54,300 emulate your own. 501 00:26:55,940 --> 00:26:57,800 But if you guys have any interesting cards, 502 00:26:57,920 --> 00:26:59,040 let me know later on 503 00:26:59,040 --> 00:27:00,200 because I always like to look at new stuff. 504 00:27:13,300 --> 00:27:15,600 Okay, so from a parking meter card memory dump, 505 00:27:16,540 --> 00:27:17,680 we get something like this. 506 00:27:19,020 --> 00:27:20,940 Through trial and error, I kind of figured out 507 00:27:21,420 --> 00:27:22,720 on most memory cards, 508 00:27:22,800 --> 00:27:25,200 the first four bytes is an ATR, answer to reset. 509 00:27:25,880 --> 00:27:27,720 And it's just kind of like a serial number. 510 00:27:28,320 --> 00:27:29,820 And then there's another four bytes 511 00:27:29,820 --> 00:27:31,100 of another type of serial number. 512 00:27:31,900 --> 00:27:33,460 And what I found out is that 513 00:27:33,460 --> 00:27:35,340 if you look at the green portion over there, 514 00:27:35,420 --> 00:27:37,620 that's actually the area 515 00:27:37,640 --> 00:27:38,280 for credit bits. 516 00:27:38,660 --> 00:27:40,480 And so for every bit that's set in there, 517 00:27:40,600 --> 00:27:42,280 it means 10 cents on the card. 518 00:27:42,940 --> 00:27:44,560 And if you look at the blue portion, 519 00:27:44,800 --> 00:27:46,320 that's the refund bits area. 520 00:27:46,700 --> 00:27:49,800 Because they can only go from one bits to zero bits, 521 00:27:50,700 --> 00:27:52,560 they decided to have a separate section 522 00:27:52,560 --> 00:27:53,540 just for refunds. 523 00:27:54,520 --> 00:27:56,960 So for every bit that's set to zero in that area, 524 00:27:57,080 --> 00:27:58,160 you get a refund on the card. 525 00:27:59,400 --> 00:28:02,800 And how it works is like, 526 00:28:02,940 --> 00:28:04,740 let's say you have a bunch of refunds, 527 00:28:04,740 --> 00:28:05,900 but you use up all your credit bits. 528 00:28:06,400 --> 00:28:07,540 What do you do then? 529 00:28:07,640 --> 00:28:09,680 They have this refund buffer area 530 00:28:09,680 --> 00:28:11,440 that's only for about maybe $5. 531 00:28:11,860 --> 00:28:13,980 And so you can really only refund $5 532 00:28:13,980 --> 00:28:14,860 and actually use it. 533 00:28:16,200 --> 00:28:18,540 So it seems kind of pointless 534 00:28:18,540 --> 00:28:19,980 to refund a bunch of credits 535 00:28:19,980 --> 00:28:21,780 when you can only use like five extra dollars. 536 00:28:23,320 --> 00:28:24,640 So on this particular card, 537 00:28:24,740 --> 00:28:26,100 there's six bits for credits 538 00:28:26,540 --> 00:28:28,300 plus seven bits for refunds, 539 00:28:28,300 --> 00:28:29,480 so it ends up being like $1.30. 540 00:28:32,720 --> 00:28:34,540 Now, if you want to figure out how they 541 00:28:34,540 --> 00:28:37,040 increment credits and deduct credits, 542 00:28:37,040 --> 00:28:40,140 you have to somehow reverse engineer the protocol 543 00:28:40,140 --> 00:28:42,660 by tapping it or guessing or something like that. 544 00:28:42,840 --> 00:28:47,420 So the basic method is to somehow tap the connection, 545 00:28:47,700 --> 00:28:49,760 log the data, and decode the protocol. 546 00:28:52,760 --> 00:28:55,080 Now, you can buy lots of tappers 547 00:28:55,080 --> 00:28:56,060 for asynchronous cards, 548 00:28:56,240 --> 00:28:59,280 like I have this one right here 549 00:28:59,280 --> 00:29:01,780 that Prime Star can sue you for having. 550 00:29:02,200 --> 00:29:04,900 And these things are great. 551 00:29:04,980 --> 00:29:06,000 They just have a serial interface. 552 00:29:06,000 --> 00:29:07,440 You can listen to communication. 553 00:29:08,000 --> 00:29:09,620 But I can't find anything 554 00:29:09,620 --> 00:29:11,220 that's made for synchronous stuff. 555 00:29:11,720 --> 00:29:13,940 And so I don't know anything about electronics, 556 00:29:14,240 --> 00:29:16,560 but with a friend of mine, 557 00:29:16,580 --> 00:29:18,380 we ended up developing this thing. 558 00:29:19,620 --> 00:29:21,240 It's attached onto the back of this laptop. 559 00:29:21,400 --> 00:29:21,940 It's really ghetto. 560 00:29:26,620 --> 00:29:28,400 They made like a fake smart card. 561 00:29:28,600 --> 00:29:29,540 I'm not sure if you can see this, 562 00:29:29,660 --> 00:29:31,460 but it's actually a Pete's Coffee card 563 00:29:31,460 --> 00:29:32,860 that I put copper tape on, 564 00:29:33,280 --> 00:29:34,380 and it's soldered onto 565 00:29:34,380 --> 00:29:35,960 a ripped-up floppy drive cable. 566 00:29:36,480 --> 00:29:38,680 And it's run over to this smart card socket 567 00:29:38,680 --> 00:29:39,440 that I ripped off 568 00:29:39,440 --> 00:29:40,460 of an old smart card reader 569 00:29:40,460 --> 00:29:41,180 that I had laying around. 570 00:29:42,180 --> 00:29:44,040 And that goes back to... 571 00:29:45,820 --> 00:29:46,940 And then I end up using 572 00:29:47,500 --> 00:29:49,460 one of these floppy drive cable thingies. 573 00:29:49,740 --> 00:29:51,560 It has vampire clips on it 574 00:29:51,560 --> 00:29:52,200 to tap the connection. 575 00:29:53,020 --> 00:29:56,140 And that runs back to 10K resistors. 576 00:29:56,520 --> 00:29:57,180 It goes to a buffer. 577 00:29:57,380 --> 00:29:58,980 It goes to the parallel port, 578 00:29:59,060 --> 00:30:00,020 so you can monitor the lines. 579 00:30:01,400 --> 00:30:02,520 And in the FRAC article, 580 00:30:02,680 --> 00:30:03,880 I have lots of cool ASCII art. 581 00:30:04,020 --> 00:30:04,360 So... 582 00:30:06,380 --> 00:30:08,420 This is like the basic schematics for it 583 00:30:08,420 --> 00:30:09,140 if you want to make your own. 584 00:30:11,220 --> 00:30:12,640 And with logging the data, 585 00:30:13,120 --> 00:30:15,340 you just pull the parallel port I.O., 586 00:30:15,340 --> 00:30:17,040 and you can find all kinds of information 587 00:30:17,040 --> 00:30:19,640 on dealing with the parallel port online. 588 00:30:20,260 --> 00:30:21,800 And if the I.O. lines change, 589 00:30:22,020 --> 00:30:22,760 just log it to memory, 590 00:30:22,920 --> 00:30:23,980 and then once you're done, 591 00:30:24,000 --> 00:30:24,620 just save it to a file. 592 00:30:24,760 --> 00:30:26,940 I had the really bad idea 593 00:30:26,940 --> 00:30:27,820 of just printing it out, 594 00:30:27,940 --> 00:30:30,320 and this stuff goes so fast 595 00:30:30,320 --> 00:30:32,040 that I was just losing bits left and right, 596 00:30:32,160 --> 00:30:34,600 so a lot of trial and error 597 00:30:34,600 --> 00:30:35,120 getting that to work. 598 00:30:36,580 --> 00:30:38,500 But it's really simple code for doing that. 599 00:30:41,020 --> 00:30:42,340 And decoding the protocol. 600 00:30:42,580 --> 00:30:44,420 I just wrote this really simple program 601 00:30:44,420 --> 00:30:47,720 for decoding bytes from the stream that you get, 602 00:30:48,640 --> 00:30:50,780 and then also doing time graph analysis. 603 00:30:52,880 --> 00:30:54,760 So here's a quick demonstration of that. 604 00:31:11,120 --> 00:31:12,380 I'll show you. 605 00:31:12,380 --> 00:31:13,100 Damn, the pin's burnt. 606 00:31:15,580 --> 00:31:16,220 . 607 00:31:20,720 --> 00:31:21,840 Okay, better. 608 00:31:26,400 --> 00:31:27,040 . 609 00:31:27,040 --> 00:31:27,520 . 610 00:31:31,800 --> 00:31:33,440 Present for the DEF CON staff. 611 00:31:39,700 --> 00:31:41,140 There we go. 612 00:31:48,280 --> 00:31:49,620 Woo-hoo! 613 00:31:59,420 --> 00:32:01,700 Okay, so... 614 00:32:06,620 --> 00:32:08,140 I'm just gonna... 615 00:32:28,780 --> 00:32:30,020 What's the password? 616 00:32:36,560 --> 00:32:36,980 . 617 00:32:40,760 --> 00:32:41,600 Thank God. 618 00:32:43,500 --> 00:32:44,400 Okay, there it goes. 619 00:32:46,420 --> 00:32:49,200 Okay, so I'm gonna tap the connection 620 00:32:49,200 --> 00:32:51,760 between this parking meter card 621 00:32:51,760 --> 00:32:53,800 and my smart card reader over here. 622 00:32:54,020 --> 00:32:55,940 I wasn't able to bring a real parking meter out here. 623 00:32:56,040 --> 00:32:59,220 I'm sorry, guys, but it's just too heavy. 624 00:32:59,800 --> 00:33:00,280 What's that? 625 00:33:01,520 --> 00:33:01,940 . 626 00:33:04,620 --> 00:33:05,040 Oh. 627 00:33:06,160 --> 00:33:07,860 Okay, so I'm gonna... 628 00:33:12,620 --> 00:33:15,460 I just inserted my fake card into the reader, 629 00:33:15,620 --> 00:33:16,860 and so it's doing its thing. 630 00:33:17,940 --> 00:33:19,380 And I'm gonna pull it out. 631 00:33:22,340 --> 00:33:23,000 Cancel it. 632 00:33:26,580 --> 00:33:27,060 Oops. 633 00:33:27,820 --> 00:33:28,880 Spacebar doesn't work at all. 634 00:33:36,120 --> 00:33:38,520 So I just logged the bits to the file, 635 00:33:38,640 --> 00:33:43,300 and it's not too pleasant to deal with this stuff. 636 00:33:43,980 --> 00:33:44,400 So... 637 00:33:48,600 --> 00:33:50,260 We can pipe it through here. 638 00:33:52,100 --> 00:33:52,520 . 639 00:33:57,540 --> 00:33:59,840 And here's some of the data that's pulling down. 640 00:34:00,740 --> 00:34:02,280 It does all kinds of crazy stuff. 641 00:34:04,000 --> 00:34:05,580 But it kind of gives you an idea for... 642 00:34:06,820 --> 00:34:09,240 for what sort of information it's getting. 643 00:34:11,000 --> 00:34:12,180 The coolest stuff, though, 644 00:34:12,220 --> 00:34:14,240 is doing time graph analysis, 645 00:34:14,620 --> 00:34:15,860 because that's when you can really figure out 646 00:34:15,860 --> 00:34:16,800 the protocols a little bit better. 647 00:34:18,800 --> 00:34:20,260 And I got this on the other machine. 648 00:34:24,860 --> 00:34:25,300 . 649 00:34:31,160 --> 00:34:31,600 And... 650 00:34:32,200 --> 00:34:34,580 So you can feed it into a script 651 00:34:34,580 --> 00:34:36,060 that we put together 652 00:34:36,060 --> 00:34:37,640 that just graphs it out. 653 00:34:38,680 --> 00:34:39,700 So you can kind of see, 654 00:34:39,800 --> 00:34:41,380 okay, here's some bits that have been going along. 655 00:34:41,660 --> 00:34:42,760 The clock is on the bottom. 656 00:34:43,020 --> 00:34:44,360 The reset is actually inverted, 657 00:34:44,440 --> 00:34:45,940 and it's kind of weird on here. 658 00:34:46,080 --> 00:34:47,560 But the reset's up on the top. 659 00:34:48,280 --> 00:34:49,020 Second to top. 660 00:34:49,200 --> 00:34:50,760 And then the I-line's at the very top. 661 00:34:50,880 --> 00:34:52,360 So you can see there's some data there. 662 00:34:52,640 --> 00:34:54,140 And it just stays high. 663 00:34:56,700 --> 00:35:00,020 And it goes low for all of our credit bits. 664 00:35:00,140 --> 00:35:00,900 And it goes high again. 665 00:35:02,500 --> 00:35:02,900 And... 666 00:35:03,660 --> 00:35:05,240 It goes along, goes along. 667 00:35:05,620 --> 00:35:07,300 And then it resets and reads it again. 668 00:35:07,520 --> 00:35:08,420 It does this a lot. 669 00:35:08,620 --> 00:35:09,580 It reads it, like, 670 00:35:09,580 --> 00:35:11,240 maybe about half a dozen times or so. 671 00:35:13,240 --> 00:35:13,640 And... 672 00:35:14,800 --> 00:35:16,140 Actually, like, this area right here 673 00:35:16,140 --> 00:35:17,500 is where it actually writes to the card 674 00:35:17,500 --> 00:35:20,260 and deducts or increments credits and stuff. 675 00:35:20,720 --> 00:35:23,720 And I kind of have it explained a little bit better in slides. 676 00:35:26,200 --> 00:35:26,600 But... 677 00:35:28,600 --> 00:35:30,520 In memory dump, you kind of see, you know, 678 00:35:30,560 --> 00:35:32,800 like, the I-line going up and down and stuff. 679 00:35:32,900 --> 00:35:34,820 And then with the write to the card, 680 00:35:35,020 --> 00:35:36,800 it does this weird sequence. 681 00:35:36,900 --> 00:35:38,600 And so it's just, like, how the protocol works. 682 00:35:39,580 --> 00:35:40,600 But for deduct, 683 00:35:40,880 --> 00:35:42,920 it ends up having this sort of pattern to it. 684 00:35:44,140 --> 00:35:46,200 And it resets a couple times. 685 00:35:46,360 --> 00:35:49,240 And it actually uses one of the reserved lines to do this. 686 00:35:50,480 --> 00:35:52,280 So you have to account for that 687 00:35:52,280 --> 00:35:53,700 when you're emulating it or whatever. 688 00:35:54,020 --> 00:35:54,880 Or tapping it. 689 00:35:55,500 --> 00:35:58,100 And for a refund, it ends up doing something like this. 690 00:35:58,260 --> 00:36:01,580 And so you can do the same thing to the card 691 00:36:01,580 --> 00:36:02,880 to refund a bunch of bits if you want. 692 00:36:02,900 --> 00:36:03,060 But... 693 00:36:05,900 --> 00:36:07,620 But what I've been working on 694 00:36:07,620 --> 00:36:10,220 is emulating the Park-O-Meter cards. 695 00:36:10,540 --> 00:36:13,180 So, you know, you can just walk up with a card 696 00:36:13,180 --> 00:36:16,080 and insert it with $50 or whatever 697 00:36:16,080 --> 00:36:17,360 and it deducts some amount. 698 00:36:17,700 --> 00:36:20,600 And I just don't like dealing with EEPROM 699 00:36:20,600 --> 00:36:21,820 and stuff that saves to the card. 700 00:36:21,940 --> 00:36:23,240 So I just make it forget the credits 701 00:36:23,240 --> 00:36:25,620 and go back to $50 the next time you insert it. 702 00:36:27,880 --> 00:36:29,860 And so that'll probably... 703 00:36:29,860 --> 00:36:30,960 The code for that will be... 704 00:36:30,960 --> 00:36:32,100 I'll release it pretty soon. 705 00:36:32,100 --> 00:36:32,560 I'm just... 706 00:36:32,940 --> 00:36:34,860 It's been hard to test it out here without a Park-O-Meter. 707 00:36:36,840 --> 00:36:37,900 Yeah, look for a FRAC... 708 00:36:37,900 --> 00:36:40,100 Look at FRAC 4811 for hints. 709 00:36:40,660 --> 00:36:42,100 I'm using a 16F84A. 710 00:36:42,740 --> 00:36:43,980 Those are pretty popular right now. 711 00:36:44,240 --> 00:36:45,900 And just make sure you supply a clock. 712 00:36:46,440 --> 00:36:49,320 And a good tip is to tie the clock line to interrupt. 713 00:36:51,340 --> 00:36:53,700 Yeah, so I'll have full code and semantics pretty soon. 714 00:36:54,560 --> 00:36:56,680 Send me for details if you want any sneak peeks or anything. 715 00:36:58,080 --> 00:36:58,980 And brute force. 716 00:36:59,520 --> 00:37:02,080 This is a really cool thing that I found out. 717 00:37:02,080 --> 00:37:03,920 When I was messing with them. 718 00:37:04,060 --> 00:37:07,240 And I was struggling on this stuff for a couple months. 719 00:37:07,440 --> 00:37:10,520 And then I just tried this thing out out of accident. 720 00:37:10,720 --> 00:37:13,300 And you just fold a business card in half, stick it in. 721 00:37:13,420 --> 00:37:15,540 It's not a valid smart card, so it goes out of order. 722 00:37:17,560 --> 00:37:19,160 And if you fold a business card in half, 723 00:37:19,220 --> 00:37:21,300 it's the perfect size where it's hard to pull out. 724 00:37:22,060 --> 00:37:24,040 And people barely even notice that it's in there. 725 00:37:24,240 --> 00:37:26,180 And so if it's out of order, 726 00:37:26,320 --> 00:37:28,580 you can just park there forever until they figure it out. 727 00:37:30,720 --> 00:37:31,040 But... 728 00:37:32,080 --> 00:37:34,700 Yeah, and then just use a credit card or something to pull it out later. 729 00:37:49,860 --> 00:37:52,760 And other memory cards, like I said, with the pins and stuff. 730 00:37:53,960 --> 00:37:56,480 A lot of this stuff is just security through obscurity. 731 00:37:56,680 --> 00:38:00,100 They figure that if they make a weird protocol, nobody's going to figure it out. 732 00:38:00,800 --> 00:38:01,160 So... 733 00:38:02,180 --> 00:38:04,740 Like, I have this friend in Holland 734 00:38:04,740 --> 00:38:07,040 that was auditing some university soda machines. 735 00:38:07,320 --> 00:38:10,440 Because lots of universities use cards for credits for students and stuff. 736 00:38:11,060 --> 00:38:13,820 And it turned out that every card had a different pin 737 00:38:13,820 --> 00:38:16,280 for enabling read-write on it. 738 00:38:16,600 --> 00:38:18,820 And what they ended up doing was they thought, 739 00:38:18,940 --> 00:38:21,140 oh, well, we'll have a different pin on each card. 740 00:38:21,260 --> 00:38:24,840 So if somebody gets one card, then they can't unlock all of them. 741 00:38:25,500 --> 00:38:29,360 And so what they did was they just had a bunch of garbage data on the card. 742 00:38:29,480 --> 00:38:30,920 And they'd do something like... 743 00:38:31,540 --> 00:38:35,780 Byte 6 plus byte 8 minus, like, byte 42 744 00:38:36,380 --> 00:38:39,380 divided by some other byte equals, you know, whatever the pin is. 745 00:38:39,640 --> 00:38:43,680 And so the soda machine would know this sort of algorithm. 746 00:38:43,840 --> 00:38:46,120 It would read the card data and then figure out the pin 747 00:38:46,120 --> 00:38:48,360 and then use that to unlock it to rewrite the credits on the card. 748 00:38:50,100 --> 00:38:54,180 And so, I mean, like, you can easily defeat this stuff. 749 00:38:54,460 --> 00:39:00,000 Michael Stegen actually ended up coding a pic to just emulate the card. 750 00:39:00,000 --> 00:39:01,180 And then when it receives the pin, 751 00:39:01,280 --> 00:39:02,960 it just saves it to another portion of memory on there. 752 00:39:03,540 --> 00:39:06,140 And so, you know, you stick it in the machine 753 00:39:06,140 --> 00:39:10,680 and it unlocks the card and thinks that everything's fine, deducts the credits. 754 00:39:10,980 --> 00:39:12,760 And then you just take the card, stick it in your machine, 755 00:39:12,960 --> 00:39:15,980 and you can see what the pin is because it just writes it right there. 756 00:39:17,800 --> 00:39:19,760 And there's all kinds of ways of getting around it. 757 00:39:19,840 --> 00:39:21,380 And it's just security through obscurity. 758 00:39:22,520 --> 00:39:25,600 But most of the time, it seems that people just use the same pin on every card. 759 00:39:25,920 --> 00:39:28,420 So if you can tap the connection, you can figure out the pin. 760 00:39:30,140 --> 00:39:32,640 And then just, you know, have fun rewriting all their cards. 761 00:39:35,260 --> 00:39:36,420 So, yeah, conclusions. 762 00:39:37,480 --> 00:39:41,640 That's how you can reach me if you want to email me anything and ask me any questions. 763 00:39:42,240 --> 00:39:43,280 And some references. 764 00:39:44,020 --> 00:39:44,880 Really great stuff. 765 00:39:49,220 --> 00:39:49,820 Shameful plugs. 766 00:39:50,260 --> 00:39:53,740 Come to TorCon, please, if you're able to make it out. 767 00:39:55,240 --> 00:39:58,060 And I'm going to be at ShmooCon, so if you want to go there. 768 00:39:58,380 --> 00:39:59,940 And I think Layer 1 is going on. 769 00:40:00,000 --> 00:40:00,900 Again, next year or so. 770 00:40:01,960 --> 00:40:02,940 Some good conferences. 771 00:40:03,080 --> 00:40:04,140 I'd like to support the small ones. 772 00:40:06,700 --> 00:40:07,960 And questions, suggestions? 773 00:40:08,220 --> 00:40:10,860 Who wants a free smart card reader? 774 00:40:13,020 --> 00:40:13,460 Wow. 775 00:40:15,840 --> 00:40:19,520 You guys didn't respond too well to the question suggestions, but, I mean. 776 00:40:21,000 --> 00:40:21,520 What's that? 777 00:40:22,700 --> 00:40:23,500 Oh, okay. 778 00:40:23,620 --> 00:40:24,020 All right. 779 00:40:24,040 --> 00:40:24,540 Do you have any questions? 780 00:40:26,580 --> 00:40:27,820 Are you going to give me the cards? 781 00:40:30,160 --> 00:40:31,500 Are those smart cards? 782 00:40:35,580 --> 00:40:37,260 Oh, like a mag stripe? 783 00:40:41,520 --> 00:40:42,520 Oh, okay. 784 00:40:43,060 --> 00:40:43,560 What's that? 785 00:40:44,740 --> 00:40:45,360 What's that? 786 00:40:47,600 --> 00:40:48,680 I don't know. 787 00:40:48,720 --> 00:40:50,160 It's probably a processor card or something. 788 00:40:50,520 --> 00:40:50,900 What? 789 00:40:51,620 --> 00:40:52,540 Oh, a BART card? 790 00:40:52,900 --> 00:40:54,220 No, I don't have a mag stripe reader. 791 00:40:56,120 --> 00:40:56,700 What's that? 792 00:40:58,140 --> 00:40:58,640 Huh. 793 00:40:58,640 --> 00:40:59,720 I'd like to take a look. 794 00:41:00,120 --> 00:41:00,600 Oh, yeah. 795 00:41:00,660 --> 00:41:01,120 It doesn't have... 796 00:41:01,120 --> 00:41:03,240 Does it have the pinouts on it? 797 00:41:03,420 --> 00:41:03,520 Like... 798 00:41:03,520 --> 00:41:04,480 Yeah, it's true. 799 00:41:04,620 --> 00:41:06,520 Like how it has some gold on the top? 800 00:41:06,740 --> 00:41:06,920 Yeah. 801 00:41:07,100 --> 00:41:07,460 No? 802 00:41:07,640 --> 00:41:08,120 It's something like this. 803 00:41:08,180 --> 00:41:08,880 It actually does that. 804 00:41:09,200 --> 00:41:09,780 Yeah, yeah. 805 00:41:10,980 --> 00:41:11,860 You have a question? 806 00:41:12,580 --> 00:41:12,940 . 807 00:41:13,780 --> 00:41:14,140 Oh. 808 00:41:14,480 --> 00:41:14,840 . 809 00:41:15,520 --> 00:41:15,880 . 810 00:41:15,880 --> 00:41:16,000 . 811 00:41:16,000 --> 00:41:16,160 . 812 00:41:16,160 --> 00:41:16,320 . 813 00:41:16,320 --> 00:41:16,420 . 814 00:41:16,420 --> 00:41:17,080 . 815 00:41:17,080 --> 00:41:17,660 . 816 00:41:17,660 --> 00:41:17,720 . 817 00:41:18,780 --> 00:41:19,140 . 818 00:41:20,600 --> 00:41:21,080 . 819 00:41:26,500 --> 00:41:26,980 . 820 00:41:27,500 --> 00:41:27,980 . 821 00:41:27,980 --> 00:41:28,080 . 822 00:41:28,080 --> 00:41:28,580 . 823 00:41:28,580 --> 00:41:28,700 . 824 00:41:28,700 --> 00:41:28,760 . 825 00:41:28,760 --> 00:41:29,160 . 826 00:41:30,900 --> 00:41:32,460 It's not worth anything yet. 827 00:41:35,120 --> 00:41:36,080 In fact... 828 00:41:36,080 --> 00:41:36,240 Yeah. 829 00:41:37,880 --> 00:41:38,980 I've heard about this. 830 00:41:39,020 --> 00:41:43,260 He was saying how credit card companies are starting to distribute smart card readers 831 00:41:43,260 --> 00:41:43,700 and stuff. 832 00:41:44,540 --> 00:41:48,420 I think they use it for like authentication with their websites and things like that 833 00:41:48,420 --> 00:41:49,120 and so... 834 00:41:49,140 --> 00:41:53,940 Yeah, totally. You could try and tap the connection and figure out how they talk to each other 835 00:41:53,940 --> 00:41:57,740 and try some attacks on there, but I haven't looked at them personally. 836 00:41:59,620 --> 00:42:00,060 What's that? 837 00:42:01,540 --> 00:42:02,240 Yeah, yeah. 838 00:42:05,360 --> 00:42:09,580 Yeah, so there's plenty of drivers out there for Gem Plus readers, but I couldn't find 839 00:42:09,580 --> 00:42:16,200 anything for these, so good luck. But you can have one if you want. I'll just leave 840 00:42:16,200 --> 00:42:19,440 it here for you or something. Anybody else? 841 00:42:21,180 --> 00:42:24,900 What's that? Oh, okay, yeah, yeah, you deserve one. What's that? 842 00:42:35,320 --> 00:42:39,260 I'm not quite sure. I think it might be for timing reasons or something like that. They 843 00:42:39,260 --> 00:42:43,500 were just kind of lazy and they, you know, when you stick the card into the meter, it 844 00:42:43,500 --> 00:42:45,840 ends up flashing, you know, the credits on the card. 845 00:42:46,200 --> 00:42:50,300 And then it starts slowly counting it down and stuff. And so it might have been some 846 00:42:50,300 --> 00:42:55,700 sort of timing weird thing or maybe they just wanted to verify that, you know, the data 847 00:42:55,700 --> 00:42:59,240 was there and there wasn't any corruption in the line or something like that. That's 848 00:42:59,240 --> 00:43:00,040 my only guess. 849 00:43:00,980 --> 00:43:01,680 Somebody over here? 850 00:43:02,480 --> 00:43:06,960 You've been talking about using the actual interface to read the data off of the card. 851 00:43:07,220 --> 00:43:12,700 Is there any work on physically tapping into the flash on the card, bypassing the interface? 852 00:43:12,940 --> 00:43:15,740 Yeah, I know some people. He was saying that... 853 00:43:16,360 --> 00:43:20,180 He was wondering if any cards, any people have been actually disassembling the cards 854 00:43:20,180 --> 00:43:25,200 to read directly from the flash. And I know that some people were using, like, electron 855 00:43:25,200 --> 00:43:30,180 microscopes and stuff like that, using acid to burn away the plastic and stuff. But, you 856 00:43:30,180 --> 00:43:35,160 know, it's just, it takes a lot of equipment and it's really difficult. So, but, yeah, 857 00:43:35,220 --> 00:43:40,640 people have been working on that. So, yeah, you can have one of these and you can have 858 00:43:40,640 --> 00:43:42,760 one of these if you want. Yeah? 859 00:43:43,000 --> 00:43:43,620 What about timing? 860 00:43:45,820 --> 00:43:46,180 Timing? 861 00:43:46,200 --> 00:43:46,360 Timing attacks? 862 00:43:52,260 --> 00:43:57,100 Yeah, for attacking GSM, the side channel attack actually analyzes the amount of power 863 00:43:57,100 --> 00:44:03,600 it's sucking. And so, what it uses, it turns out that when it's computing stuff, there's 864 00:44:03,600 --> 00:44:09,880 a table in there that's actually 512 bytes. And it can only do 8 bits at a time. And so 865 00:44:09,880 --> 00:44:13,980 they split it up into two tables and there's a noticeable power drain when it reads from 866 00:44:13,980 --> 00:44:14,680 one table to another. 867 00:44:14,680 --> 00:44:20,180 And so they use something like that to do it. I'm not totally sure about timing attacks, 868 00:44:20,460 --> 00:44:24,200 but people are definitely working on, like, side channel attacks like that. 869 00:44:26,320 --> 00:44:27,060 Yeah, go ahead. 870 00:44:29,360 --> 00:44:29,840 Yeah. 871 00:44:33,460 --> 00:44:33,840 Yeah. 872 00:44:34,960 --> 00:44:35,440 Yeah. 873 00:44:43,860 --> 00:44:44,340 Yeah. 874 00:44:44,380 --> 00:44:44,640 Yeah. 875 00:44:44,640 --> 00:44:44,660 Yeah. 876 00:44:44,680 --> 00:44:44,900 Yeah. 877 00:44:45,440 --> 00:44:46,620 Yeah. Yeah. Yeah. That 878 00:44:46,620 --> 00:44:47,760 is definitely a lack of organization for cave-happybbieottle ви. 879 00:44:47,760 --> 00:44:47,940 How did they reprogram or ... ? 880 00:44:49,000 --> 00:44:51,600 Oh, how did they reprogram them for stuff like that? 881 00:44:52,440 --> 00:44:52,820 I... 882 00:44:53,920 --> 00:44:58,480 Oh, I don't know. I'm thinking that they might interface with some sort of smart card or... 883 00:44:59,380 --> 00:45:07,220 I have no idea. I'm not sure. But I'm guessing that if everybody's... Everybody ends up making 884 00:45:07,220 --> 00:45:11,060 these cards that get you free parking, they'll end up having to upgrade all of them or something 885 00:45:11,060 --> 00:45:11,460 like that. 886 00:45:11,560 --> 00:45:14,200 So, we can find out then. What's that? 887 00:45:14,360 --> 00:45:14,660 There was a game. 888 00:45:15,340 --> 00:45:16,040 Oh, are they? 889 00:45:16,580 --> 00:45:17,160 Oh, okay. 890 00:45:18,780 --> 00:45:19,980 What, before or after? 891 00:45:20,920 --> 00:45:21,400 That's fine. 892 00:45:21,800 --> 00:45:24,380 I talked to them about taking control here. 893 00:45:26,160 --> 00:45:26,600 Okay. 894 00:45:28,680 --> 00:45:29,340 Yeah, you. 895 00:45:29,780 --> 00:45:33,680 Here with the Java cards, the military cards, 896 00:45:33,860 --> 00:45:36,460 what they're using in things like departmental and security 897 00:45:36,460 --> 00:45:37,320 and all these things there. 898 00:45:37,380 --> 00:45:37,720 Yeah. 899 00:45:37,900 --> 00:45:40,680 And I was wondering if you're able to actually pull down 900 00:45:40,680 --> 00:45:44,400 some of their little programs that they install on them 901 00:45:44,400 --> 00:45:46,200 or be able to manipulate those, 902 00:45:46,340 --> 00:45:51,620 or even a couple of new programs that would fool other type of, 903 00:45:52,480 --> 00:45:54,060 when they put their card back in, 904 00:45:54,200 --> 00:45:56,160 just put a Trojan horse on their card. 905 00:45:56,520 --> 00:45:56,880 Right. 906 00:45:57,120 --> 00:45:58,860 I guess you could manipulate the data. 907 00:45:59,260 --> 00:46:02,440 Yeah, he was saying that a lot of places are using, like, 908 00:46:02,440 --> 00:46:03,560 Java cards and stuff like that, 909 00:46:03,620 --> 00:46:04,860 and so you might be able to reprogram them. 910 00:46:05,200 --> 00:46:07,960 And, yeah, like, the stuff that I've been dealing with, 911 00:46:08,040 --> 00:46:09,160 you can't reprogram them. 912 00:46:09,200 --> 00:46:10,620 It's all, like, hard-coded in the chip. 913 00:46:10,780 --> 00:46:14,040 But I know that, like, Bruce Potter 914 00:46:14,040 --> 00:46:14,380 and... 915 00:46:14,400 --> 00:46:16,800 some other people have been working on the Java card stuff, 916 00:46:16,940 --> 00:46:18,760 and there's definitely, like, all kinds of cool attacks 917 00:46:18,760 --> 00:46:19,480 you can do with those. 918 00:46:20,180 --> 00:46:23,180 Do you say that the military IDs use Java cards? 919 00:46:24,080 --> 00:46:24,640 Oh, okay. 920 00:46:24,980 --> 00:46:28,280 And also, the government stuff is also going to come up 921 00:46:28,280 --> 00:46:29,040 with Java cards. 922 00:46:31,020 --> 00:46:33,080 TSA and all this stuff, you can use Java cards. 923 00:46:33,280 --> 00:46:33,680 Oh, okay. 924 00:46:33,880 --> 00:46:35,020 Yeah, it'd be interesting to look at. 925 00:46:36,960 --> 00:46:37,560 Yeah, go ahead. 926 00:46:37,700 --> 00:46:39,220 I just want to know, is there any work 927 00:46:40,560 --> 00:46:42,500 getting generated on a personal account? 928 00:46:44,160 --> 00:46:46,120 Oh, the PUK for SIM cards? 929 00:46:46,720 --> 00:46:47,780 Yeah, I don't know. 930 00:46:50,480 --> 00:46:52,480 I don't know how you'd get that, 931 00:46:53,840 --> 00:46:55,760 because, yeah, I haven't looked at any of the attacks 932 00:46:55,760 --> 00:46:57,140 when getting the pins or the PUK. 933 00:47:00,180 --> 00:47:00,860 Yeah, yeah. 934 00:47:01,120 --> 00:47:03,760 Yeah, you can emulate the card once you have the key, 935 00:47:03,860 --> 00:47:05,080 so you don't have to worry about that stuff 936 00:47:05,080 --> 00:47:05,660 once you get there. 937 00:47:06,440 --> 00:47:07,280 But, yeah, it'd be interesting 938 00:47:07,280 --> 00:47:09,260 if somebody found some attacks on getting that. 939 00:47:10,240 --> 00:47:10,800 Yeah, go ahead. 940 00:47:11,080 --> 00:47:11,980 Would these... 941 00:47:11,980 --> 00:47:12,480 Would these... 942 00:47:32,160 --> 00:47:33,180 Yeah, I don't know. 943 00:47:33,260 --> 00:47:36,140 I noticed that all of them have serial numbers 944 00:47:36,140 --> 00:47:36,940 and stuff like that, 945 00:47:37,060 --> 00:47:38,400 and so there might be some sort of algorithm 946 00:47:38,400 --> 00:47:41,020 for verifying that it's, like, a valid card. 947 00:47:41,180 --> 00:47:42,320 Like a recent code. 948 00:47:42,800 --> 00:47:44,360 Yeah, they might have something like that. 949 00:47:44,520 --> 00:47:46,400 And so, in that case, 950 00:47:46,420 --> 00:47:49,060 then, if you use, you know, like, an emulator 951 00:47:49,060 --> 00:47:49,560 or something like that, 952 00:47:49,600 --> 00:47:50,520 you just have to reprogram that. 953 00:47:50,700 --> 00:47:52,100 And I would think that it would work. 954 00:47:52,160 --> 00:47:54,400 I noticed that there's just a couple parking meter 955 00:47:55,200 --> 00:47:57,560 manufacturers that are doing this kind of stuff, 956 00:47:57,660 --> 00:47:58,860 and so it's probably really similar 957 00:47:58,860 --> 00:47:59,980 between the different cities. 958 00:48:02,120 --> 00:48:02,600 Go ahead. 959 00:48:03,540 --> 00:48:03,900 Yeah. 960 00:48:21,780 --> 00:48:22,600 I don't know. 961 00:48:22,640 --> 00:48:24,540 It seems like smart cards are pretty popular right now, 962 00:48:24,640 --> 00:48:26,440 and it seems like RFIDs are, too. 963 00:48:27,300 --> 00:48:27,880 But I... 964 00:48:28,700 --> 00:48:29,540 I don't know. 965 00:48:29,900 --> 00:48:31,820 There's definitely a lot of stuff people are doing 966 00:48:31,820 --> 00:48:33,260 with smart cards nowadays, 967 00:48:33,260 --> 00:48:34,340 and, like, with Java cards, 968 00:48:34,440 --> 00:48:37,900 and making things a lot more secure, 969 00:48:38,020 --> 00:48:41,360 like with PKI and stuff like that, so... 970 00:48:41,980 --> 00:48:44,480 And it seems like RFIDs are pretty new, 971 00:48:44,580 --> 00:48:46,600 and so there isn't a whole lot of security in them yet. 972 00:48:47,200 --> 00:48:48,040 So I don't know. 973 00:48:48,080 --> 00:48:48,980 It really depends. 974 00:48:49,400 --> 00:48:51,640 I like the manufacturing costs and stuff like that, I guess. 975 00:48:51,700 --> 00:48:52,260 I don't know. 976 00:48:55,260 --> 00:48:56,260 Yeah, way back there. 977 00:48:57,320 --> 00:48:57,720 Yeah. 978 00:48:57,720 --> 00:49:00,460 You said the parking meters are kind of kind of right here. 979 00:49:01,380 --> 00:49:02,180 Well, one... 980 00:49:06,380 --> 00:49:07,300 No, I... 981 00:49:07,300 --> 00:49:08,160 No, I don't, 982 00:49:08,160 --> 00:49:09,860 but I live in downtown San Diego, 983 00:49:09,920 --> 00:49:11,680 so it's, like, right out my door. 984 00:49:11,920 --> 00:49:12,480 What's the question? 985 00:49:12,860 --> 00:49:16,080 Oh, he was asking if I actually own a parking meter 986 00:49:16,080 --> 00:49:17,000 or possess one. 987 00:49:17,540 --> 00:49:19,540 I guess I can't use the hacks all late at night. 988 00:49:22,140 --> 00:49:24,200 Yeah, we were thinking of using our friend's Hummer 989 00:49:24,200 --> 00:49:26,060 and tying it to the back or something. 990 00:49:27,840 --> 00:49:28,640 Oh, okay. 991 00:49:31,300 --> 00:49:32,760 Yeah, just... 992 00:49:32,760 --> 00:49:33,240 Yeah, just... 993 00:49:33,240 --> 00:49:34,200 A couple more questions. 994 00:49:34,520 --> 00:49:35,000 Jaya? 995 00:49:35,540 --> 00:49:36,020 Yeah. 996 00:49:36,960 --> 00:49:37,440 Yeah. 997 00:49:41,300 --> 00:49:42,980 Oh, to the GSM attacks? 998 00:49:47,260 --> 00:49:48,320 I don't know. 999 00:49:48,420 --> 00:49:51,820 Somebody from Europe, like, emailed me the other day 1000 00:49:51,820 --> 00:49:55,260 asking about it, and I think that they're definitely 1001 00:49:55,260 --> 00:49:58,120 doing a lot of stuff to roll out new algorithms. 1002 00:49:58,300 --> 00:50:01,420 Like, I know Qualcomm has just published Silver 128. 1003 00:50:01,800 --> 00:50:03,140 That's supposed to be, like, the new candidate, 1004 00:50:03,140 --> 00:50:05,460 for new GSM stuff. 1005 00:50:06,080 --> 00:50:07,620 There seems like there's all kinds of 1006 00:50:07,620 --> 00:50:08,720 open-source candidates out there, 1007 00:50:08,800 --> 00:50:10,420 so I don't think they're too concerned 1008 00:50:10,420 --> 00:50:13,000 about stuff right now, 1009 00:50:13,160 --> 00:50:15,620 but they're definitely using a lot of planning 1010 00:50:15,620 --> 00:50:18,400 to just fix things and start over properly, and so... 1011 00:50:19,960 --> 00:50:20,700 Yeah, one more. 1012 00:50:21,600 --> 00:50:25,040 So, you're saying that the GSM supercard 1013 00:50:25,040 --> 00:50:26,020 does a lot of processing, 1014 00:50:26,180 --> 00:50:28,200 but the parking meter card 1015 00:50:28,200 --> 00:50:29,960 seems to pretty much just work with the storage. 1016 00:50:30,180 --> 00:50:31,960 Could you get a generic show? 1017 00:50:35,800 --> 00:50:38,800 Yeah, I tried that, 1018 00:50:38,940 --> 00:50:41,440 but you actually need that extra reserved pin 1019 00:50:41,440 --> 00:50:42,440 that I was talking about. 1020 00:50:43,100 --> 00:50:45,560 If it doesn't have the right logic on that pin, 1021 00:50:45,700 --> 00:50:46,720 then it just doesn't work, 1022 00:50:46,900 --> 00:50:48,960 and there aren't really any of the memory cards 1023 00:50:48,960 --> 00:50:49,880 that use any of those pins. 1024 00:50:50,520 --> 00:50:52,220 And so, yeah, I definitely tried that, 1025 00:50:52,280 --> 00:50:54,300 because I have a couple different blank cards here 1026 00:50:54,300 --> 00:50:54,840 that I was using, 1027 00:50:54,960 --> 00:50:57,060 and they definitely are able to distinguish 1028 00:50:57,060 --> 00:50:59,480 between the correct ones and, you know, 1029 00:50:59,500 --> 00:51:00,280 like, ones you're copying. 1030 00:51:01,600 --> 00:51:01,960 Okay. 1031 00:51:02,060 --> 00:51:03,060 I guess that's it for today. 1032 00:51:03,360 --> 00:51:03,960 Thanks a lot. 1033 00:51:04,000 --> 00:51:04,820 If you have any other questions, 1034 00:51:05,140 --> 00:51:06,380 feel free to walk up to me later. 1035 00:51:11,380 --> 00:51:11,940 Thank you. 1036 00:51:42,260 --> 00:51:44,500 Thank you.