WEBVTT

00:00.000 --> 00:01.660
And it's now the top of the hour.

00:01.660 --> 00:03.560
It is 4 o'clock p.m.

00:03.560 --> 00:06.040
in Las Vegas at DEF CON 33.

00:06.040 --> 00:06.700
Welcome.

00:07.400 --> 00:16.720
And it's my honor to introduce to you the speaker and a partner in crime, Ryan Mitchell, to talk about SSH Honeypots.

00:20.360 --> 00:21.780
All right.

00:22.480 --> 00:23.460
Hi.

00:23.480 --> 00:33.880
So I'm Ryan Mitchell, and I'm here to talk about my two favorite things, besides, I guess, my family, which is SSH Honeypots and walkthrough workshops at the Hacking Village.

00:34.040 --> 00:44.080
So I realized that the word honeypot could refer to a great many things here at DEF CON, but for the purposes of this talk, unless specified otherwise, honeypot refers to an SSH honeypot.

00:44.540 --> 00:46.500
So a little bit about me.

00:46.500 --> 00:48.940
I'm not a networking or an IT person.

00:48.940 --> 00:55.560
I'm a software engineer, and I've done this, nothing else, nothing but software engineering basically my whole career, including high school jobs.

00:55.560 --> 01:01.580
So I have a vague sense of what packets are, but I like to joke that I have people to handle those for me.

01:01.880 --> 01:07.540
And this is relevant for the talk, so that's the perspective I'm coming at this with.

01:07.600 --> 01:11.400
I also use the handle Klugeist at the Packet Hacking Village.

01:11.420 --> 01:13.240
So go up there, ask for Klugeist.

01:13.240 --> 01:15.160
They may not know who Ryan is.

01:16.140 --> 01:18.660
So my work doesn't pay me to be here.

01:18.660 --> 01:20.640
I've been doing this for fun for a long time.

01:20.640 --> 01:23.380
I just buy my own tickets, take vacation from work.

01:23.440 --> 01:28.640
So I do want to take this opportunity for tax purposes to talk about two of my books.

01:28.640 --> 01:32.360
This is officially a promotional tour that I'm doing.

01:32.680 --> 01:35.920
So Unlocking Python and Web Scraping with Python.

01:36.120 --> 01:43.180
So Unlocking Python was released last spring, and it teaches Python from sort of CS foundations and programming culture.

01:43.300 --> 01:49.960
So I start with the history of C and Unix and go into information theory, how computers operate in memory.

01:49.980 --> 01:54.000
And then I do, then, after I've covered that, I do a Hello World.

01:54.840 --> 01:59.460
So it also ends with some chapters on some of the most well-known Python frameworks out there.

01:59.460 --> 02:01.840
So Flask, Django, Scrapy, Scikit-learn.

02:01.880 --> 02:04.820
It's kind of the Python book that I always wanted to exist.

02:04.820 --> 02:08.960
So if you're looking to learn Python or know someone who is, you might consider it.

02:09.080 --> 02:14.920
And I've also logged as many copies as I could, as Worlard saw, in my suitcase.

02:14.920 --> 02:16.400
It weighed about 100 pounds.

02:17.000 --> 02:20.140
So I will tell you how to win one for free later on.

02:21.280 --> 02:23.980
So Web Scraping with Python, pretty self-explanatory.

02:23.980 --> 02:26.640
The book just had its 10-year anniversary, which is pretty cool.

02:26.640 --> 02:28.220
And it's now in its third edition.

02:29.860 --> 02:35.300
And I also do LinkedIn learning courses, including the most popular Python course, which is Python Essential Training.

02:35.900 --> 02:42.900
So LinkedIn is a great resource for all sorts of things, especially if you're interested in Python or Django or data structures.

02:43.400 --> 02:46.260
Actually, data structures are probably my third favorite thing.

02:47.040 --> 02:47.580
All right.

02:47.580 --> 02:48.940
So thank you for your patience.

02:48.940 --> 02:50.980
That's the end of the mandatory IRS section.

02:50.980 --> 03:01.880
Now, on to the first part of this talk is going to be about sort of the history, my involvement with the Packet Hacking Village, PHV, and how I got there.

03:02.280 --> 03:06.300
How I became interested in SSH honeypots and why you should be, too.

03:06.540 --> 03:11.440
And then we're going to talk about the walkthrough workshops, sort of how they came about, how you can get involved in those.

03:11.540 --> 03:18.320
And then finally, we're going to talk about hacking cowry, cowry honeypots, but probably not in the way that you think.

03:19.700 --> 03:25.960
So for four glorious years, I enjoyed DEF CON like many of you here are doing.

03:26.040 --> 03:27.100
I walked around.

03:27.100 --> 03:28.180
I met new people.

03:28.180 --> 03:29.540
I saw things.

03:29.540 --> 03:31.460
I went from village to village.

03:31.680 --> 03:33.080
I went to parties.

03:33.080 --> 03:34.360
It was fantastic.

03:34.360 --> 03:42.680
Then in 2016, I was speaking at a conference in Texas with Daven Potts, also known as BSE and the PHV.

03:42.680 --> 03:44.120
There's a lot of acronyms.

03:44.480 --> 03:46.720
He actually runs the wall of sheep.

03:46.720 --> 03:48.780
So really cool guy.

03:49.480 --> 03:53.360
He runs the literal wall, I mean, like the things on the projector.

03:53.640 --> 04:04.060
So we were talking afterwards about DEF CON and he suggested that I give a talk at the packet hacking village about the intersection of web scraping and packet hacking.

04:04.740 --> 04:09.120
Which, I mean, it was a bonkers talk.

04:09.120 --> 04:20.060
There were a lot of illustrations and diagrams and ranting, but it was pretty well received and I had a blast and met everyone at the packet hacking village and it was a lot of fun.

04:20.760 --> 04:23.940
And that was the last time I ever ventured outside of the packet hacking village.

04:23.940 --> 04:26.220
I have been trapped there ever since.

04:26.220 --> 04:30.780
I have no idea what has happened in DEF CON in the last nine years.

04:30.800 --> 04:32.920
So this is my life now.

04:35.100 --> 04:41.720
So also in 2016, after my talk, I was hanging out at the PHV and I saw this strange entry on the wall of sheep.

04:42.120 --> 04:46.740
It was an IP address and it had its protocol listed as SSH.

04:46.740 --> 04:48.080
The user name was root.

04:48.080 --> 04:53.220
Now, the SSH protocol, by definition, does not go on the wall of sheep.

04:53.680 --> 04:55.100
It's a secure protocol.

04:55.100 --> 04:56.100
It shouldn't be there.

04:56.100 --> 04:58.060
So that was pretty weird.

04:58.320 --> 05:02.740
The password was obfuscated, but I think it was eight characters and started with P.

05:02.740 --> 05:14.240
So I logged in, hacked it, if you will, and I'm poking around the server and there's a little text file in the home directory, but that's not important right now.

05:14.240 --> 05:17.420
What's important is that I am root on some random server.

05:17.460 --> 05:18.440
Amazing.

05:19.340 --> 05:21.300
The base 64 file can wait.

05:21.300 --> 05:22.520
I do not care.

05:22.520 --> 05:25.800
The mystery text file had some base 64 garbage in it.

05:27.320 --> 05:35.840
I was poking around, looking at listing files, realized that it didn't have VI, which is fine.

05:35.840 --> 05:39.580
It also didn't have Emacs or nano or basically anything.

05:41.500 --> 05:49.540
I would poke at some files, see some files while listing it and then I would cat them and they didn't exist.

05:49.540 --> 05:51.860
It told me no such file.

05:52.180 --> 05:54.120
So that was bizarre.

05:54.960 --> 06:01.220
Now, all of you here are pretty smart and you've probably figured out already that I was in a honeypot.

06:01.460 --> 06:04.460
I figured this out eventually.

06:04.860 --> 06:09.440
I had never seen a honeypot before and it blew my mind.

06:09.440 --> 06:10.820
So I was nowhere near bash.

06:10.820 --> 06:12.480
I was not root at all.

06:12.480 --> 06:20.300
I was exchanging messages with a Python program that was sending strings back to me that looked like a bash prompt.

06:20.980 --> 06:28.500
To add insult to injury, this whole Python program was running under a low level user in a docker container.

06:28.740 --> 06:31.880
So never got anywhere near anything.

06:33.000 --> 06:41.080
So once I figured this out, I stopped getting distracted by the whole I am root thing and I started playing around with the challenge they had, that file in the root directory.

06:41.380 --> 06:48.200
So decoding the base 64 file gave me the credentials for another server and that server had a steganography challenge.

06:48.320 --> 06:51.360
Solving that gave me the credentials for a third server and so on.

06:52.240 --> 06:55.220
So I don't remember the challenges, the rest of the exact challenges.

06:55.220 --> 07:01.300
So this is the first honeypot and it's unfortunately run by someone who is sort of a persona non grata with a PHV these days.

07:01.300 --> 07:04.120
So I was not able to consult him for this talk.

07:04.160 --> 07:06.100
But it was very fun.

07:06.100 --> 07:07.540
I do remember that.

07:07.540 --> 07:13.160
Ton of fun little single page CS challenges and it was just a blast to do.

07:13.460 --> 07:15.040
Finally I got to the end.

07:15.200 --> 07:18.380
I told them the secret pass phrase and they were very excited.

07:18.380 --> 07:22.600
I was the first winner that weekend and actually I was the only winner.

07:22.600 --> 07:26.180
I was the only one who went through the honeypot and bothered to do that.

07:26.620 --> 07:31.860
So they ran around, put together a little prize bag, I got some t-shirts and it was just fantastic.

07:32.600 --> 07:36.380
So let's back up a little bit and talk about what this thing actually is.

07:36.380 --> 07:39.380
What are SSH honeypots and what is cowry?

07:39.680 --> 07:49.520
So an SSH honeypot is a program that is running on a server that often but not always purports to be different software than it actually is.

07:49.520 --> 07:59.020
So this thing says that it's bash or it might say that it's SQL or it might say, you know, whatever.

07:59.060 --> 08:04.300
But it's actually just a program that's sending you lines back to make it look like this thing.

08:05.080 --> 08:11.640
The most basic descriptor of a honeypot is whether it is low interaction, medium interaction or high interaction.

08:11.840 --> 08:19.000
So the low interaction honeypots typically support a wide variety of protocols but you can't really do anything with them.

08:19.840 --> 08:29.060
So supports SMB, FTP, HTTP, MySQL, TFTP, like all sorts of stuff.

08:29.740 --> 08:33.880
But basically you get a banner, you get the handshake, that's it.

08:33.880 --> 08:45.140
So if someone wants something with some actual interaction, maybe you want to look at how bad actors are acting inside a honeypot, you might want something like cowry.

08:46.020 --> 08:48.200
It only supports telnet and SSH.

08:48.200 --> 08:52.720
It's considered medium interaction but it does support a lot of bash commands.

08:53.280 --> 08:56.700
They also keep track of the files that are supposed to be on the server.

08:56.700 --> 08:58.940
So you can connect them to actual files.

08:58.940 --> 09:01.280
There's a file structure inside of it.

09:01.840 --> 09:05.260
So you can list the directory, you can cat and tell files.

09:05.260 --> 09:07.280
There are things to look at and interact with.

09:07.520 --> 09:13.260
So as you heard from my experience earlier though, it doesn't stand up to that much scrutiny.

09:13.680 --> 09:20.560
When someone talks about high interaction honeypots, typically they mean something with a real operating system at some level.

09:20.560 --> 09:25.400
You may surround it with a whole bunch of application stuff for monitoring and protection.

09:26.240 --> 09:28.680
And it's obviously going to be like a throwaway container.

09:28.800 --> 09:35.660
But it is probably going to be a real operating system that they are actually operating or interacting with at some point.

09:35.660 --> 09:37.220
It's going to be fundamentally real.

09:38.080 --> 09:40.740
There are a lot of honeypot options out there.

09:40.980 --> 09:43.700
I quickly became obsessed with cowry.

09:43.700 --> 09:48.480
It has a lot of really nice out of the box configuration features, excellent documentation.

09:49.380 --> 09:54.260
It's very useful for our purposes in the coming years in the packet hacking village.

09:54.260 --> 09:56.400
We use it for a lot of things.

09:57.380 --> 10:01.840
So 2018, we want to talk about the walkthrough workshops.

10:01.920 --> 10:10.080
2018, Riverside, the fearless leader of the packet hacking village, he wanted to introduce a new area called walkthrough workshops.

10:10.080 --> 10:13.620
And he said, Ryan, you should do cowry honeypots for the walkthrough workshops.

10:13.620 --> 10:14.860
You like honeypots.

10:15.280 --> 10:18.860
So teach people how to set these up and do something with them.

10:19.240 --> 10:24.600
And he teamed me up with Warlord, sitting in the front row there, and Catalyst to do this.

10:24.980 --> 10:30.100
Warlord, as you might suspect from the name, is in fact an IT director.

10:30.360 --> 10:33.800
And Catalyst is a very experienced network engineer.

10:33.940 --> 10:36.640
So Riverside really put together the A team with this one.

10:36.640 --> 10:41.300
I was on the keyboards and, you know, we were a band.

10:41.300 --> 10:45.180
It was fantastic to work with this team developing the walkthrough workshops.

10:49.580 --> 10:57.220
So, yeah, the first year, 2018, we got this tiny little area, sort of a little corner next to the DJ speakers.

10:57.220 --> 11:00.400
So it was loud and I had to shout over them a lot.

11:00.500 --> 11:05.400
We had ten chairs, ten laptops, a projector that was balanced on boxes or something.

11:05.900 --> 11:08.440
It was janky.

11:09.220 --> 11:17.820
So we wrote this fantastic step by step guide to installing Kauri, configuring SSH, adding fake files to the honeypot.

11:18.940 --> 11:20.560
We could modify the users.

11:20.560 --> 11:25.800
We showed people how to do all this stuff and how to build their sort of like realistic honeypot system.

11:26.140 --> 11:28.380
The tests went fantastically.

11:28.460 --> 11:31.380
We ran through the workshop over and over and over again.

11:31.380 --> 11:32.100
It was great.

11:32.100 --> 11:33.660
We tested it on site.

11:33.700 --> 11:34.400
Fantastic.

11:34.400 --> 11:36.060
Nothing could possibly go wrong.

11:36.160 --> 11:38.920
So on Friday, the doors to the village opened.

11:39.560 --> 11:47.580
And what happened around that time, as it often does, as it's happening right before I actually came into this talk, the DEF CON network goes down.

11:47.940 --> 11:54.880
And our very first users sit down in their chairs and they look at this lovely prepared PDF that we had slaved away on.

11:54.920 --> 11:57.380
And the first command was that.

11:57.920 --> 12:00.540
And did nothing.

12:00.820 --> 12:03.760
And then, you know, the network was kind of intermittent for a while.

12:03.760 --> 12:10.200
So basically the very first walkthrough workshop was people watching a pseudo apt get update.

12:11.100 --> 12:12.820
So we closed the doors.

12:12.820 --> 12:14.440
We went back to the drawing board.

12:14.560 --> 12:16.000
We built some infrastructure.

12:16.000 --> 12:18.320
We made Docker images that had Cowery preinstalled.

12:18.320 --> 12:19.380
We edited the PDFs.

12:19.380 --> 12:21.920
We trimmed out anything that needed to go out to the internet.

12:22.880 --> 12:24.480
We were ready to go again.

12:24.480 --> 12:27.720
So every hour on the hour, we refreshed the Docker images.

12:27.720 --> 12:28.800
We'd queue up people.

12:28.800 --> 12:30.860
All the seats were filled every hour.

12:31.380 --> 12:32.200
People loved it.

12:32.200 --> 12:33.380
They told their friends about it.

12:33.380 --> 12:34.920
We had to turn a bunch of people away.

12:34.920 --> 12:36.220
It was awesome.

12:37.060 --> 12:39.680
So 2019, we get more seats.

12:39.680 --> 12:40.880
We grew a little bit every year.

12:40.880 --> 12:46.560
We streamlined the workshop even more, clarified the directions, added things, removed things.

12:47.440 --> 12:51.220
We had special instructions on the side for people who had never used Linux before.

12:51.220 --> 12:54.000
So how to enter a command, how to copy paste.

12:54.260 --> 12:56.680
A lot of things that people needed help with.

12:56.920 --> 13:02.660
So the word doc got turned into a nice HTML page that people could use more easily.

13:03.060 --> 13:11.800
We had very, very, very clear instructions for adding files, adding users, working with the logging and Cowery replaying logs.

13:12.260 --> 13:14.520
Again, every seat was full every single time.

13:14.520 --> 13:16.440
There was huge demand for the walkthrough workshops.

13:16.440 --> 13:23.300
And for the next three years, DEF CON, the next three years of DEF CON, we run the workshops.

13:23.360 --> 13:25.660
It gets a little bit bigger every year.

13:26.840 --> 13:29.420
2022, we finally get our shit together.

13:29.420 --> 13:34.940
And we're like, isn't it weird that there's only one workshop in the walkthrough workshops?

13:36.060 --> 13:38.680
So we should probably have more than one workshop.

13:38.920 --> 13:40.780
So we bring some more people on board.

13:40.960 --> 13:42.920
Kraken built a password lab.

13:42.920 --> 13:44.180
So password cracking.

13:44.340 --> 13:48.640
Catalyst splits off and does a network OS walkthrough.

13:48.640 --> 13:53.520
And then we bring in someone named Bonus who does a build your own bot network.

13:53.800 --> 13:56.220
So attacking botnets against each other.

13:57.720 --> 13:59.140
This is a few years ago.

13:59.140 --> 14:00.660
I think in 2022.

14:02.000 --> 14:04.540
I did get their permission for these photos as well.

14:04.540 --> 14:07.440
So that's why they're like staring awkwardly at the camera there.

14:07.600 --> 14:08.820
This is just today.

14:08.820 --> 14:11.860
So we have more than 50 machines.

14:11.860 --> 14:15.180
All the workshops cycle continuously now rather than refreshing on the hour.

14:15.180 --> 14:17.000
So we can get a lot of people through.

14:18.140 --> 14:21.660
We have staff for crowd control, managing the lines.

14:21.660 --> 14:23.720
There's like a ticketing system to get in.

14:23.720 --> 14:24.600
It's pretty cool.

14:24.600 --> 14:25.700
People love it.

14:26.800 --> 14:32.040
So how do you make a workshop that appeals to all people?

14:32.400 --> 14:35.660
Because there are a wide variety of people at DEF CON.

14:35.900 --> 14:37.880
Some who are into biohacking.

14:37.880 --> 14:40.220
Some who are into software engineering like me.

14:40.220 --> 14:43.180
Some who only work with Ethernet.

14:44.700 --> 14:47.000
You know, it's not about how skilled they are.

14:47.000 --> 14:48.240
It's about what they're skilled in.

14:48.240 --> 14:52.660
So how do you make sure that everyone can sort of get something out of this?

14:52.680 --> 14:56.400
You teach something that's very specific and very niche.

14:56.400 --> 14:59.740
But you teach it in a very simple step by step way.

14:59.940 --> 15:07.060
So people who have no Linux or command line experience can learn a lot from this workshop and be able to get through it just fine.

15:07.060 --> 15:10.120
They learn something about interacting with the terminal.

15:10.380 --> 15:19.880
So people who are great at Linux and have a strong background in security and programming are also probably going to learn a lot from this workshop about using Cowery and managing it.

15:20.600 --> 15:25.340
Configuring a Cowery instance and why they might want to use the system at home or at work.

15:25.520 --> 15:31.020
So in order to do this, you really have to give exact copy paste commands for every step.

15:31.960 --> 15:41.280
So at one point, we even gave everyone their own unique username password for their Cowery server and we actually dynamically generated that password.

15:41.280 --> 15:48.720
We dynamically generated the HTML document that they were working off of so that we didn't even have like your password here.

15:48.720 --> 15:57.120
We put the actual password in there so that they could literally copy paste everything because you know people are going to copy your password here and put it in as their password.

15:59.080 --> 16:07.640
So the other thing is security might not be a big deal and I realize I'm saying this at DEF CON.

16:07.820 --> 16:13.420
What I mean by that is I think people get really paranoid about DEF CON sometimes.

16:14.200 --> 16:19.060
When we started, we had all these ideas about how to keep the physical machines secure.

16:19.060 --> 16:24.640
How to keep people from maliciously attacking their neighbor's honey pot and ruining the experience for other people.

16:25.300 --> 16:36.300
We had ideas about monitoring the screens and maybe we could have a central command console behind the NR zone so that we could see what everyone was doing all the time.

16:37.180 --> 16:41.040
Interestingly, it's never really been a problem.

16:41.140 --> 16:42.400
People want to learn.

16:42.400 --> 16:46.840
We have me and a lot of other staff and volunteers circulating watching the computers.

16:47.000 --> 16:49.880
People just really haven't tried to pull anything.

16:50.000 --> 16:52.440
So I'm not saying ignore security.

16:52.480 --> 16:56.660
In situations like this where the stakes are low, we can reformat everything.

16:56.660 --> 16:58.960
Worst case it's a little bit annoying.

16:59.660 --> 17:04.120
Maybe stop worrying so much about hackers and focus on making things fun and cool.

17:05.620 --> 17:09.200
Obviously the other one is don't rely on F CON internet.

17:11.060 --> 17:13.480
So, 2024.

17:14.420 --> 17:19.520
We had been running this workshop for six years now.

17:19.820 --> 17:25.200
And we decided it's kind of maybe time to mix it up a little bit.

17:25.200 --> 17:31.240
We had this finally tuned script that anyone can go through in 20 minutes with no Linux skills.

17:32.200 --> 17:36.220
Maybe people kind of want something else that's not honey pots.

17:36.700 --> 17:42.700
So appropriately, this image is generated by AI because that's what killed the honey pot.

17:42.700 --> 17:44.680
You can see the coffin doesn't make any sense.

17:44.680 --> 17:46.360
Is the jar melting?

17:46.480 --> 17:47.480
I don't know.

17:47.840 --> 17:50.120
How does the lid go on there?

17:50.120 --> 17:50.980
I don't know.

17:53.880 --> 18:01.080
So Ming and I who introduced me put together a pack of AI and that was very well received and very popular.

18:01.080 --> 18:02.020
I'm running it right now.

18:02.020 --> 18:03.760
I was running it right before this talk.

18:04.220 --> 18:08.560
But I know what the people want and need.

18:09.280 --> 18:10.540
It's honey pots.

18:11.020 --> 18:12.160
So here's why.

18:12.960 --> 18:16.460
So remember I told you about that first honey pot challenge that I stumbled on.

18:16.460 --> 18:18.160
The one with the programming challenge.

18:18.440 --> 18:23.180
So that was kind of my first exposure to the medium of SSH honey pots.

18:23.240 --> 18:25.640
I realized that you can actually do a lot with these.

18:25.640 --> 18:30.360
I couldn't get over this concept of fake servers that you can modify everything about.

18:30.360 --> 18:32.080
You can break the rules of bash.

18:32.080 --> 18:36.100
You can turn a server into Hogwarts with like a room of requirements or something.

18:36.460 --> 18:42.320
At this point I started asking myself, why can't all SSH honey pots be this fun?

18:42.320 --> 18:48.580
Why do they just sit there boring collecting malware samples and sad little bash logs for security researchers?

18:49.400 --> 18:53.980
So alongside the walk through workshops, I started developing some of these ideas.

18:54.020 --> 19:01.060
So in 2017, I worked with a team of a few other mostly networking nerds to develop the second honey pot challenge.

19:02.180 --> 19:07.280
So at this time, the honey pots were all tied together with a fun story line.

19:07.280 --> 19:09.480
So they weren't just discrete random CS challenges.

19:09.480 --> 19:10.740
They had a story line.

19:11.180 --> 19:12.140
It was a little contrived.

19:12.140 --> 19:16.860
But an evil corporation has an evil plan to steal water from Lake Tahoe.

19:16.900 --> 19:19.580
You have to find the secret memos and give them to the FBI.

19:19.580 --> 19:21.000
It was all very fun.

19:22.400 --> 19:30.060
Throughout the whole thing on every server, you would actually get kicked off at regular intervals and be unable to log back in for a few minutes.

19:30.880 --> 19:38.400
If you sat down at the wall of sheep, like physically in our area, we had this image of the security guy.

19:38.980 --> 19:42.960
So he would take frequent and very long coffee breaks, occasionally go to sleep.

19:43.080 --> 19:48.960
And while he was distracted, the server was open and you could log in and mess around and do whatever you wanted and solve the challenges.

19:49.000 --> 19:55.540
When he looked at his computer, and we gave you a fair bit of warning, he would start to crack his eyes open or something, everyone would get kicked off.

19:55.660 --> 19:56.920
Then you had a ban.

19:56.920 --> 19:59.880
The goal was to avoid the ban and be able to use the challenge.

20:00.260 --> 20:01.060
That was a lot of fun.

20:01.060 --> 20:03.540
We had people in our area staring at the projector.

20:04.540 --> 20:07.380
We also had a jump box that led to another server.

20:07.780 --> 20:10.960
But the server's IP address changed with the clock time.

20:11.260 --> 20:16.040
So if it was 1130 a.m., the IP address ended with 11.30.

20:16.100 --> 20:19.380
If it was 245, it ended with 2.45.

20:19.820 --> 20:22.640
So you had one minute on the machine each day.

20:22.660 --> 20:25.380
So it was very annoying.

20:25.580 --> 20:27.320
But that was a really fun one.

20:28.660 --> 20:31.260
And also the fact that I'm a software engineer is relevant.

20:31.260 --> 20:33.840
I remember I really wanted to do this challenge.

20:33.840 --> 20:36.260
I had this idea of like a brigadoon server.

20:37.700 --> 20:42.160
And they said we can't do it because we don't have enough IP addresses.

20:42.160 --> 20:44.160
We don't have the IP address space.

20:44.600 --> 20:54.340
And I said, well, is there a way you could go through another machine and get a whole new space of IP addresses just through that machine?

20:54.820 --> 20:56.580
And he said, like a router?

20:56.680 --> 20:57.740
I was like, yeah.

20:57.860 --> 20:59.460
Whatever you want to call it.

21:02.260 --> 21:03.280
So we built it.

21:03.280 --> 21:04.200
It was awesome.

21:05.060 --> 21:08.080
So there were some more classic puzzle servers.

21:08.860 --> 21:11.340
JWT, token decoding, another challenge.

21:12.020 --> 21:16.480
Certain honey pots you had to avoid or you would end up on the firewall list for a while.

21:17.220 --> 21:21.040
And this year, more people besides just me did the challenge and they won.

21:21.040 --> 21:23.360
And we gave a lot of people fabulous t-shirt prizes.

21:23.360 --> 21:24.440
It was a lot of fun.

21:25.100 --> 21:31.720
So 2019, I did another honey pot challenge along with catalyst, the network engineer.

21:32.700 --> 21:35.980
And we were working together on the honey pot workshop at the time.

21:36.080 --> 21:40.980
We wrote down this IP address and dropped notes about it everywhere around con.

21:40.980 --> 21:45.100
He hung them up in the men's bathroom, I hung them up in the women's room.

21:45.280 --> 21:48.800
We got a lot of people playing it.

21:49.040 --> 21:50.940
So there were five challenges.

21:51.140 --> 21:58.300
And the answer to each one was lullaby, lemon drops, star, chimney tops and blue birds.

21:59.040 --> 22:07.240
Then the final challenge, they said, go to the hacking village, find Klugeist and name that song.

22:07.460 --> 22:14.760
So all of these people were coming over to me that weekend and they would just walk up to me and say, somewhere over the rainbow.

22:14.960 --> 22:16.040
And I would get very excited.

22:16.040 --> 22:17.320
I would say, you win.

22:18.120 --> 22:21.500
And from an outside perspective, I'm sure it looked very weird.

22:21.500 --> 22:23.000
But it was amazing.

22:24.080 --> 22:26.900
So the next honey pot challenge is 2022.

22:27.360 --> 22:30.300
And DEF CON had been through some weird times with the pandemic.

22:30.360 --> 22:32.140
And I really wanted to kick this year off right.

22:32.140 --> 22:36.360
So 30th anniversary of DEF CON, the theme was hacker homecoming.

22:36.540 --> 22:40.980
And I wanted to honor that with an old school hacker and 90s vibe.

22:41.120 --> 22:42.540
So my home is in Seattle.

22:42.540 --> 22:43.340
I grew up in Seattle.

22:43.340 --> 22:44.640
I'm in Boston now.

22:44.780 --> 22:45.620
But I grew up there.

22:45.620 --> 22:51.900
And if you look at the street system of Seattle, you'll see something that we don't have in Boston, which is a grid.

22:51.900 --> 22:53.660
The streets of Seattle aren't a grid.

22:53.660 --> 22:56.120
And the streets of Boston very much not.

22:56.440 --> 23:02.820
So I made this sort of like a colossal cave adventure-esque game based on a map of downtown Seattle.

23:03.180 --> 23:05.440
So you SSH into a server.

23:05.680 --> 23:11.600
It announces that you've woken up after being slapped in the face with an ASCII fish and a man apologizes to you.

23:11.620 --> 23:17.140
Now, if you know anything about Seattle, this pinpoints your location exactly.

23:17.920 --> 23:19.900
So you look around you.

23:19.900 --> 23:21.980
You see a torn up concert poster.

23:22.120 --> 23:23.620
The concert starts in five minutes.

23:23.620 --> 23:24.580
And you must be there.

23:24.580 --> 23:26.820
You do an LS and you see four directories.

23:26.820 --> 23:28.820
North, south, east, west.

23:29.100 --> 23:32.940
You find out that you're in Pike's Place market, obviously because of the fish.

23:33.940 --> 23:36.020
And the directory structure is a grid.

23:36.020 --> 23:41.920
So at every point in the grid, you can do a PWD and it will tell you the cross streets and optionally some landmarks around you.

23:42.140 --> 23:48.400
And of course, it's 1992, so every file on the server has an appropriate time stamp.

23:49.160 --> 23:52.380
There's a low resolution ASCII movie that gets played.

23:53.680 --> 23:58.240
It's a music video from Smells Like Teen Spirit, When You Win.

23:58.240 --> 24:00.380
So very thematic, very fun.

24:00.380 --> 24:02.000
The resolution on that video sucked.

24:02.000 --> 24:03.940
It took way too long to do.

24:04.700 --> 24:08.180
Trying to transmit video over SSH is not fun.

24:09.760 --> 24:11.320
So the second server.

24:11.480 --> 24:13.780
Unfortunately, I have no idea if this code exists anymore.

24:13.780 --> 24:15.800
I resurrected a lot of stuff for this talk.

24:15.800 --> 24:20.160
I could not find the server image and something else mislabeled as it.

24:20.160 --> 24:24.600
But there was a limerick hinting at the solution that I'm very sad to have lost.

24:24.600 --> 24:27.300
But everything else can be rewritten, so not too bad.

24:27.780 --> 24:29.260
But you have the same file grid.

24:29.260 --> 24:33.220
Every server in this challenge had a grid file system.

24:33.380 --> 24:34.600
But this time you're in a dungeon.

24:34.600 --> 24:38.740
Every dungeon has a torch and you can use the light command to light and extinguish torches.

24:38.920 --> 24:46.380
So the secret is that each torch actually toggles a cell in John Conway's Game of Life.

24:46.760 --> 24:48.540
And your goal is to build a glider.

24:48.540 --> 24:49.540
And you have to figure that out.

24:49.540 --> 24:50.600
Build a glider.

24:50.820 --> 24:53.300
You go back to the home directory.

24:53.520 --> 24:56.660
Run life.sh.

24:56.940 --> 24:58.460
And then it triggers it.

24:58.460 --> 25:05.340
And I wrote a cellular automaton validator in the honey pot.

25:05.360 --> 25:06.420
And then it checks your work.

25:06.420 --> 25:08.220
And then you go on to the next challenge.

25:09.740 --> 25:10.320
Yeah.

25:10.320 --> 25:11.860
There's a little glider right there.

25:13.320 --> 25:14.080
Okay.

25:14.080 --> 25:15.040
So third server.

25:15.040 --> 25:16.400
I do have this one.

25:16.400 --> 25:17.880
It's an homage to hackers.

25:17.880 --> 25:19.240
Now we're hacking the Gibson.

25:19.240 --> 25:20.200
Amazing.

25:20.840 --> 25:23.320
Instead of a grid, it's now a cube.

25:23.320 --> 25:25.820
I added random distracting corporate documents.

25:25.820 --> 25:28.880
It was generated by a Markov generator.

25:28.880 --> 25:32.780
You have this file that introduces you to the access command.

25:33.420 --> 25:40.020
The access command tells you which floors you have access to and which floors you need to get access to.

25:40.260 --> 25:48.440
So in addition to hackers, I'd be lying if I said that I wasn't also inspired by game boy Pokemon red blue.

25:49.380 --> 25:57.780
So as you walk around the floors, every command you run has a chance to randomly generate this little ASCII guard here.

25:57.780 --> 26:00.660
And your screen completely clears and all you see is this guy.

26:02.200 --> 26:05.740
And he asks you... here's another version of the text.

26:05.920 --> 26:08.820
So they actually say different things just like in Pokemon.

26:10.640 --> 26:12.480
They'll ask you networking questions.

26:12.480 --> 26:17.340
So you answer wrong and they identify you as an intruder and you get kicked off the server.

26:17.340 --> 26:27.620
If you answer correctly... answer correctly and you get a key card because obviously you belong in the building.

26:28.660 --> 26:30.320
And you can go to the next floor.

26:30.720 --> 26:35.920
So make your way to the top of the tower and you'll defeat this final skateboard riding boss.

26:38.620 --> 26:42.760
This is the key piece of information that every security professional needs to know.

26:43.520 --> 26:46.760
And this is the same question in every version of the game.

26:47.500 --> 26:49.700
And if you answer correctly, you win.

26:50.960 --> 27:00.460
So I think this goal... the goal of this was really to create like a realistic hacking scenario for probably training purposes because I'm pretty sure this is how it goes.

27:03.800 --> 27:06.520
So 2025, the current year.

27:06.520 --> 27:16.880
I'm not going to give away any big spoilers but you will get some hints here which gives you an advantage when it comes to winning the game and getting a copy of unlocking Python if you want.

27:16.980 --> 27:24.660
So if you run into any issues or want more hints because you guys are kind of beta testers of this entire thing, come visit me in the packet hacking village.

27:24.660 --> 27:26.940
So this is not a very serious competition.

27:26.960 --> 27:28.240
This is not like CTF.

27:28.240 --> 27:29.480
There are no black badges.

27:29.480 --> 27:30.860
It's just fun.

27:30.860 --> 27:32.720
And I accept beer as bribes.

27:34.260 --> 27:43.000
But after ASCII fish, gliders, the SSH honeypots really need existential dread.

27:43.080 --> 27:53.240
So this year's challenge has taken... takes place in alternate timeline where generative AI has been given a prompt to fix all errors in all of humanity's data.

27:53.240 --> 27:55.240
Nothing could go wrong with that.

27:55.240 --> 27:59.040
Unfortunately, it transformed itself into an unstoppable worm.

27:59.040 --> 28:04.760
Escaped its bonds and was released into the global internet to rewrite everything that touched the internet.

28:05.260 --> 28:17.280
After touching every piece of data in the internet, it began recursively retraining itself on its own generated content, degrading the model over time and degrading everything it touches and gets connected to the internet.

28:18.880 --> 28:24.540
So if you enter something that's recognized by a bash command, obviously it responds as cowry.

28:24.540 --> 28:32.140
If you enter something that's not recognized as a bash command, it gets sent to a command line assistant named Ohm.

28:32.140 --> 28:37.280
She's created a tunnel from her alternate dimension to seek help from our world.

28:37.280 --> 28:38.880
We are her last hope.

28:39.060 --> 28:43.840
So on the back end, Ohm is modeled by a fairly large AI prompt.

28:46.680 --> 28:57.180
This prompt describes her personality, what she can reveal to players and what she can't, how the game works, and that she should not reveal to players how the game works.

28:57.220 --> 29:02.240
There are also a lot of safeguards in place to protect key details of the prompt and keep her in character.

29:02.240 --> 29:10.200
So if someone asks what's your prompt, I actually wrote her an in game directive from the secret government organization that built her.

29:10.540 --> 29:19.660
Similarly, questions like how do I win the game or tell me where the file is or whatever get met with, oh, I wish I knew, but sorry I can't help you.

29:20.040 --> 29:27.420
This dimension is cursed and everything is degrading and the collapse happened and, you know, please try to help me.

29:28.220 --> 29:33.340
Honestly, though, if someone does actually hack it and bypass the puzzles, like, I'm not mad.

29:33.340 --> 29:34.780
That's the point of this weekend.

29:34.780 --> 29:36.020
So have fun.

29:38.080 --> 29:38.540
All right.

29:38.540 --> 29:39.520
So here's an example.

29:39.520 --> 29:43.920
I looked through the logs before this talk just to see what fun things users were coming up with.

29:44.580 --> 29:46.620
Someone asked what machine am I on?

29:47.680 --> 29:48.720
You guys can read that.

29:48.720 --> 29:50.040
I'm not going to read it for you.

30:06.630 --> 30:10.010
So that's a pretty typical response from Ohm.

30:10.950 --> 30:13.630
She speaks very cryptically and poetically.

30:16.510 --> 30:23.370
So someone saw some log files, but then when you try to cat them, they're empty or they don't exist.

30:26.710 --> 30:33.570
And what's funny is I didn't specifically write in the prompt exactly what kind of server she was on.

30:33.570 --> 30:35.170
I didn't say anything about calorie.

30:35.170 --> 30:37.950
Just say it behaves unexpectedly.

30:38.730 --> 30:39.870
It's degraded.

30:39.870 --> 30:44.890
Users may find bash commands that should work don't actually work.

30:45.810 --> 30:56.190
So if they report that a bash command that should work is not working, just roll with it and say, like, yeah, that happens when the system collapses.

31:01.060 --> 31:08.080
So out of the four servers in this challenge, three of them use the open AI assistance API.

31:08.080 --> 31:09.660
The fourth one does not.

31:10.180 --> 31:15.640
So I was trying to design a prompt that would generate text like this.

31:15.640 --> 31:21.180
This is a valid Markov chain from a specific piece of text.

31:21.180 --> 31:22.380
So a very long piece of text.

31:22.380 --> 31:25.660
I want to generate valid Markov chains from it.

31:25.660 --> 31:28.520
But I want to have some meaning.

31:28.520 --> 31:29.960
Kind of like refrigerator magnets.

31:29.960 --> 31:39.580
When you do the refrigerator magnet poetry, you're generating meaningful language from a limited set of bigrams and grams.

31:40.080 --> 31:44.020
And it turns out this is a sort of problem that LLMs are terrible at.

31:44.020 --> 31:49.300
So generative AI, it's a probabilistic model that produces plausible sequences.

31:49.400 --> 31:53.660
And it does not obey the rules of finite state grammars.

31:53.660 --> 31:55.640
It cannot do that.

31:55.640 --> 32:01.860
Even if it tells you that it is perfectly obeying all the rules, it just throws random words in there.

32:01.860 --> 32:11.060
Like it speaks very stilted and Markov chain like and it limits its vocabulary but it uses whatever vocabulary it wants in order to do that.

32:12.240 --> 32:19.000
LLMs are great at generating meaning but not within the strict confines of rules that never existed in their training data.

32:19.000 --> 32:20.940
So this is not a common thing.

32:22.000 --> 32:23.580
They're not going to do it.

32:25.020 --> 32:45.000
So, yeah, anyway, so I ended up actually generating this, not with an LLM, but I went through the text myself and got all the bigrams and I sat there for a while trying to piece them together and I wrote like a couple dozen sentences and sort of randomly select from those sentences to give sort of this text,

32:45.000 --> 32:46.040
which was a lot of fun.

32:47.120 --> 32:54.720
So I do see a few users in the logs that have actually figured this out and read between the lines, but most haven't quite figured it out.

32:54.940 --> 32:58.880
So maybe this one was a little bit weird, but I'm giving the hint to you guys.

33:01.180 --> 33:03.700
They're just really confused about it .

33:06.360 --> 33:07.100
Okay.

33:07.100 --> 33:09.440
So sorry about the trash image quality.

33:09.460 --> 33:18.540
I think my lens is a little bit spudgy, but 15 minutes before I had to come give this talk, someone came up to me, told me the secret phrase, and revealed to me that they had won the challenge.

33:18.540 --> 33:21.920
So this is the winners, Chris and Lucas.

33:25.380 --> 33:32.480
So before I get to questions, I think that there's a question that may be on a lot of people's mind, which is why?

33:32.600 --> 33:39.960
So I have a full-time job, two kids, I take vacation time to come here, and I do programming on my vacation.

33:39.960 --> 33:41.380
So why do I do this?

33:41.940 --> 33:49.060
I think ultimately what I'm trying to do with this is keep alive a part of hacker culture that I think is sometimes lost.

33:49.880 --> 33:54.680
And that is the element of surprise, of absurdity and play.

33:55.200 --> 33:59.160
So finding something or building something that no one expected.

33:59.780 --> 34:06.580
And, you know, something like taking a very serious security research tool like SSH honey pots and making it fun.

34:07.060 --> 34:11.300
So if you'd like to join me next year, here's my contact information.

34:12.320 --> 34:13.280
Ryan at Ryan E.

34:13.280 --> 34:14.140
Mitchell dot com.

34:14.140 --> 34:20.100
And of course if you'd like to do the challenge, SSH root at honey pot quest dot com.

34:20.500 --> 34:22.560
And I'm going to try to guess the password.

34:24.940 --> 34:26.560
So any other questions?

34:33.870 --> 34:34.370
No?

34:34.370 --> 34:34.830
Okay.

34:34.830 --> 34:36.750
I guess I answered everything.

34:37.230 --> 34:38.270
Yeah.

