WEBVTT

00:00.540 --> 00:04.220
Good afternoon, ladies, gentlemen, and hackers all around.

00:04.220 --> 00:07.220
We are very, very excited to be here with you today.

00:07.220 --> 00:10.460
We're excited to share what we've done this year.

00:10.940 --> 00:14.920
The light's a little bright, so I can't see you, but I'm trusting that there's people out there.

00:14.920 --> 00:22.320
So as always, keep your hands and feet inside of the vehicles at all times and enjoy the ride.

00:22.320 --> 00:23.520
We're excited.

00:25.480 --> 00:28.700
Okay, so this is what we're going to go over today.

00:28.700 --> 00:31.880
What I really want to point out is the link at the bottom.

00:32.060 --> 00:33.320
It is a GitHub link.

00:33.320 --> 00:41.000
If you would like to follow along, see more details, actual code, and the firmware of what we've gone through, you can go ahead.

00:41.000 --> 00:44.540
We published it about 30 minutes ago, so you can go in and follow through.

00:44.600 --> 00:52.580
Or if you would just like to listen to the talk, follow along, and then maybe view it at the end, there is a QR code that we have that you can scan.

00:52.580 --> 00:54.280
I promise you it's not a rickroll.

00:54.440 --> 00:56.340
It'll just give you this GitHub link.

00:58.460 --> 01:00.760
Okay, first we'll do some introductions.

01:00.880 --> 01:02.600
My name is Justin Applegate.

01:02.600 --> 01:06.420
I am a rising graduate student at Brigham Young University.

01:06.620 --> 01:08.140
I am an avid CTF-er.

01:08.140 --> 01:10.020
I play for Project Sekai and the U.S.

01:10.020 --> 01:11.100
Cyber Team.

01:12.120 --> 01:13.660
I am Ava Peterson.

01:13.660 --> 01:18.260
I'm also an undergraduate student at BYU, and I go by the handle DeltaBlueJay.

01:18.880 --> 01:20.420
And I am Justin Mott.

01:20.420 --> 01:25.320
I am also a graduate student at BYU, and I go by the handle Kester Burris.

01:25.500 --> 01:25.920
Thank you.

01:25.920 --> 01:29.300
Yes, I go by LegoClones, if you see me around.

01:29.360 --> 01:32.960
The last member of our team for this project, his name is Wyatt Pangirl.

01:32.960 --> 01:34.880
He goes by SpoutingWhale.

01:35.060 --> 01:36.980
He just graduated from BYU.

01:36.980 --> 01:41.780
He was not able to make it today, but he was an invaluable member of our team.

01:43.780 --> 01:46.380
So let's just go over the project real quick.

01:46.380 --> 01:49.780
But first, I want to present to you the router graveyard.

01:49.780 --> 01:54.760
We managed to break not one, but two, but three routers along the way of this journey.

01:55.060 --> 02:05.100
We really wanted to apply some CTF skills to a real-life situation, so we picked a router, a device, and tried to hike into it.

02:05.100 --> 02:06.220
So we formed our team.

02:06.220 --> 02:12.060
We picked a timeline of about a semester long project and saw what we could get from there.

02:12.300 --> 02:17.900
So the device we picked was this Vylo router a home mesh Wi-Fi device.

02:19.940 --> 02:28.080
So as any vulnerability researcher or security researcher does, when you first start against a new target, you want to do reconnaissance.

02:28.080 --> 02:28.860
You want to OSINT.

02:28.860 --> 02:33.520
You want to figure out what has been done before so I don't have to reinvent the wheel.

02:33.660 --> 02:37.400
So this is some of the results of what we went through.

02:37.400 --> 02:41.120
Vylo Living is the company that produced the routers that we went after.

02:41.120 --> 02:49.220
They were a startup founded in 2021, so they're pretty new, pretty recent, and they only have two products as of today.

02:49.220 --> 02:50.660
They are both mesh routers.

02:50.660 --> 02:53.380
One supports Wi-Fi 5, the other Wi-Fi 6.

02:53.380 --> 03:03.960
We searched for CVEs that have been released, any sort of technical deep dive or breakdown, or even a consumer review that might go into some of the features a little bit, and we didn't find anything.

03:04.000 --> 03:12.380
So between the fact that it's a new company, the fact that we didn't see anything, any other research that had been done before, and it was pretty cheap.

03:12.380 --> 03:14.900
It was one of the cheapest routers that we could find on Amazon.

03:14.900 --> 03:24.120
We were thinking, all right, this is perfect for some college students to get our feet wet, get involved, find some CVEs, just get used to the router hacking scene.

03:24.220 --> 03:31.260
A couple of notes, I know a lot of routers, especially the older ones, are administered through a web interface.

03:31.520 --> 03:39.520
You connect to the LAN or to the WAN, you type in 192.168.1.1 in your browser, it pops up, that's how you set it up.

03:39.520 --> 03:42.100
This was not the case with us and with this router.

03:42.100 --> 03:44.660
It was all managed through an app on your phone.

03:44.660 --> 03:45.960
Kind of a new age thing.

03:46.240 --> 03:48.780
They said they have a bug bounty program.

03:48.780 --> 04:02.480
When we did some research, in order to access the bug bounty program, you had to sign an NDA and be a part of their beta testing group, which we didn't know what the NDA looked like, so we reached out and said, hey, we want to join the beta testing group,

04:02.480 --> 04:04.800
can you send us the NDA, and they just never got back to us.

04:04.800 --> 04:08.840
So we were like, well, I guess we'll just risk it for the biscuit, go for it anyway, see what we find.

04:09.380 --> 04:16.900
And last thing, the firmware was not released by the vendor, it's not something that we could just download and go through, we had to go ahead and recover that ourselves.

04:17.520 --> 04:21.620
This led to the three main goals for us today.

04:22.180 --> 04:33.700
First was to acquire the firmware, that way it's a white box test and not a black box test, you can see the code, it makes it a lot easier to actually turn memory corruption vulnerabilities into exploits.

04:33.700 --> 04:42.080
Then we wanted to pop a shell, actually get a shell on the device that makes debugging and extracting the latest version of the firmware much easier.

04:42.080 --> 04:49.020
And our third goal was to find as many pre-authentication remote code execution vulnerabilities as we could.

04:49.020 --> 04:56.540
That's kind of the holy grail, anyone that does not have administrator access to this router that can run whatever code that they want on it.

04:56.540 --> 04:59.120
So those were the goals that we had when we approached it.

05:00.240 --> 05:04.140
So obviously the next step was to start enumerating our attack surface.

05:04.660 --> 05:09.840
So we went and disassembled the router and this is what we ended up with.

05:09.840 --> 05:16.520
And we found some UART pins, so we tried to solder to them and that was the death of router number one.

05:16.700 --> 05:20.680
You may be gone but it will live forever on in our hearts.

05:22.620 --> 05:26.080
The second router had better pins that were easy to solder to.

05:26.080 --> 05:30.980
So then we hooked it up, got a Linux log on screen.

05:31.300 --> 05:34.820
The problem is we didn't know the password and it wasn't an easy one.

05:35.080 --> 05:38.460
And the UART interface died after 30 seconds after boot.

05:38.460 --> 05:44.800
And it was really hard to even try to put in a password because it printed out how much time you had left every second.

05:45.660 --> 05:49.940
As a result, there was no free shell from this interface.

05:50.100 --> 05:51.240
So we moved on.

05:52.060 --> 05:54.340
We went to go and look at the Vilo app.

05:54.340 --> 05:57.580
We pulled the APK from Google Play.

05:58.420 --> 06:02.300
And apparently the other members of our team think that mobile rev sucks.

06:02.340 --> 06:04.380
I thought it was a great time.

06:05.460 --> 06:11.300
We found some Firebase info, various cloud service stuff on the app.

06:11.300 --> 06:18.840
But the biggest important thing that we found was a custom service running on TCP port 5432.

06:18.840 --> 06:26.580
This was used for app to router interactions when the router had not yet gotten internet access.

06:26.840 --> 06:29.000
This was used to do all that set up.

06:29.000 --> 06:29.800
It would spin this up.

06:29.800 --> 06:31.280
They would talk to each other over this.

06:31.280 --> 06:35.820
They had a custom protocol that we reverse engineered to learn how that was working.

06:37.420 --> 06:38.700
Next slide.

06:39.740 --> 06:41.600
So this is kind of the overview.

06:41.600 --> 06:44.420
It had a 15 byte header and a payload.

06:45.180 --> 06:49.040
The header had all the fields that you see there.

06:49.120 --> 06:51.960
Not all op codes had payloads, but many did.

06:51.960 --> 07:00.120
And they were usually encrypted using this weird XXT plus custom obfuscation layer random things.

07:00.420 --> 07:04.780
Basically the app had a hard coded key that obfuscated and sent to the router.

07:04.780 --> 07:07.100
The router encrypted a new key and sent it back.

07:07.100 --> 07:08.580
But it was all reversible.

07:08.860 --> 07:14.700
So we were able to go from the hard coded key and generate our own ones to be able to talk to it.

07:15.180 --> 07:28.360
Which made it really easy to start once we were able to get the source for it, start sending messages back and forth and exploit some of our some of the things we found.

07:30.540 --> 07:34.340
So then we needed still needed to get the firmware off of it.

07:34.340 --> 07:38.740
We saw that there was a flash memory chip of the model on the slide.

07:39.260 --> 07:43.120
We tried some software utilities and they only gave us bad data.

07:43.120 --> 07:47.420
So then we got this Salie logic analyzer and then it just worked.

07:47.860 --> 08:02.920
We just hooked it up, we fired up their software, we turned the router on, we got all of the SPI data straight to their software and then we could just decode it and there was the binary and we extracted the firmware and then we had everything that was on the router just like that.

08:02.920 --> 08:12.920
We spent about a month getting to this point trying all sorts of different stuff and like literally it took us about two hours and then we had everything on it the moment we plugged this in.

08:15.040 --> 08:20.980
So this is just a look at what that SPI data looked like in the software.

08:20.980 --> 08:23.480
It was super easy once we had it.

08:23.480 --> 08:32.620
We have a more technical deep dive on exactly what that is and the Python scripts we use to translate this into the binary on the GitHub.

08:32.920 --> 08:36.400
Yep, so check out the GitHub if you want to see more about how that's done.

08:36.680 --> 08:44.600
At this point we had the firmware, we had accomplished goal number one, now we wanted to look for vulnerabilities and establish a shell.

08:44.600 --> 08:52.340
So before you start looking for vulnerabilities it's usually a good idea to figure out how to emulate the firmware on your own machine.

08:52.520 --> 09:01.820
This specific device had a 32-bit little endian MIPS processor so that's what all the the binaries were compiled to be using.

09:01.900 --> 09:21.580
Most of us have x86 or even ARM machines and so that's not something that we can run natively so we decided to use QEMU which was statically compiled along with chroot and some precise GDB breakpoints that we had figured out after some reverse engineering in Ghidra in order to actually emulate the firmware and get it running on one of our machines.

09:21.580 --> 09:30.640
This makes it significantly easier to fuzz for vulnerabilities, to test things out, to create exploits once you find a vulnerability.

09:30.820 --> 09:45.180
In addition we wanted the ability to compile our own executables that we can place on the device and run them because a lot of these embedded devices do not have the executables that you would like to have on there, for example Netcat or whatnot.

09:45.540 --> 09:50.000
This one didn't even have WhoAmI and so we wanted to be able to create our own stuff.

09:50.000 --> 09:55.440
Now this device used UCLibc as its libc library.

09:55.960 --> 10:12.280
UCLibc was actually pretty much discontinued or unmaintained since 2012 and so someone created a fork called it UCLibc-NG or next generation and so that is what we used along with Buildroot to build a toolchain so that we could compile our own executables.

10:12.280 --> 10:15.620
It worked for the most part, not all the time.

10:15.700 --> 10:20.040
The Bindshell that we had created and used for one of our exploits worked just fine.

10:20.040 --> 10:27.940
We were able to compile GDB server but every time we tried to connect to it remotely it kept segfaulting.

10:27.940 --> 10:30.660
It could be because we're using UCLibc-NG.

10:30.660 --> 10:32.600
It could just be a skill issue on our part.

10:32.600 --> 10:33.440
I'm not sure.

10:33.440 --> 10:34.680
Something happened there.

10:35.480 --> 10:38.640
This is what it looks like when you actually have it emulated.

10:38.640 --> 10:49.760
So like I said we're using chroot to mount the file system so that the executable can find the libraries that it's looking for at the hardcoded path that it has.

10:49.760 --> 10:52.860
Then we have a statically compiled QEMU which runs it.

10:52.860 --> 10:55.620
Now you can see a "-g1234".

10:55.620 --> 11:03.980
If you're not super familiar with QEMU or GDB, this opens up a remote debugging session on the local port 1234.

11:03.980 --> 11:20.400
Which means on a separate terminal than what you see here, you can open up GDB server or GDB multi-arch and then connect to that local port and now you're running the firmware here but you can debug it with your own GDB setup in another terminal.

11:20.440 --> 11:29.060
And then because this one opens up a socket and expects communication, you have to open up a third terminal to actually send data to this service.

11:29.060 --> 11:30.260
We got all that figured out.

11:30.260 --> 11:33.920
Again more details are in the GitHub repo if you would like to see how that's done.

11:34.920 --> 11:43.180
At this point we spent about a month and a half, approximately six weeks, looking for vulnerabilities in the VILO routers.

11:43.180 --> 11:46.260
Like we said the holy grail is pre-authentication RCE.

11:46.260 --> 11:51.540
We found nine vulnerabilities total in the the four months that we had for this project.

11:51.540 --> 11:54.200
Six of them were critical and three of them were medium.

11:54.200 --> 12:00.480
Out of those six critical vulnerabilities, four of them were pre-authentication buffer overflow vulnerabilities.

12:00.580 --> 12:17.460
Now we had only figured out how to exploit one of them because three of them were on a version of the firmware that had canaries enabled for that and so we weren't actually able to overwrite the instruction pointer and execute our own code, except for one of them we were able to.

12:18.000 --> 12:27.020
And while we were working on trying to develop exploits, see if we can get past these mitigations, we accidentally discovered a blind authenticated command injection.

12:27.080 --> 12:32.900
Now we're going to go over three specific vulnerabilities, the ones we found most entertaining for you guys today.

12:33.120 --> 12:41.300
I also want to note most of these bugs are present in the service, the custom service running on port 5432 that we talked a little bit about.

12:42.360 --> 12:44.160
These are the vulnerabilities up here.

12:44.160 --> 12:46.820
So you can see the four buffer overflows are at the top.

12:46.820 --> 12:49.080
They're all 9.6 criticals.

12:49.080 --> 12:51.400
There was an info leak and some lack of authentication.

12:51.680 --> 12:54.380
We have reserved CVE numbers through MITRE.

12:54.380 --> 13:02.240
They're not published yet since we just published our public repo earlier today, but we have reserved the numbers and they're in the same order that you see up here.

13:04.840 --> 13:10.700
Okay, the first vulnerability that I want to talk about today is the lack of authentication in this custom service.

13:10.740 --> 13:23.140
So as my team member said, most of the communications from the app to the router went through AWS, except if you're not connected to the internet, you need some way to set it up.

13:23.140 --> 13:24.900
So that goes through this service.

13:24.900 --> 13:37.660
The thing is, because it has hard-coded keys and there's really no authentication inside of it, anyone that is on the LAN and knows how to speak this protocol can control the router, pretty much.

13:37.660 --> 13:39.700
So anything that you can do, they can do.

13:39.700 --> 13:46.600
For example, you invite a friend over, give them the Wi-Fi password, they're now on the Wi-Fi, they can control the router the same way that you can.

13:46.600 --> 13:55.460
They can see and change your SSID, your password, PPPoE, username and password, they can reboot it, they can even exploit all of these vulnerabilities.

13:55.780 --> 14:05.820
That was very useful for us because then a lot of the buffer overflows that we found became unauthenticated RCE vulnerabilities and not authenticated RCE vulnerabilities.

14:05.820 --> 14:17.920
The other important thing to note is while this service was used for initial setup when the router didn't have internet access, it stayed up the whole time that the router was on, even if it did.

14:17.920 --> 14:21.100
So it was just always available no matter what.

14:21.440 --> 14:28.120
So we first found the first buffer overflow in this local app set router token function.

14:28.120 --> 14:32.620
We talked about how there are different messages that are differentiated by opcodes.

14:32.620 --> 14:39.720
So the opcode 0x3e updates a token and a time zone using an encrypted JSON object.

14:39.720 --> 14:43.860
Encryption coming from this weird XXT and obfuscation that we talked about.

14:44.040 --> 14:58.400
If you are familiar with C and memory corruption, you'll see this sscanf function immediately will stand out to you because it takes the token and pulls it into a fixed length buffer token, but it doesn't check the length of the string.

14:58.400 --> 15:05.240
So if token is, for example, only 16 bytes and you send a token that is 20 bytes, you now have a four byte overflow.

15:05.240 --> 15:06.280
Pretty obvious.

15:06.300 --> 15:09.680
So our next goal was, how can we actually exploit this?

15:09.700 --> 15:11.560
We don't want to just say, oh, this is a vulnerability.

15:11.560 --> 15:12.540
We want to prove impact.

15:12.540 --> 15:14.140
Plus it's kind of fun doing this.

15:15.280 --> 15:18.240
For mitigations, pi and canaries were disabled.

15:18.480 --> 15:20.160
Or at least that's what we thought.

15:20.160 --> 15:30.220
We had later learned that in the latest version of the firmware, canaries were enabled and this ended up not being exploitable, but we didn't know that we were dealing with an older version of the firmware.

15:30.220 --> 15:35.100
It was the newest one that we could get our hands on, but it still wasn't the latest one.

15:35.460 --> 15:38.040
So we were trying to figure out, how can we exploit this?

15:38.040 --> 15:41.140
We just have a generic buffer overflow vulnerability.

15:41.660 --> 15:46.400
If you're into binary exploitation, ROP probably comes to mind.

15:46.400 --> 15:51.300
ROP is a little bit difficult in MIPS because it doesn't have a return instruction.

15:51.340 --> 15:55.240
Yeah, you can still kind of get it, but it makes it significantly more difficult.

15:55.320 --> 16:04.260
As a side note, based off of what we had to do here, I decided to make a CTF challenge with very, very similar conditions that I wrote myself.

16:04.260 --> 16:07.300
We released it as a part of BYU CTF 2024.

16:07.660 --> 16:10.920
If you would like to do that yourself, give yourself a challenge, you can look it up.

16:10.940 --> 16:12.160
It's available on GitHub.

16:15.060 --> 16:18.160
So how do we exploit this?

16:18.160 --> 16:26.060
Well, we wanted to find kind of a one-shot gadget where we could just return there and then it would do everything for us and we didn't have to chain multiple gadgets together.

16:26.060 --> 16:34.340
Because of the overflow, we could control the RA register or the return address register and the S8 register, which is pretty much the stack pointer.

16:34.380 --> 16:45.420
So we figured if we can control S8 and point it to a user-controlled bash command and then set the instruction pointer to go to this gadget, win, right?

16:45.420 --> 16:46.220
You profit.

16:46.220 --> 16:48.800
ASLR is enabled, so we can't use stack values.

16:48.800 --> 16:53.000
But because PI is disabled, we know where all the global variables are.

16:53.000 --> 17:00.940
So we started looking through to see what global variables can we control that we can easily put our own command inside of it.

17:01.480 --> 17:06.100
So us being the intelligent people that we are, decided to put a semicolon reboot semicolon in there.

17:06.100 --> 17:08.000
We ran it and nothing happened.

17:08.000 --> 17:14.480
So we rebooted it just to make sure that we hadn't messed anything up and we ended up messing something up by doing that.

17:14.480 --> 17:18.120
The router just kept rebooting and it never actually got online.

17:18.120 --> 17:24.360
Turns out there's an authenticated command injection vulnerability that Ava will now go over.

17:25.220 --> 17:31.380
So after we found our accidental command injection vulnerability, we went back to find the code that was responsible for this.

17:31.400 --> 17:35.740
So we ended up finding it in the sysconf binary, which is run on boot.

17:35.900 --> 17:42.840
So as you can see here, it formats a UDHCPC bash command with several variables, including the router host name.

17:42.840 --> 17:46.260
And then it pipes that directly into the system function.

17:47.680 --> 17:57.640
And so because we can control the router host name through the viral app, we can get arbitrary RCE by just setting that host name to a bash command.

17:57.640 --> 18:04.000
So we can verify that this command actually has been run by looking at the boot output, which you can see here on the right.

18:04.000 --> 18:06.620
You can see the output of that command right there.

18:06.880 --> 18:10.720
We got this output from the UR interface that we had connected to initially.

18:11.520 --> 18:23.100
So there are a few limitations with this exploit, namely that the injected command is run only once on booting the router, as well as that the router host name is limited to a length of 30 characters.

18:23.260 --> 18:37.080
So as a result, we had to write our payload into several 30-byte sections, which what we ended up doing with that is write a script to the slash folly directory, which is one of the few directories that is both writable and persistent on the router.

18:37.480 --> 18:45.920
And so we wrote a script that itself then downloads a longer script from the using wget and runs that.

18:45.920 --> 18:52.000
Now, we also found that the router does not have an internet connection at the time of running the injected command.

18:52.060 --> 18:58.560
So we had to make our script or our payload wait 20 seconds before running our first script.

19:00.060 --> 19:11.660
So after we wrote our first payload, it then downloads and executes a second payload, which itself then downloads and executes a compiled cbind shell, which we can connect to via netcat.

19:11.660 --> 19:15.320
And so through this bind shell, we were able to gain our first shell on the router.

19:15.880 --> 19:21.740
So as you can see here, we're able to netcat into the router and find that we have gained a shell as the root user.

19:28.900 --> 19:40.600
Okay, so once April had come around, we had reached our four months, it was the end of the semester, we had to wrap up the project and we decided, you know, let's reach out to the vendor, try and get in contact, send them the details for the vulnerabilities,

19:40.600 --> 19:42.220
let's see if we can get this patched.

19:42.220 --> 19:46.560
It was actually pretty much like it was a pretty big pain to get in contact with them.

19:46.560 --> 19:52.260
They had an email address listed in their terms of service, but it didn't exist, it just bounced back.

19:52.260 --> 19:58.100
We reached out to a couple other email addresses on their website, we tried to guess the email addresses, none of that worked.

19:58.100 --> 20:04.300
We reached out over social media, they have YouTube, they have I think Facebook, maybe an Instagram, we didn't hear back from that.

20:04.300 --> 20:09.140
We filed a couple support tickets and eventually we got a response from them.

20:09.640 --> 20:18.420
They put us in contact with the actual developers and the developers said, hey, thank you for sending us this, we'll take a look at it, we'll get back to you on it.

20:19.340 --> 20:34.320
This is the overall timeline of what we did, so we started the project in January, we finished it up in early April, we reached out to them, and it took us a month before we actually got in contact, and we said, hey, here are the details for these nine vulnerabilities,

20:34.320 --> 20:40.620
we are giving you a 90-day deadline, we are happy to help if you have any questions, if you want us to elaborate, et cetera.

20:40.840 --> 20:53.640
We followed up a month later, didn't hear anything, followed up two weeks after that, we didn't hear anything, and as we had told them, we went ahead and filed CVE numbers from MITRE, we followed up two weeks later, and they said, we're working on it,

20:53.640 --> 20:56.560
we'll publish something pretty soon here, we'll get it out to you.

20:56.820 --> 21:09.980
So the 90-day disclosure deadline was a couple days ago, we timed this for our talk today, and the vendors actually reached out to us like the day before we left here for DEF CON and said, hey, we've pushed a new firmware update, can you check that, and we said,

21:09.980 --> 21:11.440
yes, just not right now.

21:11.440 --> 21:18.440
We haven't looked at it yet, we'll take a look at that there, but they have been somewhat responsive after we finally got in contact with them.

21:20.160 --> 21:39.040
Just a quick conclusion, we expected it to be a lot easier to get started, to get the firmware to find the initial vulnerability and get that initial root shell, it took us two months to get to that point, so we were a little surprised about that, that's also probably attributed to the lack of experience on our part,

21:39.040 --> 21:50.860
but then once we got in and we got the firmware, we were able to find a lot of bugs and not a lot of time, and we only looked at a very, very small portion of the attack surface, there is still a lot more space for bugs.

21:50.860 --> 22:05.040
If that's something that you're interested in looking for, go to the GitHub repo, you'll notice that there are holes in the documentation that we just didn't have time to fill in, and we've hacked into a couple other devices since then, and we found that the cheaper,

22:05.040 --> 22:09.120
lower quality devices, hacking them is very, very similar.

22:09.180 --> 22:15.300
IoT and embedded products still have a long, long way to go when it comes to security.

22:15.900 --> 22:28.780
So this is the QR code, if you want to go ahead and go to the GitHub repo and look at the details, if you would like to connect with us on LinkedIn, we also have our links up here, what time are we at?

22:28.780 --> 22:29.200
53.

22:29.200 --> 22:30.900
Are there any questions?

22:34.220 --> 22:35.340
Yes.

22:39.820 --> 22:41.640
Yeah, feel free, come on up.

22:44.330 --> 22:49.570
I did not expect that.

22:58.470 --> 23:03.070
Sorry, can you repeat that?

23:04.330 --> 23:07.130
He said, like, what method do we use to find the vulnerabilities?

23:07.130 --> 23:12.270
Okay, so the question was, what method did you use to find the vulnerabilities?

23:12.270 --> 23:13.150
Was it fuzzing?

23:13.150 --> 23:15.670
Was it manual code analysis?

23:16.390 --> 23:18.110
We did not use any fuzzing.

23:18.150 --> 23:23.750
Fuzzing is a little bit more difficult, it's not impossible, but it's a little bit more difficult when you have a closed source binary.

23:23.930 --> 23:33.870
Normally you would compile source code with some sort of sanitizer and then fuzz it from there, but because it was closed source, and it was MIPS, and we're not super experienced with fuzzing, we went the manual route.

23:33.870 --> 23:39.190
So we just searched through the code by hand in Ghidra, decompiling it to find it.

23:39.190 --> 23:39.990
Thank you.

23:40.690 --> 23:41.850
Other questions?

23:45.220 --> 23:47.580
Going once, going twice.

23:48.380 --> 23:49.400
Yes, right here.

23:51.020 --> 23:52.300
Yeah, feel free to come up.

23:58.600 --> 24:02.880
And if you could speak that protocol, you could do basically any router administration.

24:02.960 --> 24:15.140
Could you not set the hostname of the router from there and trigger a reboot and make that authenticated hostname injection, hostname command injection to an unauthenticated injection because there's no credentials from that path?

24:15.140 --> 24:15.580
Perfect.

24:15.580 --> 24:21.660
So the question was, like, since that...

24:21.660 --> 24:23.520
how would you say that?

24:23.520 --> 24:33.420
Since the local service is unauthenticated, the question was about, can we use that to turn the router hostname injection to an unauthenticated command injection?

24:33.620 --> 24:36.300
I think the answer to that is no, kind of.

24:36.300 --> 24:37.340
At least not that we know of.

24:37.340 --> 24:42.480
Not that we know of, because the router hostname, the process of setting that actually goes through AWS.

24:42.800 --> 24:46.400
And so that was one area that we didn't have a lot of time to explore.

24:46.400 --> 24:57.840
There are some keys associated with logging into that AWS service, which it's possible that those itself are vulnerable in some way, but simply having access to the local service is not enough to set the router hostname.

24:58.160 --> 25:02.880
Yeah, so a large part of the mobile app was just dealing with the AWS API.

25:02.960 --> 25:04.620
We didn't have a whole lot of time to go through that.

25:04.620 --> 25:11.320
So it may be possible, but from what we had seen, we could only do that if you were authenticated, if you already had the app set up with the router.

25:11.440 --> 25:12.220
Thank you.

25:12.380 --> 25:13.800
I think we got one back there.

25:38.210 --> 25:52.190
So the question was, for someone who is new to hardware hacking and new to vulnerability research, do you think following these steps would be good to learn some hardware hacking and do you think springboarding off of the research that we've done would be a good way to get started?

25:52.430 --> 26:02.330
First off, I'm still kind of a noob, so I don't know that I have the best advice, but I would say this is something that you definitely can do for hardware hacking.

26:02.330 --> 26:04.530
This was kind of my first exposure to it.

26:04.790 --> 26:05.650
And I learned a lot.

26:05.650 --> 26:07.550
There's a lot of resources out there.

26:07.550 --> 26:09.490
DEF CON has their hardware hacking village.

26:09.790 --> 26:14.270
I think reproducing these steps and going through it would be very, very helpful.

26:14.570 --> 26:18.010
We do have some extensive write-ups specifically on the hardware part.

26:18.010 --> 26:22.870
We spent more time documenting that because it was newer for us, so hopefully it's helpful.

26:23.090 --> 26:29.990
As for finding CVEs, if you want to find CVEs and IoT devices, this is probably the easiest way to do it.

26:29.990 --> 26:40.590
It does take a little bit of knowledge when it comes to memory corruption and whatnot, but if you have an introduction to C and assembly and memory corruption and you want to find your own, it's just a matter of looking through the code.

26:40.590 --> 26:43.770
There is just so much code that we haven't even gone through.

26:43.850 --> 26:45.310
So I would absolutely recommend that.

26:45.310 --> 26:45.770
Yes.

26:46.350 --> 26:47.810
Any other questions?

26:48.430 --> 26:49.170
Yes.

26:57.980 --> 27:01.620
Okay, so the question is, how do you get future firmware updates?

27:01.620 --> 27:03.160
So this is kind of a tricky question.

27:03.160 --> 27:05.020
We looked into it a little bit.

27:05.940 --> 27:12.640
Initially, there was an API endpoint, just an HTTP web server, where you were able to say, hey, what is the latest firmware?

27:12.640 --> 27:14.020
Can you give me a link to it?

27:14.020 --> 27:17.820
The thing is, it didn't actually give you the latest firmware.

27:17.820 --> 27:22.620
We talked about one of the buffer overflows that we tried to exploit that did not have stack canaries.

27:22.640 --> 27:28.720
We thought that was the latest firmware version because we got it from that endpoint pretty early on in the process.

27:28.900 --> 27:36.980
But the actual device had later firmware that I think it gets through the AWS IoT.

27:36.980 --> 27:43.740
It uses encrypted MQTT communications, and so somehow it gets the update from that.

27:43.740 --> 27:46.460
We have not fully reverse engineered that process.

27:46.460 --> 27:52.800
We don't know how it is, but it is somewhere within the AWS MQTT sort of set up in there.

27:53.420 --> 27:54.860
Other questions?

27:57.280 --> 27:58.760
Going once.

27:59.040 --> 28:00.260
Going twice.

28:00.640 --> 28:01.000
All right.

28:01.000 --> 28:02.360
Thank you for coming to our talk.

28:02.360 --> 28:03.620
We appreciate it.

