I'm Zach Franken. Thank you. Right, we're going to talk about physical access control systems. I did a talk last year, and I have put together a very quick talk this year because we've been doing some fun things. A major who spoke before me has been my bitch for the last six months, and it's been CodeMonkey. Yeah. So, yes. But CodeMonkey is dead useful once you get them to stop masturbating and throwing shit at the walls. Okay, now. Oniva. Oniva. Okay. So, this was going to be an all-singing, all-dancing extravaganza, and then I realized, fuck, that's a lot of live demos. So, we're going to do one super, super, super live demo which has great possibility for extreme messy disaster. You'll see what's going to happen in a minute. Okay, so we're going to talk about defeating a biometric system. Access control credentials. In general. And how to emulate a physical access control token. Okay, so, in case you're not familiar with it, this is the basics of an access control system. Should I actually try and hold the mic or not? This is the question. Fuck it. Okay. So, here we have a basic access control system. You have the access controller. Request to exit device. Normally a button or sometimes a passive infrared device mounted over the door. Not a good idea, by the way. An electric lock and a reader of some kind. Typically, proximity card readers, Y-Gand readers, mag stripes, or biometric readers these days. Now, this demo is going to take a little while to get going, so we're going to jump straight into the demo. So, I'm going to talk about hand geometry scanners. And I have one here, which I picked up on eBay for the stunning price of $2. I love eBay. eBay is your friend. Okay. However, when it arrived, it did appear to have been pried off the wall, so, I don't know. I don't know. Slightly bent out of shape and required a little bit of muscling to get it back working. Touch wood, it's going to work now. So, this access control system knows about me. And the way these particular ones work is you enter, you either hold a card up to a reader or you enter a code on the keypad and it'll ask you to present your hand and you pop your hand. I don't know if you can see on the screens here. You pop your hand on this platen and there's little pegs that help you line up your fingers because one of the big issues with biometrics is we're just big squidgy bags of mostly water. And in the digital age, we have alignment problems. So, and that's a big issue with most biometrics. So, there's normally something to help you line up to kind of interface you with the digital world. So, in this case, you have a set of pegs. You have a set of little lights on the reader and when you close your hands up around the pegs the light goes out, the lights go out and when you get all of them out it takes a reading. And it's just an image. The base of the platen is highly reflective and there's a camera, there's a set of mirrors and there's a camera here, a 45 degree mirror and it takes an image of your hand on this platen. This guy's quite nice because and I swear to God I truly believe it was a hacker that thought this up. So, you've got your camera taking your picture of your hand and someone said what happens if we put a mirror in there at 45 degrees then we can take a slice across the hand as long as it's in the field of vision of the camera and we suddenly get a 3D scanner. So, we now have the 3D scanner as you can see here, here's an image and now we're going to try and duplicate a credential for this and this is the credential and it's going to be entertaining. Well, if it works. Can I borrow you for a second please? No, don't try and pull the wire. Okay, we'll use another one. Excellent. Can we move it up just a little bit? Okay. So, here is my template. One of the things with biometric systems is that as well as security they sell you on the fact that it's identifying you. You as a person. No one else will get in. That employee that you want access to your high security area the great thing with biometric systems is it's only that person can get in. Well, we'll see if we can duplicate me. So, this is less of a hack and more of a recipe really. So, we're going to start off now this is going to get a little bit mad because the stuff we're playing with here is going to go from powder to liquid to solid in about 120 seconds flat. And if you notice we brought along his favourite stick which is ribbed for his pleasure. Okay. So, we've got a bit of a recipe here. So, first of all, take four pounds of chromatic dental alginate and add it to a bucket. Chromatic dental alginate is fantastic stuff. The first line in the instructions say chromatic dental alginate has a pleasant dentist waiting room smell. Notice I went for the one with the dentist waiting room smell. I didn't cheap out on you guys. I didn't get the dentist waiting room smell available separately. Okay. And then, now this is where it's going to get absolutely fucking crazy. Not to put a finer point on it. Mixing stick ready. Do you want me to help pour? Okay. Stand by. Okay. Now this is the secret sauce. It's the mould. Okay. Hold it. We're violet. I am happy with that. Do it. Ooh. Okay. Yeah. Right on. Keep going. Okay. This is where I've just you just get me to stand very still for a couple of minutes. Major. Major. Okay. See that there? No. That mousy thing. Flip it over. That one. Yep. So, we start thoroughly and we try to avoid bubbles. Keep going. And we added three pounds of meat to the mould. So, I'm going to let Major. Beep. Clicky clicky. So, we added the dental alginate over the meat. And now it's beginning to get hard. Okay. Oh, yeah. Okay. We will be offering a service afterwards if you want something moulded. Click click. Okay. So, we're going to let it marinate for a couple of minutes. Now, yes. I can't really do anything now. So, yeah. Don't even think about it. Okay. So, this credential is not supposed to be duplicatable. And if you think God. I want to break into that telco. But, hey. How am I going to get the guy to stand around with his hand and a bucket of alginate? The thing is you're not. But, you've got the other part of it which is this is supposed to be unique to me. So, I'm having dinner with the chief of police. Yeah. Yeah. I think we've done it. I think it's as hard as it's going to get. Okay. Can I have the compressed air, please? Okay. Thank you. Okay. Now, that was part one. A little bit of dry stuff came out, but we'll see. Okay. Now, here's the key thing about this mole. We do have a couple of bubbles, but we'll see how it goes. Right. Now comes step two. Oh, yeah. Step two. So, what we're going to do is we're going to mix up some vinyl polysiloxane. Also known as silicon rubber to you guys. This stuff is fabulous. Most silicon rubber takes 24 hours to cure. This is going to go from liquid to solid in 20 minutes. Possibly sooner because it's a bit warm. So, we're adding our silicon base and we're going to add our the...actually that was the catalyst and now we're adding the base. And then he's going to stir it. Now, silicon tends to be a bit of a pain in the arse. And you normally need a big vacuum chamber and you need to vacuum it to get all the bubbles out of it to set. This stuff's pretty cool. You don't need to do that. And it has a resolution of two micrometers. Right. Which is pretty fine. I don't know actually. The question was what's the resolution of the hand geometry scanner. And I don't know. Off the top of my head. I think we're going to leave the first question off. Actually. It is less rigorous. Then he's going to fall asleep. Bastard. Okay. Right. Whilst this is going on, are you almost stirred? Have you got all the white stuff off the bottom? Okay. So, in order to, again, to try and eliminate bubbles, I am just going to pour this very carefully in a very thin stream into the deepest part of the mold. Go for it. A bit higher. Oh, yeah. Alien green. So, yeah. One of the problems with biometrics, you're not really supposed to be able to do this. And with a lot of biometrics, as we've probably seen, and as I've spoken about before, not so great when it comes to this. I had a collision with one of my neighbors. I have several of these hand geometry scanners. And I was coming over here one summer and he was going to look after the house. And I'm like, okay, and just in case anything goes wrong with the power, you need to get into the plant room, so I need to register your hand with the hand geometry system. And that went okay. So I enrolled him. And I said, right, now you have a go. And I typed in, a code on the panel, or his code on the panel. And I said, right, put your hand in there. And he did. And it opened the door. And he said, yeah, you know that wasn't my code. So I put in my code, and he matched my template. And that's not so good. Especially when it's your next door neighbor. Fortunately, he's a nice guy. But, okay. So, one of the key things here, so let's just say I've tried this before. And one of the key things to getting this right was the mold. This mold's quite particular. It's got a series of rods. If you see it on the front, there's a scale picture of actually, can we bump it, Major? I we're just going to tap it to get the, to get any bubbles out. Harder. Okay. So, so the key thing here was making a cast of your hand isn't good enough. What you have to do is you have to get a cast of your hand and get it laid out exactly right. So, on the front here, there's a scale image of the platen of this hand geometry scanner. And drilled through the mold are holes and running through the holes are pegs exactly in the same dimension as the pegs on the platen. So, when this comes out, hopefully, if I wasn't too distracted talking to you and I got my hand position right, is my hand should be in exactly the same position as the hand geometry scanner expects to see it in. So, we're going to leave that for 20 minutes. And bloody hell. Okay, we're running late. Okay. Prepare for lightning talk. Okay. So, we're going to leave that to cook for 20 minutes and hopefully we should be able to demold it. And it should get access through code 123 on here. Okay. Now, the other problem with biometrics is how do you revoke your credential? Now, that's not so good. And when I come back into the UK these days, I actually use an iris scan system. So, I don't bother with my passport. I just walk in, look into their poor user interface, and I get a picture taken of my irises. This has slightly larger repercussions. Of course, being a UK government, they'll no doubt provide me with a handy kit. But the real issue is what happens when you have to revoke your credential. Okay. So, while this is cooking, I are setting. We're going to have a little chat about some other credential technologies. We're going to talk briefly about the mag stripe card. Wigan cards, I'm not really going to cover. But I'm mentioning it. And we'll get into that a little bit later. And proximity cards. So, mag stripes. Everyone's got one in your pocket. Normally, they have about three tracks on the card. And there are two types, based on the amount of energy it takes to flip the bits on the card, effectively. Most of the cards in your pocket will be high coercivity cards, apart from your hotel keys, which are most likely to be local cards. And you can zap them with cell phones quite easily, so no surprises there. Some high security cards can simply mean just adjusting the offsetting of the tracks on the cards. But there's some other quite cool technology. You didn't think mag stripes could be secure. And I haven't had a really close look at these other technologies. A real good go at them, but hey, gotta start somewhere. So, they tend to use fingerprinting. So, one of them is it'll take an image of the entire mag stripe and try and work out where there's particular magnetic hotspots that were just natural when the magnetic slurry was laid down. There's an actual magnetic imprint which they lay down when they put the slurry down, which is permanent on the card and you can write data on and off the top of it. And what you tend to do is you tend to use that imprint, the data from the imprint on the slurry as part of a checksum for the data on the card. Some cards also use holograms on the actual mag stripe itself. And that's actually read with an optical reader. And some use IR coding as well on the stripe. So basically you're not really aware if it's there, but there's an IR code on the stripe that's read optically and then compared with the data on the card. And also people do jitter analysis. So basically they look at the wobbly signal that was laid down on the card in the first place and use that as a checksum. So this is where Codemonkey comes into play. Codemonkey has been writing code furiously for me which is quite nice and I have been building toys. So this is Jackson. And Jackson emulates a standard three track mag stripe card. There are three very tightly wound very thin coils and we have a driver circuit at the bottom that effectively emulates the actual data that's read off when you swipe your card. It's easier than you think. This guy here. So one of the big challenges with this was actually making the producers. And this little guy here complete Heath Robinson. What's the American version of Heath Robinson? No, no, no. The guy that makes all Yes, Rube Goldberg. We have in the UK, we've got a guy called Heath Robinson that makes shit like this or draws shit like this. And you've got Rube Goldberg. So this guy is ticking away and over about 40 minutes will wind one of these transducers. And it's actually allowed me to make several of them because if I had to do them by hand it just ain't going to happen. So you see the wire being spooled onto the former. Okay. Now when you use access control systems with MagStripe cards there's two ways of doing it. It either reads the data on your card such as the PAN, your account number and hashes that into, kind of muscles it into YGAND format or it directly writes YGAND data format onto one of the tracks. And this is it. 13 characters on the bitstream you've got 10 leading zeros, 10 trailing zeros and 15 characters giving you your site code and the card ID. Proximity cards. Now actually the actual circuitry involved in driving Jackson simply what happens and count zero back in the late 80s and 90s wrote pretty much the seminal work on MagStripes or certainly the MagStripes he had back in those days. And what actually happens a bit is a phase transition a north-south flip in the bitstream that's been laid down on the cards. So basically, you know north, north, north, south at that point that transition signals a bit. It's encoded with, is it F2F, Major? You miss your MagStripe? Sorry? F2F. Frequency twice, frequency. And Major did a talk years ago because he's quite old and he was doing a whole bunch of MagStripe stuff and one of the things he was doing is he was replaying MagStripes through a computer sound card and we took this just a bit further and actually built a complete digital device to do it. Now I was going to have the board attached, but I decided to do the whole Terminator 2 thing. It would be a bit sad, but hey it came out quite well so you can check it out later on in close up. Okay, so now we're going to talk about proximity cards. This is something I've been quite interested in in a while and finally we actually managed to get some traction on it. Again, simpler than you think. Standard proximity cards tend to be 125 kilohertz. Contactless smart cards operate in the 1356 megahertz range. So the reader, and I didn't actually bring one, emits an RF field that powers up the card and then the card sends its data back and the reader sends it back to the host system. There are active cards that will tend to be vehicle transponders that can be read from a good distance away and in general when they're energized they barf back a single bit stream so when the field hits the card the card goes to the tune of 540 bits to get its 26 bits across. In general lots of things like for example this system here the hand geometry scanner outputs 26 bits. It doesn't output anything more than that. So 26 bits and the access control industry is very much seen as a standard. And manufacturers will sell you your own site codes or formats if you want 10 minutes, thank you. Okay. Need to speed up here. So they'll sell you your own proprietary formats and that's just an extra layer of security. This is what happens when you undress a proximity card. In this case this card happened to be dipped in chloroform. You can do it with acetone however and that's been going on a lot certainly with the Mifare cards. Okay. So finding concealed detectors is easy. This is dead simple. It has three components. 33 turns around a regular soda can, a .1 microfarad capacitor and any red LED. Red because it tends to be driven with a lower voltage. And you can spot lit up detectors even when they're concealed behind walls. Okay. So we're going to move on to another proximity tag. In this case it's a unique tag and we'll discover it's not quite so unique. So in general these tags contain an 8-bit ID, byte ID. As all proximity tags they barf back a single ID when they're energized. Oh, and just so you know, somewhere at DEFCON there is a long range reader. And when you're within a couple of feet of this reader and you have a tag on you it's going to read the tag out of your pocket and it's going to take your photograph. So I'm trialing it this year and next year it just may well be on the wall of sheep. So you might want to think about your tinfoil wallets next year. Or at least having a card that is slightly more secure than my ID is 123, my ID is 123, my ID is 123. Okay. So this particular tag the UK police decided that they were having so many problems with grannies forgetting their alarm codes, they were going to mandate tags to disarm all burglar alarms that they were going to show up to. And that's kind of a poor idea. I'm like, can I have a code as well? And they're like, no. So that's great. Where do you put your proximity tag? Especially when it's one that looks like that. Oh, why? That looks like it's supposed to go on my keyring. So I walk out of the house, I drop my keys in front of my front door, they can break in and turn my alarm off. Great! And you were supposed to be reducing crime. How? Okay. So this is Chameleon. This is a very early version. And Chameleon emulates unique tags. Or this particular version does. And if you walk up to my house, this will disarm my alarm. Not as unique as the manufacturers like you to think. And a lot of these proximity tags can be quite simple. So that was V1. It's not a clone. As when it was pointed out to some manufacturers, they said, oh, you can't clone my card. That's not in the same format, physical format, as my token. It's like, yeah. It just happens to transmit exactly the same ID as the original tag. Multipass. Okay. This is... So that was V1. This is V8. And this is Chameleon Multipass. So what we have here is a bit more powerful device. It can handle more complex cards. It can handle multiple cards. And if I don't know if you guys can see this little silver thing with the blue tip. Any ideas? Hands up. Any ideas what that might be? Yeah, that's a Bluetooth chip. So if you pair with it, it says, hi, I'm Chameleon. What tag would you like me to emulate today? And as I said, Chameleon's a bit more sophisticated than version 8. The Multipass is a bit more sophisticated because it can actually do tags of a major security vendor that's around all the place. I'm not going to mention their names. It may have three letters in there. But yeah. I couldn't possibly say. Are we there? Are you sure it's not going to be chewy on the off side and soft in the middle? Okay. We didn't work at all. Let's check out where the hell we're going to put all this dental algebra. We're going to put it in that box. Okay. Right. Major is going to have a chunk fest. So yeah, Chameleon Multipass, it's, so other people have attacked this vendor's prox cards previously. And prox cards, now that's a very important thing because you should be able to pull it apart. Gently now. I'm going to let Chip Monkey do some work now. Don't squirt in his eye. He doesn't like that. It doesn't matter if you break the gunk because we only care about what's inside. Do you want some leverage? We're not gay, okay? We're British. Yeah, maybe I do want some leverage. Ooh. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . your site code, and you've been given a block of cards. What card number is in your pocket? Card number one. So all the ones, actually, rather than trying to brute force your card space, brute forces the site code space, which is only 256 site codes. So the chances are you can be in, and you're going to be in with admin rights. Okay, so thank you. So this is, we've moved away from the coil antenna and went for a nice little flat-edged one, shiny, shiny. So I'm going to finish up. Thank you very much to Major, CodeMonkey. Woz, who's my beautiful assistant, also including Major. And I'd like to thank Nick at Tomps, who managed to give us some direction on the super good silicon goop. So I hope you enjoyed it. Biometric systems, not unique. Take it easy. I'm Zach Franken, and I'll see you in the Q&A room. Take care.