start	end	text
1360	2320	Hello, everyone.
2320	8800	Welcome to keeping your distance, pwning RFID physical access controls from six feet and beyond.
9240	21320	Today we're going to discuss two methods that we used over the pandemic to conduct our red team assessments and cloning an RFID badge beyond that six foot barrier.
22400	24820	My name is Langston Clement.
24820	41240	I am a principal pen tester here at Core BTS, and I've been in the industry for about 15 years now, focusing primarily on RFID, hacking, wireless, and physical pen tests.
41640	43060	I'm Dan Goga.
43060	45740	I'm a penetration tester at Core BTS.
45740	52080	I've been in the industry for over five years now, and I focus on penetration tests and red team engagements.
53100	59300	So the question here is, how do you conduct a physical red team engagement during a pandemic?
59300	71960	Now, if you're familiar with doing red team engagements and physical pen tests, you know that a huge portion of that pen test is going to rely on social engineering people, right?
71960	81220	At the end of the day, your client still wants you to social engineer their employees to see if you can get in in a certain way, right?
81220	99500	So it's made it a little bit difficult because, you know, with the restrictions in place of having that six feet, you know, social distance policy that, you know, we are abiding by to make sure that we conducted this safely and that we could go through and actually,
99500	116790	you know, perform the pen test during this time period, you know, it made it a little bit more difficult because if you're familiar with RFID cloning, you know that you have to stay within, you know, a lot less than six feet to actually get close enough to clone someone's badge.
116790	129670	So that is, you know, the issue that we came across and, you know, came up with some fun creative ways that we want to share with you and for anybody to use on their red team engagements moving forward.
129950	139410	So Dan's going to talk about some of the, you know, what RFID cloning is in the first place, if you're unfamiliar with it, and then talk about the differences between the two.
140430	141110	Great.
141110	145230	So we'll briefly go through RFID cloning.
145230	152470	The purpose of this talk is not to go into the ins and outs of how RFID works and how to clone it.
152470	156650	However, it's essential we touch on this briefly.
156650	164830	So radio frequency identification technology or RFID is common in a lot of physical access control systems.
164830	175130	And it's become a very convenient way for building managers and managing organizations to provision access and revoke access with ease.
175130	186970	However, this convenience presents some vulnerabilities as RFID technology and credentials can be cloned under the right circumstances.
187290	199710	Now, when discussing RFID technology, it's important to note that there's typically two distinctions made, that being between low frequency and high frequency RFID.
199750	210330	So low frequency tends to be less secure and works over longer range, while high frequency RFID tends to be more secure and works over a shorter range.
210330	221690	Now, it's important to note that under the right circumstances and with the right tools, both low frequency and high frequency credentials can be cloned to gain access to a building.
222010	233890	So there are some traditional cloning methods that Dan's going to explain, and then we'll show you sort of how we adapted those for our Red Team engagements during this time.
235430	246550	So there are a few well-documented ways of cloning a badge on a Red Team engagement, two of them being the brush pass method and the clipboard cloner method.
246550	256350	With the brush pass method, you insert a rogue badge reader into a messenger bag and you approach someone, bump into them, or get close enough that you can get a badge read.
256350	266090	Now, it's a bit difficult to confirm you get a good read on the fly, and of course, this does not abide by COVID-19 policies.
266670	271050	Clipboard cloner method presents a better chance of getting a good read.
271050	277870	As you approach someone, you hover the badge directly over a concealed rogue badge reader and give it back to the user.
277970	282430	But of course, this also requires you to get within six feet of somebody.
282430	291770	So that led us to a point where we had to develop a way to get that badge credential, get that read on a credential, while staying six feet apart.
293730	301610	So what we did, you know, is sort of come up with two different ways of doing this.
301610	307970	So Dan's going to explain the first one that we started going around the idea that was pretty successful.
309370	320730	So this led us to a point where we developed a way where we put a rogue badge on the next to a legitimate badge reader at the entrance point to the target location.
320790	337270	So we get a rogue badge reader, tape it on with some 3M tape, and accompany it with a message from presumably the building management with an organization's logo saying, hey, everybody, use this badge reader and not the legitimate one.
337270	357590	And the idea here is that as people approach the they see this sign and they present their badge to the rogue badge reader, see the door doesn't open, and then they just present it to a legitimate one and they get access to the building and we get their credential and they don't think twice about it.
360530	387110	So the great thing is, is that with a few modifications, this rogue badge reader can be modified with a Wi-Fi module known as the ESP RFID tool, where remotely from the parking lot with a long range antenna, you can connect to this Wi-Fi interface's web interface and remotely collect the information you need to clone the RFID credential.
387170	398310	So again, we are able to maintain social distance and we tend to get a much better and more reliable read when someone comes up directly and puts their badge right over the rogue badge reader.
400010	422070	So as you can see here, and as you'll see when you go through the process of setting this up on your own, the ESP RFID tool has a great web interface where it lists the exfiltrated data and with that all from the car, you take that hex value and you put it into your Proxmark and you clone a new badge.
424550	432130	So once you get that data, like Dan mentioned, you'll just see these collecting onto that sort of payload.
432130	437590	And that method, we actually used that pretty recently, a few months ago on a client.
437590	450630	And when we deployed it onto the side of the building, we were able to get around 17 badge reads onto that actual device before anybody figured out that something odd was going on.
450630	456230	At that point, we had already collected all the hex data that we needed to create as many badges as we wanted.
456230	466130	So if they actually figured out that somebody had touched their badge to the reader and they tried to reset that badge, we still had more that we could use.
466650	470370	So the wall reader build is very easy to do.
470370	474530	It's very entry level and it's a fun project to do over a weekend.
474650	479230	All you're going to need is an HID Prox Pro 5355A.
479230	488990	This older model works really well because you can access the screw-in terminals that you're going to need so that you don't need to do any soldering at all during this entire process.
489270	504210	So what you'll need to do is go ahead and grab one of those, get some LiPo batteries, a T-Tap connector, some wire to wire connections, and then some jumper board wires as well.
504210	506910	And then you should be good to go.
506910	510950	So all you need to do is take your ESP RFID tool.
510950	519510	You're going to screw in those wires into the one side of the terminal and take it over to your actual reader, which is the WeGand interface.
519510	524010	So this works directly and it's built for WeGand interfaces.
524010	529290	So you can use a various different types of companies out there.
529290	533330	If you get a used badge reader that has a WeGand interface, this works very well.
533350	538070	And then what you want to do is take your LiPo batteries and you're going to make a series connection.
538070	549130	The series connection is important because you're going to need enough juice to power both your ESP RFID tool and the Wi-Fi that it provides to you and to your actual badge reader.
549130	566970	Now for this implant reader, this one smaller one with these LiPo batteries, it lasts maybe a few hours, but you're only going to need really the morning time or you're going to need, you know, when people are actually coming into the office and then when people are actually going into the,
566970	570230	you know, like lunchtime or something like that.
570230	575070	So when there's actual foot traffic with the few people that are actually coming in and out of the office.
575250	581090	And so if you take a look at this, this is exactly what the wall reader should look like when you're complete.
581250	586770	I had run out of some white wire there, so I just used the blue wire, but the example is right there.
586770	597410	This is without the batteries plugged in, but it's nice because once the batteries are plugged in, it makes a nice little compact unit that you can throw 3M strips on the back.
597410	601030	Everything's enclosed and it's water protected as well.
601070	607250	And then you just slap that on the side of the building with a social engineering sign and you're good to go.
607450	615050	So one thing that happened when we actually deployed this the first time is that it was very odd.
615050	617610	We didn't understand what was going on.
617610	625410	And Dan's going to explain, you know, this sort of misdirection opportunity that we were provided with after we found out what it did.
626870	644750	So we discovered that when you place a rogue badge reader within about six inches to a legitimate badge reader, it presents a denial of service attack where the legitimate reader cannot read or authenticate any RFID credentials presented to it.
644750	652690	So we planted this rogue badge reader early in the morning before everyone got to the office and we put it within six inches.
652810	665790	And we observed as people presented their badges to a legitimate reader, they couldn't get access to the building and the security guard had to come open the door for them and they were granted access to the building.
665850	669550	So this presents a unique opportunity for us to tailgate.
669550	676050	Either A, we go in behind the person that can't get in and we say, oh, well, my badge doesn't work either.
676050	678470	Well, we don't even have a legitimate badge.
678490	691730	Or it directs people to a different entry point of the building where you can tailgate there too, of course, using the pretext of, oh, my badge reader didn't work at the front entrance and I have to use the back entrance like you.
692530	702730	So the second one that we toyed around with and thought was pretty interesting and worked really well is the gooseneck reader.
702730	715210	So if you take a look at this picture of this pedestal, the steel pedestal, what you'll see is that, you know, typically you'll see these at a parking garage, let's say, right?
715210	726710	Or restricted entrance of an area where they attach a long range reader to it so that someone can drive up with their car, wave their card, and it will let them in.
726710	732950	Now, typically these are cemented and there's drilled into the concrete.
733430	740050	So it'd be really hard for you to be stealthy to deploy one of these at one of the sites with a rogue reader.
740050	747410	So I thought it'd be really neat, what if we just take this pedestal and just attach it to a piece of wood and make it mobile?
747410	767150	And so it's a really simple yet effective way of creating a long range mobile reader that all you need is a piece of plywood, some rubber feet, spray paint, and this pedestal with your long range reader, and you instantly have a nice mobile reader.
767150	776190	Now, as you see in this picture, it, you know, sort of in the way it looks, it will sometimes just blend into the environment, right?
776190	781210	A lot of people just don't notice that there's something odd, some piece of equipment, right?
781210	782650	They don't even know what that is.
782650	788710	So sometimes they don't even alert, you know, someone about it, and they just think that's very strange.
789030	804370	The way it's sort of angled and it's, you know, right as soon as you walk out of the door, a lot of people that are, you know, next to that trash can, going for a smoke, leaving for lunch, it sort of sandwiches them, you know, as soon as they walk out that door,
804370	807490	they're going to make that angle so that they come right across.
807750	811190	And it makes it a nice, easy thing for you to do.
811270	817010	And this battery that's attached to it, it's like a 12-hour battery, so it's going to last all day long.
817010	821710	It's a very stable thing that you can just set it and forget it, and then remote in.
821710	825430	So yep, that's the Gooseneck Reader, R.I.P.
825430	826310	Goose.
826310	827530	Thanks, man.
827810	833010	So as you see, there are different heights of the Gooseneck Reader.
833410	846770	Typically, you know, the 36-inch height works the best because it will give you a different variance between someone wearing a badge on their hip and then someone wearing a badge around their neck.
846770	862270	And so what you'll, you know, sort of see as people walk past is that you'll be able to either get that within the range, or as they reach their badge up to hit their legitimate badge reader, it will, you know, brush past it automatically.
862270	868290	And again, you know, something that you just deploy in the field, you leave it there, and it does all the work for you.
868610	872230	So with the Gooseneck build, no soldering needed.
872230	879450	Again, it's going to be a very simple process to put this together, and you're going to need all these components.
879450	886790	Now, we're not going to talk about the step-by-step guide about building the actual base and attaching it all.
886790	894130	If you'd like to go see that, check out this link right here, github.com slash shocksec, and that's with a zero.
894130	899370	You'll be able to get there and look at all of the, you know, step-by-step guides.
899370	909650	You'll also see that there are templates so that if you want to, you know, you know, cut it out yourself or you need a reference guide, it is right there for you to download.
910130	915910	So once you get all that stuff together, you will do the same thing just like the wall reader.
915910	923850	You are going to set up a white and green wire for your data, and that's always going to be the case for any WGAN interface.
924050	936230	You're going to have a positive and a negative connection, and then you're also going to connect that pigtail, DC pigtail, directly to the WGAN interface.
936270	946730	And so as you plug those two in, it's going to power your large long-range reader and your, you know, ESP RFID tool so you can get Wi-Fi access and collect data.
946730	956090	So with the HID iClass SER90, as you see here in the picture, again, on the right-hand side, if you look at it, it's a very simple process.
956530	962370	Everything's labeled inside, so all you need to do is, you know, find your data wires.
962370	967410	You're going to connect that to your ESP key with the screw-in terminals using the screwdriver.
967410	969830	Same thing on the long-range reader.
969830	983030	And then you're going to attach that pigtail right there, and then you'll drill a little hole out the back of the reader and attach that nice large battery for you to collect all of your loot.
984390	987590	So the gooseneck base itself is very simple.
987590	997670	It's only a 16 by 16-inch piece of wood, and then you're going to throw some rubber feet on the bottom of it and use some carriage bolts to attach it.
997850	1022350	And when you do this and you actually sit it on top of your piece of wood, you want to make sure that when you're tracing the mounting holes that you're at least one inch and a quarter away from the edge of the piece of wood because it's going to counterbalance itself and it's going to make a nice weight distribution so that when you actually mount your reader,
1022350	1023730	it's going to lean forward.
1023730	1025150	Everything is perfect.
1025250	1027010	I've tested this a lot.
1027010	1032030	It's very stable, and you're not going to have to worry about it falling on a client or anything like that.
1032030	1033970	It just works really well.
1033970	1037670	So trace out those holes, drill your holes, spray paint it.
1037670	1038490	It's very simple.
1038490	1043290	Throw some rubber feet on the bottom and then attach your carriage bolts underneath.
1043910	1049130	And as you see there, you can put a piece of Velcro on the back of the battery and you can stick it on the back.
1049130	1051350	It makes it look nice and clean.
1051630	1055170	And then as you see on the right, it's going to be your final product.
1055690	1064830	And to the point of stability, you see in this picture, we actually sat this on a pile of rocks and nothing happened to it.
1064830	1065950	It stayed there.
1065950	1074110	But again, you're able to deploy it near a smoking station or something where people are going to come in and out of the building.
1074110	1085310	And as they brush past their key fob or their actual badge, it's going to go through and it's going to collect that data.
1087370	1096930	So again, the use case for the Gooseneck is applied similarly to the Rogue badge reader strapped directly to the building.
1096930	1107530	We implant it early in the morning and then with a long range antenna reader, we're able to access the data similarly through the ESP RFID tool and clone it in the car.
1108910	1109610	All right.
1109610	1119970	So the best way of going about this that I found while we're out in sight, you don't really want to have your laptop out with your Proxmark and wires going from it.
1119970	1124510	It's a much more stealthy approach if you actually can clone it with a mobile phone.
1124510	1131310	So I'm going to show you the quick and easy way to do this and the cheapest way to do this while you're on site.
1131310	1141670	So what you'll need is to grab your favorite Android phone or tablet, grab a Proxmark 3 Easy, which is around $60 to $70.
1141670	1142710	That's the cheaper option.
1142710	1148570	The Proxmark 3 RDP4, highly recommend, amazing tool by Iceman.
1148570	1149650	Go ahead and grab that.
1149650	1152750	It's a lot more expensive, but it's worth it.
1152950	1157610	Get a on-the-go cable and then download the Nprox mobile app.
1157610	1158610	It's on GitHub.
1158730	1163930	There's no root required, so you don't need to know anything about reading an Android phone.
1163950	1171790	And then all you need to do is, as a bonus, if you'd like, grab this 3D file and 3D print your own case.
1171890	1178050	Because as you see in the right-hand corner, that, you know, Proxmark 3 Easy, it's got all the wires exposed.
1178150	1182930	It looks a little odd, so if you stick this on the back of your phone, people, you know, might draw attention to you.
1182950	1185190	Probably don't want to do that, right?
1185230	1194490	So if you put all that stuff together... Dan, you want to explain how you even remind people how you get that hex code in the first place?
1194490	1195630	Definitely.
1195630	1211290	So with this arrangement, we again access the ESP RFID tool and we refresh it, get that new hex value, and with Nprox, instead of just the Proxmark, we're able to clone the badge.
1211650	1229630	And through this Easy interface, and then of course in the lower left, you can see that that cell phone with the Proxmark Easy is a lot more easy to carry and less conspicuous than a laptop and a Proxmark RD4.
1230670	1240610	Yeah, so once you do that and you set up your nice little, you know, Nprox app, you plug in the antenna, you're going to run a simple command.
1240610	1245310	In this case, we're going to clone an HID badge, low frequency.
1245530	1254190	And so you just type lf hid clone and insert your hex code that you got from that ESP RFID loop page.
1254230	1257570	So once you copy that over, you just type it in there.
1257570	1264710	So in this case, we're going to type lf hid clone, we enter our hex code, and then it's just going to say done on the screen.
1264710	1266730	It's very quick and easy.
1266730	1271290	And then you type lf search, and then it's going to verify your card data.
1271290	1282810	So once you see it, it'll tell you that, you know, this is the HID Prox tag ID, give you that hex code back, it'll give you the facility code and the card number, and it says it's found.
1282810	1286250	So once you're done with that, you're good to go.
1286250	1289330	Just walk up to that door and let yourself into the building.
1289330	1298410	So those are the two methods that we've used over the pandemic that have been very successful for us, you know, cloning badges from a distance.
1298410	1313050	And it's been a lot of fun sort of just sitting back, letting those devices do all the work for us, and then, you know, showing the client later that, you know, either somebody noticed that these devices are, you know, deployed in the field, or that no one even noticed them in the first place.
1313070	1317370	So we encourage you all to build these and have a lot of fun with them.
1319150	1333710	So we just want to give shout outs to everybody that's listed here in our references, because a lot of these people, you know, inspired and helped actually build, you know, some of these tools.
1333850	1338970	Corey Harding with the actual ESP RFID tool, and there's some really great guides.
1338970	1347510	So if you're very interested in this and you want to get a little bit deeper dive, highly recommend checking out all of these references here.
1347670	1350970	This is also listed in the GitHub tutorial.
1350970	1358790	So if you need to go to the links, go over to GitHub slash shock stack, and you'll be able to get all of that information there.
1358990	1362810	So we appreciate everybody watching this video.
1362810	1369070	And, you know, we just want everybody to say, you know, have a happy DEF CON and enjoy.
1369850	1370730	Thanks.
1370730	1371830	Thanks so much.
