Hey everyone, how you doing out there? I am DeviantOlef. I am not particularly cool, but I get to do things that are cool. Specifically, many people in the hacker community and online know me as a lockpicker and a physical security person. I'm not going to lie, it's a cool gig. I get to break into buildings, that's my job and I get paid for it, but my knowledge in that area was pretty archaic for a very long time. Mechanical locks, safes, you name it, I'm there, I'm your guy. RFID and electronic access controls, however, that's the direction that a lot of things are moving, right? Using little boop-boop access cards. I didn't know a whole lot about that and I decided it was time to learn. If you've ever gotten interested in doing some RFID and credential hacking but you haven't learned yet either, well, how about I teach you what I've figured out so far and you can take it from there. Sound good? So when we're talking about electronic credentials, what do we actually mean here? Well, again, a lot of you have seen buildings like this, right? You have an access control card or some kind of token, you present it to a reader, you hear a beep, the door unlocks, you get to go inside. What's going on when you use a reader like that? That's what we're going to dig into. And what if you want to use credentials like that maybe improperly or maybe do interesting things with them? Well, instead of using a conventional reader, you can use a reader like this. This device right here, we're going to use it a lot in this presentation. This is my Proxmark RFID hacking tool. I'm going to explain how it works, you're going to see some basic commands and capabilities, and if you want to get started later, I'll give you an overview of what you want to look for online. So this is a picture of me with what kind of credential is that? Can anyone guess? It's not a work badge. No, that's a hotel key. This is me dumping memory out of a hotel key so that I can make extra room keys for where I'm staying. I'm actually going to show you at the end of the talk how I copy my hotel keys, and it might be not exactly what you're expecting. All right, before we get too deep into the hardware though, let's talk about the actual technology driving it. Radio frequency identification, RFID. What exactly is going on? Is this like, you know, I can put on my Walkman and tune a radio station and I can, oh, I'm listening to the radio. No, it's nothing like that. RFID is a very small distance technology. It doesn't involve broadcasting from one element to another. Now, if you look at things that are part of an RFID system, you've got some kind of tag, some kind of reader, and you crack them open, you say, well, wait, there's there's an antenna inside the tag. There's an antenna inside the rear. Deviant, you told me that it's not broadcasting and receiving, but it sure looks like that to me. No, these antennas are not used for transmission of data. These antennas are used like your phone. If you do wireless charging of your phone, anybody ever do that with their devices? Right. Inductive coupling is what we're talking about here. So if you put a charge in one coil of wire and bring another coil of wire near it, that other coil of wire develops a charge. That's how wireless charging works. That's also how RFID communication works. The reason is because of that inductive coupling, right? You can send and receive signals. And again, they're not broadcast signals. It's actually communicating in a very interesting way. So I want you to imagine something. I want you to imagine you're kind of locked in a house and you can't go outside and, you know, you don't have Internet, you don't have phone, you don't have any real way of communicating with the outside world. What if you needed to send a message to someone else? This might sound a little hokey, but imagine the utility company providing you with your water. That water pipe leading to your house? Well, someone at the utility company is monitoring that water, right? They have to send you a bill. It might be slow data rate, but you could communicate with someone at the water company just by turning your water on and off. You could kind of send them Morse code because they're watching your water usage and then it goes down and then it goes up and then it goes down. This is how credentials communicate with an RFID reader. Remember that inductive coupling where the card itself, these credentials don't have any batteries. There's no power in this card. The only time they get power is when they go near the reader and that wakes them up. That's how they power up and wake up. What else do they do? They actually modulate their power draw. I'm going to pull more power and then less power and then more power and then less power. That's how RFID communication works between a credential and a reader. Modulating that power draw, it's like you're a person in a house turning your water on and off trying to get someone to listen to what you're saying way out at the power company or the water company. Now there's a couple of terms that get really confused and we need to just talk about this right away. RFID is what we're hacking on here today. How many of you have ever heard of NFC? Probably a lot of you. It's in your cell phones these days. If you have contactless payment or anything like that, boop boop boop, well that's NFC. Oh, my phone is NFC enabled. And some people don't quite understand. They say, well, RFID, that's like NFC, right? It's the thing in my phone? Kind of, but not exactly. Let's make a big diagram. RFID is any kind of inductive coupling based communication using a coil of wire and a reader and a coil of wire in a token of some kind. If you're inductively coupling and modulating your power draw to communicate, that's RFID. There's a lot of ways to do it, though. There's a lot of different implementations of RFID. The oldest that's been around forever is low-frequency RFID, often used for old-school access control or sometimes inventory tracking in a retro way. These are not really complicated devices. There's not a lot of power from the reader going into the credential, and the chip itself that's powering up can't do a whole lot. We're about to learn how very simple and rudimentary those chips are. Now, there's also high-frequency RFID. That's up in the megahertz range. You've got more power to the chips, more functions and features on that chip, a lot more you can do. Not going to get into it in this talk, but there's even ultra-high frequency, way up in the 900 megahertz range. These are not generally used for access control. This is where you see a lot more asset tracking, and if your luggage ever gets tracked by your airline and you get little alerts on your phone, they're using UHF RFID. So then we've got a whole chart here, but there's no NFC on it. Is the whole thing NFC? Is it just a different word? No. NFC is just one small subset of high-frequency RFID. It's a very small piece of the puzzle, but it's become ubiquitous in the marketplace, in the landscape, because it's what's in all of our phones. NFC is the direction most tech is moving. Many times you'll hear NFC referred to as contactless smart cards, because those chips support modern feature sets. So how is RFID typically used in access control environments if you want to get into a building? Well, think of it this way. A lot of really basic RFID, really simplistic old-school tech, it's nothing more than a folder. A folder that contains a piece of paper. Inside there's just a simple credential string, a simple bit of data that's here's who I am, and that's it. And this is not like a locked folder. There's no padlock on this. It's just a folder that anyone can look at, open, read the numbers, and then close it again. When you think about this in terms of access control, it's kind of crazy. It's like walking up to a building and just holding a piece of paper up, saying, hi, I work here. Can I come in, please? Am I authorized to be in this building? Here's a little scenario for you. I'm going to paint you a picture. And if you can imagine all these different players, right? So someone's going to come up to this building and they want to get in. That someone is an RFID credential. And they're about to talk to this guard at the door. That guard is the reader. The guard, you'll find out, doesn't make a lot of decisions. Those decisions are made in the building by the boss lady up here. The boss, she is the door controller. She has all the logic. She has all the command and control structures. She is in charge of unlocking the door hardware, the doorman there in red. So what's going to happen when all these pieces interact together? Well, let's step through it. The reader, first of all, is always looking to talk. The reader is always just offering power in a little bubble. It's offering energy to anyone that comes near it. Because again, if I bring a card near a reader, that card has to wake up. So the reader is always looking for credentials, saying, hello, is anyone there? Hello, hello, hello. And then if a credential shows up by the reader, what happens? Well, the credential gets power. It wakes up. And old school credentials only know how to do one thing. They just know how to show people, hi, this is my number, this is all I am, this is all I can do. And the reader is fine with that. In access control, you take that simple string of data, that's called the PACS payload, or the Physical Access Control System payload. You take that payload, and the reader doesn't know who you are. The reader on the wall doesn't know if you're authorized or not. It doesn't care. It's just going to take whatever you gave it and throw it up the wire to the door controller. It's the door controller's job to say, oh, let's see what this is. Is this person authorized this time of day, this building? Okay, yeah, they're authorized. Cool. And the door controller, the boss lady, she tells, okay, unlock, the door opens, let you in. That's access control in a nutshell. Now, when we think about this though, remember, those credentials, especially old school credentials, don't have a lot of protection to them. So we can clone and copy these credentials very easily. Let's talk about how that would work, right? Well, here we have our credential, right? Our credential sees a reader, wakes up, spits out its number, and hopes for the best. The thing is, these credentials don't know who they're talking to. They don't know if they're talking to a reader that's attached to a building or if they're talking to maybe an interception device. If I come along with something like my Proxmark device, remember, this can act like a reader. Well, my Proxmark device can offer power into the world and say, hello, who's there? Hello. And if I have a credential on it, that credential will wake up and say, oh, I'm in front of a reader. Here's who I am. Here's my number. And this card just doesn't know any better. This card doesn't have any logging capability or audit capability on it. If a person goes ahead, accesses a building where they belong, now what have I done? I've listened in on their credential data because they gave it to me. I can come along later, walk right up to that reader, and then I can replay that data. I can simulate being that credential. And if that credential is authorized to open up a building or open up a locked system, there you go. That's all you need to do. Would you like to see a demo of that? It's pretty straightforward and simple here. All right, let me fire up the Proxmark environment here. So this is actually a lock designed to hold a shotgun in a police car in America. Here's the credential that operates it. So if I pass it in front, boom, that opens up just fine, right? Well, what if I'm not presenting it to that reader? What if I present this credential to my Proxmark tool? And if I do a quick search function, low frequency search, what do we have here? Wow, look at that. We've got a whole bunch of data. Again, this card wakes up, spits out who it is, and says, okay, I'm done. And here we have up here, we have an EM style credential. EM is a credential made by the Swatch Group. Very popular use in kind of low cost access control systems. Once I have that unique ID, if I want to use a low frequency command, and we're working again with EM chipsets, this is an EM410 style system, which is a very popular EM chipset. So 410X. If I want to simulate a card, how would I simulate a card? EM410. Okay, so if this is my syntax, I just need to simulate the ID number, just plug the ID number right into the command, low frequency, EM tag, 410, simulate this ID, paste, boom, simulating, simulating, simulating. So what's happening now? This Proxmark is no longer acting as a reader. This Proxmark is now acting as the credential. It is pretending to be the credential. And if I bring it in front of the locker, there you go. Simple as that. Get yourself a shotgun out of a police car. Now, of course, this looks a little weird. I wouldn't want to walk around a police car and kind of like start pushing this into windows. This looks odd. It would look a lot better if I wanted to steal something out of a building on a test that I'm doing, if I could be carrying a little white card like this. So let's go ahead and do that. Let me take a blank card that I can put on my reader here. Now, if we want to check and see what is on this card, search for it. Nope, no tags found, nothing found. All right, but we do have a reprogrammable chip. Okay, so instead of running that simulate command, what if I want to clone that badge data onto a blank card? Well, let's see if we have a nice little clone command. Sure enough, I do. And what does it want? It just wants the unique ID. All right, let's go to clone, unique ID. There's our badge data. We'll put this right on the proxmark. All right, tag written. Let's see if that works. Instead of walking around with my laptop trying to unlock a police car, what if I just have a little innocuous white tag? Doesn't look like anything special, does it? But what does it do? Works just like the original tag would, because whatever was on this tag, we've copied it now onto this one. So that's the kind of thing you can do with a tool like this. RFID hacking tools are really common on the marketplace. And if you want to clone simple credentials like the ones you see here, you don't need something as high-tech as the proxmark at first. There are a lot of really cheap tools that are on the market. The famous blue cloner. It looks like this little fist gun. There's a different one that has a little more verbose display on it. But these cloners are out there. You can do a lot of these attacks on the low-end credential technologies, low-frequency technologies, older technologies, with pretty cheap hardware. But I'm not gonna lie, the standard of the industry is the proxmark3. What is the proxmark? Where's the history? If there was a proxmark2, was there a proxmark1? Yeah! The original proxmark was made by someone named Jonathan Westhues, and it was made as a student project just to demonstrate when RFID was becoming on the market really new, and companies like Texas Instrument and others were saying, oh, this is super secure. No one could ever clone our technology. It's brand new. It's impenetrable. Jonathan Westhues said, that kind of looks pretty easy to do, actually. I see how you're doing inductive coupling. I could do that. So this is the original proxmark, and it went through revisions over the years. He released a second version of the project and started publishing more, but really it came into its own, and the hacker world got a hold of it when Jonathan Westhues gave it to everyone in the community. He open-sourced it in the proxmark3, and there started to become kits where people could buy the parts, solder the board, they would actually hand wind their own antennas, actually tuning the copper. Eventually, enough people liked this technology, and RFID became so common, and hacking on it became so typical, that people started making ready-made kits. They were commercial antennas, the boards were pre-populated, but again, it was all still the original proxmark3 code that people were working on as open source at this point. We started to see the hardware being repackaged, so Elekhaus released the RDV2, which was like these nice integrated antennas, very well tuned, you didn't have to fudge around with weird chunky antennas anymore. Then you have companies making like the proxmark3 Easy, or the proxmark3 Evo. These weren't as good. They were trying to maintain that proxmark3 name, but honestly cut in a lot of corners. Frankly, it looked like the was going to kind of really go in some bad directions, until really amazing people, principally Iceman and some others from the RFID research group, manufactured the RDV4. They designed a complete revamp of the hardware package, and they've been rewriting the code base as well for years. This is a really gorgeous unit at this point. There's really nothing else like it on the research. Now there is, of course, a software component. You see that I'm tethered to a laptop. You can run a proxmark in standalone mode with a little battery. It doesn't have true functionality unless you're connected to an actual software environment, the client application that controls the proxmark itself. You can run it on Windows, you can run it on Mac, you can run it on Unix, you can even run it on your phone nowadays with a little Bluetooth module, which my proxmark has. That's why it looks a little different and extra blinky. Now that's not the only tool on the market if you're doing RFID hacking and attack like we do in the field, right? So if you've ever seen a long-range RFID reader, you know, we're not talking again, it's not broadcast, but if you've ever seen a parking garage where they have a reader that you can be a foot or two away from, this is called the huntpad. We weaponize these long-range readers, and you can be about half a meter away and still get a credential grab out of someone. This is what it looks like in the field if we're trying to grab someone's credential to break in a building later. Here's a colleague of ours named Dennis, and he's going to sit down, and in his backpack, he's got that huntpad. So he looks like a person, oh, I'm just checking my messages. Oh, you're here? Oh, I'll come meet you. But what happened? Well, the gentleman next to him had a credential in their pocket, and then Dennis was able to grab that credential without getting that close to him. So there are a lot of ways we can use this in the field. We do this all the time, trying to break into buildings. I'll get near employees on trains. I'll get next to an employee in a restaurant. I will get near someone when they're out there, most vulnerable. And if I have my backpack or my laptop bag, and it's got a huntpad in it, I can grab that credential, and then we can recode it, rewrite it, simulate it, clone it, play it back later. Now, some credentials try to anticipate this, right? There are some technologies where they say, well, that RFID thing, it's not that secure. If you get near the card, it'll just release its information. Well, what we're going to do, if you want to secure technology, our card is better because we scramble all the data on the card, and it makes it hard to copy. Let's think about that for a second. The credential reader wants credential information, right? And if you have their special brand of credential reader, well, it knows how to de-scramble the card. Here's a credential, and it talks really funny. It says, hi, my number ends with 47, and my facility is 16, and my code starts with 33. That's kind of a dumb way to communicate, but the reader's like, okay, sure, I understand what you're doing here. The reader fixes it, and then passes that PAX payload up to the boss, and the door controller sees it as a regular credential string, and unlocks the door if they're authorized. Now, that's the whole idea of the security of this scrambled card. They say, well, you need the special reader, and without the special reader, which we sell, you know, that company says, well, you got to buy our reader because it understands the scramble pattern. However, let's think about this. Do I have to understand someone's language if all I want to do is replay what they're saying? What if I just put a tape recorder up to someone who's speaking, and I played that tape recorder later? I don't have to know what the language is if I can copy it all in one raw dump. Remember that guy? We said a guy holds up his... Hi, I'm this person. Can you let me in the building? What if that paper has something funny on it that I can't read? I don't understand. What if it's in symbols? I have no idea what this paper says. You know what I can still do? I can still put that paper in a photocopying machine and make a duplicate of it. I don't have to care what it says as long as the reader on the building understands what it says. That works just fine for me. Let's look at some scrambled data and talk about copying that data. So here we have a different type of credential. This is old, old tech, by the way. Motorola originally made this scrambled kind of card. They called it Indala. Indala's been around forever. It's actually been acquired by HID, the corporation. Motorola doesn't make it anymore. But if we did a quick search on our Proxmark tool, what do we have? Oh, there we go. Look, we've got some data out of this card. And the Proxmark is even smart enough to say that that looks like Indala. And now the Proxmark will try to de-scramble it. It'll say, I think this could be the internal ID. I mean, this is probably the card number and facility code. But none of that really matters to me. I can look at this big string. That's the raw dump. This raw card data, as long as I've got that, if I want to take one of those special blank cards, if I want to clone an Indala credential, LF Indala clone, what do I need? Do I need all the de-scramble patterns? Not if I don't want to. There is a dash R. There's a raw switch. What does that do? You can just throw raw bytes and shove them back into this card here. So what are we going to do? All right, LF Indala clone, and we're going to go raw mode. I don't care about the scramble. I'm just going to shove all those bytes right back into this other card. Preparing, block written, done. Now this card should be the same as this card. Let's check them out and see. Here was our original card. Let's search for that. Okay, there's our Indala output. What about the card we just copied? If I search for that, there's our Indala output. I don't know about you, that looks like the exact same card to me. And in fact it is. If a building was using Indala credentials, I can absolutely walk up to the door, present my new copied card, and these are indistinguishable to the reader and to the access control door controller on the inside. So that's how RFID kept evolving over the years. New ideas, new ways of packaging the data and scrambling the data and formatting the data. They were evolving all the time, but ultimately it's still just inductive coupling with a little RFID chip. So how many different types of credentials are there on the market now? Well, let's look at a couple of categories here. Let's look at low frequency and high frequency. That's what we said we're going to talk about today. There's a lot of each, I'm not going to lie, like a lot, a lot. But they all work the same way. They all just present some user data. Especially, let's talk about low frequency, right? If we want to simplify things, there's a couple of ways to break this down. On the low frequency side, first of all, there is one chip kind of to rule them all if you want to hack on these systems. And you've been seeing it as I've been writing cards on my Proxmark here. This little Atmel card. What is this? What is the T5577? What's going on there? This is a chip that can be reprogrammed to act like all kinds of other RFID credentials. This is part of the Atmel data sheet. Atmel is now Microchip Corporation. So you can see this is a configuration block that we can program using the Proxmark. And you can program all kinds of switches on this chip. You can change it to be Manchester encoding or phase shift keying or frequency shift keying. Anybody who does RF work, you understand there's a lot of different ways to format data. You can package the data scrambled or not scrambled or reversed or raw. This chip can pretend to be all kinds of different credentials. It's, you know, I can reprogram this card over and over. I can pretend to be a HID Prox credential from the HID Corporation. I can pretend to be Motorola's Indala. You just saw that happen. I can pretend to be another type of technology called Ioprox by Cantech, right? I can be an EM credential. That's what we saw when I opened up the shotgun lock. Applied wireless, Jablatron, Farpoint, Pyramid, the list goes on and on and on. This one card can pretend to be tons of different PAX type credentials, different low frequency physical access control credentials, even really outdated ones that no one uses anymore. It can be all those. Well, that sounds cool, right? Like, is this a hacker tool? Is like, did Atmel make this just for hackers who want to do RFID attacks? No, it's not that cool of a history. The reason this chip exists, and there's a family of these chips, right? There's the older generation that, in fact, Temec made the Q5, the T5555, and then there was the 5557, the 5567. The 5577 is one of the latest generations of a chip the industry uses to make up for the fact that some things are just archaic in the marketplace. Remember I said Indala used to be made by who? Motorola. Motorola sold this back in 2003 to HID. The Motorola factory is not making more Indala chips. They are out of that game. But HID still has customers, right? HID still needs to service these old installs. That's where Atmel came in. Atmel said, hey, you've got a really old chip. You've got Visa 2000. You've got Honeywell, Nexkey, Guardall. You can still support your old customers. Just use our chip and reprogram it as you need. Well, the industry uses it for legitimate purposes. We can use it for really cool hacking purposes because, again, this chip is meant to act like all the other LF credentials on the market that you've probably ever heard of. So now you might be saying to yourself, neat, that's awesome. Are high frequency tags just as simple? Like, this is a high frequency tag that I've got here on this little key fob. Is it just as... is there one special card that can copy all of these? Not exactly. So on the high frequency side, tech has gotten better, right? We do have more power coming out of the reader. As the megahertz, the clock frequency, there's more waves of energy coming out of the reader. So these chips can actually use more energy to perform more advanced functions. Because of this, there's a whole lot of work the industry has been doing to implement secure features, to implement encrypted sectors, to implement key exchange. They're often called contactless smart cards in many instances. But there are data standards now. There are working group standards that have been put out. And you'll actually see, you can read data sheets, you can understand the commands that you use to interact with these cards. They're not hidden in secrecy the way they used to be on the old obscure low frequency tech. Now there are different types of NFC and contactless smart cards. For the most part, you're usually dealing with type 2 and type 4 in a lot of kind of phone situations. Sometimes type 5 for some access control things. Type 5 is no longer supported by smartphones. Apple killed support for 15693. But let's break it down a little bit. Why is this better? Why is this supposedly more secure? Well, when you have more energy to play with, the credentials can actually use locking and unlocking of different sectors. There are segments of memory on these credentials that need to be unlocked with a key in high secure environments. How is that implemented? Well, you know that guy who says, here's my credential, here's my paperwork, can I be let in? Imagine taking that piece of paper, and instead of just showing it to anyone who walks by, you put that piece of paper in an envelope. And then you put that envelope in a secured banker's bag. And then you put that zippered locked bag in a safe. And that's how you transport your credential around. That's a much better way of going about security, right? So if you have a secure building, you still have a reader. The reader is looking to talk. Hello, hello, is anyone there? Hello. And now a high frequency credential comes up with secure segments of memory. It will still introduce itself. It'll say, hi, you know, I'm Susan. This is my unique identifier. But that's not the security token. To do security, this credential goes, hmm, can I trust you or not? And they do a little exchange. The chair is against the wall. John has a long mustache. Let's do a secret handshake. Okay. Now the credential says, okay, I'm unlocked. I trust you. Then it will unlock and offer that PAX payload, that credential data that is important for the access control system. The reader passes that along. The boss lady looks at it and says, oh yeah, this user? Cool. They're authorized. Go ahead. Open that door. And the door unlocks. That's the way it's supposed to be done in high frequency environments. How secure is this process really though? When done correctly, it's pretty good. I'm not saying that the encryption hasn't been broken on certain technologies. There are a lot of credentials out there where the master keys are known and the implementation of the encryption was weak and has been broken by hackers. But let's say you have a brand new technology right off the line that hasn't been broken yet. Is it a hundred percent secure? Well, it depends how it's being implemented. Let's look at a memory dump from a credential. This is an actual dump of sectors of memory from an unlocked high frequency card. Now that first block, block zero, remember when the card first wakes up, it does introduce itself. It says, hi, you know, I'm Susan. You a unique identifier called a chip serial number and some manufacturer data that identifies what type of card it is. That's public. That's not encrypted. Anytime you get near a reader, the card offers that as part of its initial handshake. But the rest of the memory on the card is potentially encrypted and all locked up. And you can't get to that memory unless you do the handshake correctly. And we can see on this particular memory dump, there's some interesting stuff in here. There's definitely PAX payload data. There's credential and access control data in some of these sectors. And those are the locked sectors, right? So how secure is this in the real world? Well, if you do it the right way, it's great. If you use that safe and you say, all right, you got to unlock the safe and unlock the bag and take the envelope out and pull out the paper. That's wonderful because that credential data is very well protected with an encrypted system. But what do you notice about this safe? There's that serial number right on the outside of it, right? Think of that as block zero. That is the first thing the card will present to people whenever you see it. That is not encrypted. That is not secured in any way. There are systems that use that as the security token. Let's see what it looks like if we want to just read a high frequency chip. What happens if I get near a high frequency card? HF search. All right, we're searching around. Oh, there we go. This card woke up. This little credential woke up and said, hi. And it gave me some information. Now, it's not a lot of good information, right? It just tells me this is my unique ID. This is the CSN or the chip serial number, the unique ID. And we have some manufacturer data. And the Proxmark tries to interpret what that is. Maybe it's a MyFairCard. I can tell you it's actually an NTAG NFC type credential. But I don't see the rest of the data on this card. I don't get to figure out what is contained in those locked sectors. The thing is, in many instances, I don't have to care. There are lots of technologies out there where they only use the CSN. This is really common in any kind of product where they advertise interoperability and compatibility with other systems, where they might say like this Samsung deadbolt. They say you can enroll new credentials. We ship you a few credentials. But if you want to use your student ID, if you want to use your work badge, if you want to get more credentials, you can enroll more credentials. Use your phone. Who cares? That's great. I love that you're helping people out there, Samsung. But do you think Samsung has spent the time to figure out how every one of those different high frequency credentials works and where it stores its security payload? And is it encrypted? Is it not? How do you do the key exchange? They don't have time for that. They want the user to have a smooth, seamless process. If I want to enroll my hotel key into my home deadbolt, why not? Sure, let it work. They do this by only caring about the CSN, the chip serial number. It's like this. If you have this building where the reader is looking to talk, a high security credential comes up to the reader and says, hello, I'm Susan. And this credential is ready to do that crypto exchange, right? Are you going to unlock the safe? Are you going to take out the piece of paper? And they say, okay, let's start handshake. The chair is against the wall. What's happening? This reader literally doesn't know what's happening. It doesn't know the encryption. It doesn't know what technology that is. And it doesn't care. It says, I got your name. Your name is Susan, right? All right, let me just tell the boss you're here. Hey, Susan's here. And because the system is set up to say, well, the CSN, the chip serial number is supposed to be a unique ID. That's probably fine for security, right? No one can change that. Sure. Susan, we know a Susan. There's only one Susan in the world. Let them in. Go ahead. What's the problem here? The problem is that you're not using any secure memory segments. You're not accessing any of the secure functions on the chip. You're just using the CSN as an authenticating token. You can clone that almost as easily. Again, I don't have to be a reader that has all kinds of crazy crypto functions. I don't have to know how to unlock this credential. If the credential immediately gives me its CSN the moment I see it, they might want to do a bunch of encryption. I don't care about the encryption. The credential says, well, I don't know how to talk to you, and it leaves. Do I have to do encryption if I walk up to this building? No. What's the building expecting? It's expecting just a little chip serial number. And I say, hi, yeah, guess what? I'm Susan. Why not? Consider me Susan. And is Susan authorized? Sure, Susan's authorized. In systems that want to be as smooth as possible as an operating experience, they're only relying on the unencrypted CSN. And they rely on it because they say, well, no one could... there's no way to change the CSN. It's not like I can rewrite that block zero on this token. It's burned in at the factory. Well, that doesn't mean I can't rewrite it on something else. Just because you're not supposed to be able to rewrite the CSN doesn't mean you can't. There are a lot of credentials out there now on the shady kind of places on the internet where it'll say block zero, changeable, UID, changeable, clonable cards. This is tech that's out there now for people who want to hack on RFID. So what we have here, this is a little NFC-enabled padlock, right? So if I want to unlock this, present the token, that works. But part of the functionality on this lock, they advertise it as, ooh, it's super extensible. If you have other credentials, you can enroll new credentials. So I've taken a card that didn't come with this lock, but I've decided to program it into the lock instead. All right. And that works as well. Cool. Now, do you think this technology is the same as these other technologies here? No, it just happens to have a high-frequency chip inside of it. And that means it has a CSN that'll spit out whenever you're near a reader. So if this padlock is operating in CSN mode only, let's go ahead and do a CSN cloning attack. So we had this right here, right? This was the serial number that spat out when we were scanning this tag. I can actually tell you that a lot of these systems don't even use the entire serial number. I'm just going to grab the beginning of it. And now we're going to use one of our reprogrammable cards. So here we have a magic card, sometimes called a magic reprogrammable MyFair card. So I'm going to say high-frequency. We're doing a MyFair credential here with set UID. And what I want to set it as? Well, I want to copy the UID that I know works. Old UID was 1234. That's going to be written over. New UID. Okay, this now has the same CSN, the same unique identifier, as this card. I haven't copied the rest of the credential, nothing of the card contents. I've only copied that UID, that CSN string. Let's see what happens. Green light, lock is open. And I know this sounds crazy, but that's how it works on a lot of these systems. Manufacturers want to put product in the marketplace that has maximum compatibility. So here we have a reader by RF Ideas. This is a high-frequency reader. It's, you know, it's sold as a super secure solution. And they even say, like, look, our reader is so awesome because it works with, look at all these technologies. Look at all these different high-frequency card types. There's like 20 cards here. How many does it support? Supports all of them. Awesome. How does it achieve that level of support? Because it's operating in CSN mode. All of these chips, yeah, it's just chip serial number, chip serial number. Does it support any secure memory unlocking? Yeah, with two. And one of them, by the way, Legic Prime is super broken and outdated now. German hackers broke it like 10 years ago. So this amazing solution that supports all these credentials, wow. But are you really supporting anything securely? Or are you just reading the unencrypted portion of a card that was never meant to perform a security role? Now, better standards are emerging. There are interoperability proposals. The LEAF standard is a good one if you want to research into this, where they're going to say, look, all credentials should try to store the credential payload in the same sector. And you should try to unlock it in this fashion. And this is how you manage keys. And this is how you interoperate between different systems. We're not there yet. So right now, if you buy a product and it advertises, oh, this can operate with all these different card types, be skeptical of it. Okay, so you want to start getting into this, you want to start doing some of these attacks, maybe getting a Proxmark or even a cheaper device that you're starting out just to learn about this, you're going to need blank credentials, right? You want to get some reprogrammable credentials to do some hacking, some cloning, some attacking. What are your options? Well, on the low frequency side of the house, we've talked about the T5577. That really is the gold standard now. And it's available in plenty of form factors. You can get cards, you can get little fobs, you can get it as stickers that go on your cell phone case or something. You can find them in all different shapes. For high frequency, for those NFC and other functions like that, remember, NFC is a pretty open standard. You can read the ISO standards, you can pick up reprogrammable tags. The NTAG family is one of the biggest ones. So you'll see NTAG 216 or NTAG 215 or NTAG 213. What's the difference there, by the way? Just memory size. The only difference is how much storage capacity is on the tag. They were all released at the exact same time by NXP. They have the same feature set. They have the same write endurance. The only difference is how much memory they have. So go ahead and get the 216s. You get the most space on the cards. But the really fancy stuff for the hacking of areas of the chip you're not supposed to be able to modify, that's where we get into those Magic cards, right? And there's different varieties out there. There's the old MyFair Classic, which is a very common type of credential that's a little outdated now. That's been around for a while, the Magic MyFair card. But they even have newer ones, Magic DesFire cards and so forth, where you can write that block zero. You can modify things you're not supposed to be able to modify. So this is all accessible stuff. Every new technology comes out and it's secure for a while, and then researchers and hackers learn how to break that implementation, and you've got to get to the next page. You've got to get to the next level. So if you want to learn more about this, if you want to do this kind of stuff, pick up some of these rewritable credentials and start trying it. By the way, I noticed this chart's not really to scale here. Those sticker dots are pretty tiny, right? They're smaller than the fobs. Let's fix that. Also, what's that at the end there? That's also not to scale. Let's fix that. You know what those are? Ever heard of these? That's right, those are implantable credentials. Those are biohacking implants that you can insert between the first and second metacarpal of your hand, or really anywhere on your body if you like, and they are T55 chips, or MagicMyFair chips, or NTAG216 chips, and I can speak with experience here because both my wife and I have these in our hands right now. We have had them injected, we've hacked on them, we've played with them, we've reprogrammed them, and we use them for all kinds of purposes, right? One time my wife, you know, wanted to get into a building. We had a copy of her ID written to her hand, so she was able to access wherever she needed to go in that facility without carrying cards around. What do I do most of the time? I don't go into high secure... well, sometimes on pen tests I will write a badge to my hand and then people can't figure out why I'm... how am I getting this building? You don't have a card on you. For the most part, I use it for hotel rooms. I like to crack the implementation of whatever security is on my hotel key, clone it, and write it to my hand, get myself in that room, and then I go to the next hotel. And again, they're rewritable, so I can erase my hand and I can rewrite it the next time I travel and write the hotel key for that door. So I think this is really neat stuff. If you want to get into that, well, look for a talk at the DEF CON this summer in the U.S. where we hope to talk about this for biohacking and implantables. But all of these chips, they are really well known and they're understood by the hacker community now who are developing these toolkits and these different ways of interacting with them. If you want to learn more about this kind of technology, if you're excited about this, couple of names I'm going to give you. Babak Javadi, one of my longest time friends, one of my business partners, great guy in the access control space, and our colleague Iceman, right? So Christian Ehrman, this gentleman, he is responsible, again, for much of the RFID research group's project work. He's responsible for the design of the new Proxmark. And he runs a Discord. There is an open Discord server. Anyone can join, anyone who wants to learn about this. It's a wonderful community of hackers that just share information. They say, hey, I've got this new chip. I don't know what it is. I think it's low frequency. How do I decode it? And people would start jumping in and say, well, let's try this. Try these commands. And someone else says, oh, those commands need to be rewritten. And the open source Proxmark gets, the code base gets updated all the time. These are the people doing it. This is the community that is right on the bleeding edge of this technology. And if you want to join us, we want to see you with us. Again, I was never the cool kid. But when I hang out with these guys, I feel like I can do cool stuff sometimes. And I guarantee you can too.