start	end	text
0	640	Quick intro.
640	1700	I'm Mickey.
1900	3280	That's Jesse.
3620	5280	We hack things.
5460	7320	We give talks.
7420	8180	That's who we are.
8180	11160	There's a lot of stuff online.
11160	13340	We work for a company called Eclipsium.
13460	17740	We want to mention them because they help us fund all of this stuff.
19420	25840	Quick terminology, for those unaware, UART is a serial communication protocol.
25880	32360	Wow, it's really distracting, that noise from the other place.
33940	35340	Don't tempt me.
36360	47040	Okay, so UART is a serial communication protocol, usually in IoT devices, OTA over the air, UVC, basically read it yourselves.
48700	53420	One thing I want to be clear about that I do want some participation.
53420	57560	If anyone has a question, shout because I can't see anything.
57560	59180	I have a light in my eyes.
59340	68040	So either come to the microphones and ask us a question or interrupt, yell, everything's cool as long as you do it, you know, with taste.
69100	77380	Another thing I want to be clear about, there's multiple ways to hack a thing.
77460	79460	We did it one way.
79740	83680	I'm sure there's at least 12 people here that can do it better.
85240	86880	I'll start with a story.
89140	94500	Back in the COVID days, we did a lot of e-meetings, you know, video calls, all that stuff.
94500	96220	And I needed a good webcam.
96380	99100	So I found one that did 60 frames per second.
99100	100700	I'm like, yeah, I buy it.
100740	102860	I plug it into my computer.
102860	107720	And then a year goes by and it starts to be flaky in meetings.
107720	112260	And I'm like, okay, it's been on the market for two years.
112260	115400	There must be a firmware update that I haven't applied yet.
115900	119500	I should go and apply that.
119500	123340	So I find the firmware update tool.
123340	124500	I go on their website.
124500	125820	I download it.
125820	130240	That's the URL for the web archive for the original tool.
131340	135680	I recommend that you save it because it's no longer on the internet.
136500	141620	So I download the tool and I install it, right?
141680	142980	Run the installer.
143960	145740	Get the GUI for the installer.
145740	147400	It automatically opens it up.
147600	149920	It shows the camera, the firmware version.
151040	152480	But did you see it?
154140	156380	It extracts into a folder.
157640	162400	Me, being an inquisitive mind, I'm like, okay, something's sus here.
162620	165000	I open and look at the files.
169220	170640	You see it?
174200	182860	I take a closer look and I say to myself, like, what the fuck?
183660	189880	Why does a webcam need almost an 8 meg firmware update?
191320	193260	So take a look at it again.
195300	197680	There's a .sh script.
197680	200020	Keep in mind this is a Windows updater.
201400	206420	U-boot, a USB update binary.
207120	211120	Some weird ass looking file, OTA.
211720	213540	And an auto update TXT.
213540	216000	Okay, something is off here.
217100	221160	I like to hack IOT, so bin walk.
221600	221680	I don't know why I'm doing this.
221700	226760	I swear, this is one of the most beautiful bin walks I've ever gotten in my life.
226920	229940	If you ever run bin walk, you see a lot of sometimes noise.
230200	231760	This is the whole dump.
231760	234340	This is how the firmware for the camera looks.
235280	237180	Now I really have to open this.
238060	239240	Open this device.
239240	241680	And it's like hard.
241680	243560	The front panel is glued in.
244300	245560	I rip it apart.
245560	246380	I open it up.
246380	247180	I look at the back.
247180	248440	I see an SOC.
248500	250000	You see this stuff.
250020	253540	You go like, okay, I'd expect to see a chip on a webcam.
253980	255820	USB to the chip.
255820	258940	The chip does its, you know, conversion of the image.
259400	260860	Passes on the USB.
261200	262420	Normal stuff.
262420	268260	What you'd normally expect from a Linux running target or a system or a device is to have the trifecta.
268440	273500	The CPU, the memory and the storage.
273940	277260	I didn't see memory, so I'm like, okay, weird.
277520	278600	Look at the back.
278600	282660	I see a spy and then I see these pads.
282660	284020	I call them sus pads.
284860	287620	It's three pads on the middle of a PCB.
287620	288500	I'm like, okay.
288780	290420	Turns out, there you are.
291000	294360	So maybe I can hotwire this thing.
294480	295760	So I hotwire it.
296900	298540	And this is what I see.
302170	302890	Okay?
302890	309550	So at this point, um, I'm a bit processing.
309550	311190	I'm like, okay, what did I see?
311390	314470	I see Linux on a CPU.
314470	315910	What Linux version?
316290	317310	Firmware version.
317310	323710	And this is the exact process of emotions that I've had at the time.
326090	328150	Then it turned into this.
330190	332570	And then it came into that.
334710	335670	Okay.
336030	337630	I'm going to hand it off to Jesse now.
340030	344570	So we've already seen some kind of suspicious things already.
344570	350450	So we started to dive into what the firmware update process actually does and how that works.
350450	358690	So the way their package arrives, you have this firmware tool executable and then a couple DLLs.
358690	366290	There's this HD 510 SDK DLL that has most of the update code itself.
366490	371290	And then it has a helper function that's AIT UBC extension API.
371290	378290	It's basically just used for, there's something in UBC or USB video class, it's called extension units.
378290	381790	And those are used for configuring different things about the camera.
382050	386850	This really, most of the update code runs in that HD SDK.
387010	389210	It only calls three of the functions through this helper.
389210	396850	There's a lot of other stuff in this extension unit helper library that is used for other types of devices.
396850	400270	So they just pulled this in for a few small commands.
400270	415610	And then together, those will take instructions from the auto update.txt which will then basically parse commands from the OTA and send commands and the firmware file to the device itself.
415830	424850	And if you look at that auto update, it just has this E star command and then the name of the other file to parse and then reset.
426170	433390	If we look in the OTA, these are even more suspicious because it's just SF probe.
433390	437970	It's like spy flash probe and we're probing chip select zero.
438210	440230	And then spy flash erase.
440230	446230	This particular region offset, this particular size and then it's TFTP transfer.
446230	451290	That doesn't really make sense over this USB interface for how they're doing it.
451290	457450	But we'll go with that and then write that region to that offset that they just erased.
457690	460990	This is literally the full update script that it runs.
461710	466290	We take a closer look at how this actually works in the internals.
466290	469070	I mentioned the UVC extension units .
469210	480850	They're only doing one call to get a property for this specific vendor extension extension unit to get the firmware version and then also switch the camera into firmware update mode.
481130	492030	Extension units are used for a bunch of other things for different cameras like if you have like a pan, tilt, zoom, all of that, those are configured using extension units.
492410	503530	But when you send this specific vendor, specific set property, it reboots the device and comes up as a mass storage device which is kind of interesting.
503770	521630	And then from then on, it's sent, it's using SCSI commands, basically SCSI direct, SCSI pass through commands in order to use vendor specific SCSI op codes to continue sending command and data to the device.
521730	533970	And then it also sends this interesting USB updater op bin and uboot.bin for the camera to run during that update process, which is also something that we're concerned and suspicious about.
534370	536410	But here's some of the code.
536410	551910	It's just doing the open device by path using that helper library and then sending this extension set with a specific GUID and then a specific control selector to say what specific request I'm doing within this extension unit.
552050	557530	Once it does this, it just starts waiting and looks to see, has a new mass storage device popped up?
557530	561050	Can I find the specific device I'm looking for?
561390	565770	So at that point it starts sending SCSI commands.
565770	568410	If you look at the bottom, there's this device IO control.
568630	574130	The specific IOCTL number is OX4D004.
574130	577250	That's the specific IOCTL for SCSI pass through.
577450	579870	And it's used for other mass storage devices.
580090	590410	But in this case we're just sending an inquiry request where we get information back from the device about the specific device from this inquiry request.
591010	596390	In this case they're using this in order to determine what mode the camera is operating in.
596390	600910	So after it reboots, it comes up in what's called ROM mode.
601210	610650	And by doing this inquiry command they can determine if it's in ROM mode based on inside of the buffer it will have a G or a C at a specific offset.
611250	616170	If it has a UPD at a different offset, it's in update mode.
616270	619530	And if it's in UBO, it's in UBOOT mode.
619690	629730	And the way that this works is that it will transition the camera into update by sending that UVC extension unit request.
629830	631550	And then it will send an inquiry.
631650	635630	Once it's in ROM mode, it will send the updater.
635650	638890	And then once it's in updater mode, it will send UBOOT.
638890	649050	And then once it's in UBOOT mode, it will just literally send UBOOT commands over that mass storage channel that it's still using, which is kind of an interesting way to do this.
649570	653510	So they are using vendor specific SCSI op codes to transfer data.
653590	667550	The TFT command instead of doing network operations, they have special handling to convert that into there's a load info command that they send which says here's the address to load this at in memory.
667550	668870	Here's the size.
668950	689570	And then the update tool itself will then calculate an MD5 hash, pass that over and then start sending chunks of that buffer in multiple different SCSI write requests using that specific vendor op code with a sub op code to say these are the chunks and then the last chunk has a different sub op code.
689710	697250	But all the other commands are just sent as literal strings to run and by the camera to interpret in this UBOOT that's running for you now.
698310	703950	So when you're looking at the camera UART itself, it basically looks like this.
703950	712550	And you can see the camera is running and then it switches into UBOOT mode and waits a little bit while it's doing things.
712550	715410	And you start seeing things like this run command at the end.
715410	721890	Those are literal commands that are being run by this, that are being sent from the updater tool to be run by UBOOT in the camera.
722070	731330	So it will do the run commands and then it will do this operation of erase, transfer the data and then write.
731710	739930	And we can look at this and these basically map to our commands that were in that auto update TXT or the OTA TXT.
740490	752550	One interesting thing that we noticed is if you look at the order for here, they're erasing the spy region and in this case they are erasing only the root file system and the kernel.
752610	757950	So they erase the file system and then they transfer the new image to update.
757950	762550	So if you look at the bottom there, there's an MD5 pass.
762770	764310	What happens if that fails?
764310	772090	If there's like an integrity ‑‑ if there's an integrity problem while they're transferring that file, maybe it was a file that isn't going to work.
772150	780510	They've already erased the image and there isn't really any retry and send the copy, send the firmware file again if that fails.
780510	783590	So that's another thing to take a look at.
784150	790130	But at this point, it's a pretty straightforward method of how we can do the updates.
790170	791990	I'll pass that back to Becky.
793270	796090	Spoiler alert, it breaks the camera.
800040	801340	That was easy.
802740	807600	So we've seen their GUI and their tool and everything.
807600	809800	Can we just simplify and make our own tool?
809800	815500	Because we know they're using the third party API from some SOC vendor.
816420	818380	Short answer is yes.
818420	820460	And it's in C sharp.
820460	832860	And the simplest thing is because we got lucky and the firmware update tool is in C sharp, we threw it in our IL disassembler and got the assembly and hacked it together.
832860	835080	And you can convert it to PowerShell if you'd like.
835080	836020	It's fun.
836900	841940	And it works the same, calls the DLLs and fun.
842580	846200	So a quick topic change.
848160	851380	Why the fuck would you put Linux in a webcam?
853960	857740	The quick answer is basically money.
859300	877920	If there's a company that sells you an SOC that has all this integrated already in it and it works and you just got to rebrand it and maintain a, a small workforce of people to maintain the updates over a couple of years that already do other things, it's cheaper to do it that way but it's not always secure.
882080	883720	The way it looks is like this.
883720	886040	The SOC vendor is called Sigma Star.
886280	888660	They make this chip.
889020	897800	You go on the website, they sell all these kinds of SKUs of it, they do for webcams, IOT, all kinds of stuff.
898040	908800	They are a subsidiary of a company called M-Star Semiconductor that doesn't appear to be alive, it's only on paper and that is a subsidiary of Mediatek.
910300	923220	Out of Sigma Star's SOCs we've identified so far, we've seen, um, in TP-Link, which credit to TP-Link, they do publish their GPL code, which is great.
923380	925980	Nexigo and OBSBot.
925980	929080	Never heard of these before this, uh, this research.
929760	931940	But we'll get to that in a second.
932220	941540	Uh, when you go to their website, the fun, the, the good thing about these companies when they, when they want to sell their product, they build a full vertical stack of everything you need.
941920	949880	So, the SDK, the code, the documentation, the data sheets, the examples, everything.
950060	953100	You go to the website and you get all the data you need.
953860	956380	That's, that's the link to go there.
956380	960560	You do need, uh, to create a credential.
961440	965660	Supposedly it will get you access to the source and the SDK.
965720	971260	I have tried, I think it's been two months with two different accounts.
971440	977240	Uh, one is Gmail, one is a cor, Gmail didn't work so I went with my corporate email to see maybe they filter.
977240	978920	No, they just don't give a shit.
979300	982980	Um, there's no data, there's no, nothing.
983100	985440	It is like pulling teeth.
985980	986880	It's terrible.
986880	988900	So, what can you do?
988900	990420	So, do it yourself.
991140	996200	You go Google things, GitHub things, look in the forums.
996760	1000160	Surprise, you can go through LinkedIn and you can go through Twitter.
1001140	1001940	Why?
1002400	1003400	In a second.
1003560	1016060	Um, so the process is like this, you Google for the files, you find them on GitHub, you find them on Google and you repeat this over and over and over and over again.
1016100	1018960	And if you can go into the Russian forums, you get bonus points.
1021280	1025500	There's a GitHub repo with four, sorry, GitHub user with four repos.
1025920	1030380	One of them is the actual USB tool from Sigma Star.
1030380	1037780	It's a bit of an older version but it, they keep things the same way over generations because people are lazy.
1038240	1042580	Um, and if it works they just keep it moving over the years, the technology.
1042820	1045980	You get the U-Boot, you get the Linux, you get the, their SDK.
1046480	1049980	Um, the next two are open directories.
1050480	1055840	So, you just find random stuff in open directories.
1056220	1061280	And the last one is an open IPC kinda sorta, um, implementation.
1061280	1062880	Open IPC if you don't know.
1062880	1070180	It's, um, it's for internet cameras that you can open, you can use open source code to do it.
1070180	1072220	And it supports Sigma Star's chipsets.
1072220	1075520	So, they do have a kernel for that.
1076400	1080020	But like I said, no help from them.
1080060	1082300	I thought maybe there's a chance.
1082580	1083500	Nothing.
1083760	1084800	Forget about it.
1084820	1093500	Um, the only other thing we could do is reach out to Lenovo and say, can you give us the GPL code?
1095780	1097680	And this is how it went.
1099080	1104520	We asked for the GPL code, Lenovo asks Sigma Star for GPL code.
1104520	1109380	Sigma Star's, Sigma Star gives Lenovo the code, Lenovo gives us the code.
1109380	1110960	We build it, it fails.
1111060	1117220	We go to Lenovo and we go back to Lenovo and say, we need more, uh, it's not complete.
1117700	1119240	Again, cycle.
1120260	1122280	We get the code, it works.
1122700	1130760	We build all our demos for the talk and then we're like, you know what, we want to take the extra step, do something, we did something crazy, let's do something even more crazy.
1131640	1136400	Uh, we requested the GPL again and nothing yet.
1137520	1140080	Um, hopefully we'll get it.
1140080	1145580	So, we do have the U-Boot, we have the kernel, we don't have the latest SDK.
1146260	1149500	We have a bunch of stuff from GitHub, what can we do?
1149920	1152840	We do know the structure of how it looks.
1152840	1157340	They do have, for the same SOC you can build either for, uh, Spynor or Spynand.
1157760	1159320	In our case it's a NOR.
1159400	1161480	This is how the, the partition looks like.
1161480	1167340	We're going to focus on these two because it's easier, it's the easiest way for anyone to get into this world.
1168280	1175360	Uh, just build a kernel or modify a file system and that's what we know.
1175360	1176580	We know, this is what we know.
1176580	1182560	We know the camera runs Linux, we know how to build a Linux, we know we can flash it, we know how to flash it.
1184080	1186820	So, here comes the fun part.
1188560	1200070	Can we turn the camera into a camera?
1200070	1202430	We have a laptop, we have a camera, this one.
1203670	1205470	We plug the USB in.
1210590	1216430	Uh, I opened the camera app on the, on the background just to show, I disabled the, the built-in camera.
1216990	1223830	The camera shoots out a text and then it reboots into normal, regular code.
1224670	1226370	Take a picture of him too.
1226370	1227790	Okay, cool.
1231030	1232350	And that's it.
1232350	1239470	So, we, we took the kernel, we built it, we added the hit stack, USB gadgets, cool.
1239850	1247270	The camera boots up, it's a hit, it's a keyboard, it types in stuff, it's cool, it's funny.
1249350	1251450	Um, what?
1252930	1254250	There's more.
1254290	1257170	So, um, so this is the, this is the, this is the, this is the how do we do that?
1257170	1258910	The, the file system is read only, right?
1258910	1265430	It's, it's a spy chip, it loads it to memory and then runs it and every change you do doesn't persist across reboots.
1266250	1272530	Um, so it turns out there's a, there's a section in memory called environment variables, every system usually has it.
1272950	1284890	Um, in this case we just added our own variable called implant and the camera just, the, our code in the camera checks if implant is one, run the hit payload, change it to zero.
1284890	1294150	Next time the camera reboots, implant is zero, if, if, if the code is, if the implant is zero, boot into the normal Lenovo flow.
1294450	1295410	That's it.
1296530	1299930	This is how it looks from the camera side.
1301190	1316470	The camera boots, you see implant equals one, means run the payload, start sending key strokes, this opens an admin command prompt and starts saying, psst, I'm your camera, this is an admin command prompt, I'm going to become a camera now.
1317130	1329830	It reboots, implant is now zero and it just follows the normal Lenovo boot flow and it's a regular camera.
1330910	1334190	Okay, let's, uh, change gears.
1334730	1343050	Uh, for some god awful reason, uh, the RCS script in the camera has Telnet D starting in it.
1344030	1349450	So can we have a network gadget on the camera?
1349570	1350790	Let's try it.
1354110	1358730	So we plug in a camera , I don't know if it's playing.
1359430	1360610	Yeah, it's playing now.
1361090	1368850	So we plug in a camera, integrated camera is off, just to be sure.
1369290	1382630	I'm going to show that there's an, there's an RNDIS gadget, once it's plugged in, it flashed, means the USB event happened, USB Ethernet means the camera's connected.
1384090	1389210	As you can see, it's connected alongside a keyboard from the same composite device.
1392640	1416760	Here we, uh, open Teraterm, Telnet to it, AI Scion, no password, we drop, drop into a shell, I go to my folder, I run the script, it issues the usual I am evil keyboard script, and then I go and I reboot the camera, I don't, I type reboot, it's wrong,
1416760	1425020	I need to type, no, I do, I type reboot, it works, it's fine, I open the, uh, the camera app in Windows and then I wait.
1432440	1434320	And that's it, it's a normal camera.
1438080	1440840	Uh, so, what else can we do?
1440840	1442220	We got to this point.
1443380	1446700	Um, better buckle up for this one.
1448060	1456400	This is a PowerShell script that all it does is share the Internet connection from the host Wi-Fi to the gadget.
1459200	1461740	I see you're getting the, where we're going with this.
1464560	1474220	So, on the left top is the webcam UI, on the bottom left is a Kali machine that we have in Microsoft's cloud, and on the right is the laptop.
1479090	1492110	We start hosting a payload, we start Metasploit listening on the 443, and then you have Metasploit running and listening.
1493630	1496370	Um, yeah, listening.
1497730	1501710	The moment, the moment the text starts running on the top left, the camera's plugged in.
1502310	1507710	Uh, Wi-Fi is connected to a, uh, network called local host, sorry for the confusion.
1508490	1514690	That's it, it's connected to a Wi-Fi, nothing says shared, nothing there, just normal Wi-Fi.
1515090	1519130	Camera plugged in, you are scrolling,
1523380	1528560	the camera now goes to and fetches that PowerShell script.
1534500	1541960	The, the camera has now enabled Internet connection sharing between the Wi-Fi and the RNDIS gadget.
1542020	1559560	The camera now has Internet, but the camera wants to show you, so here we go, there's the gadget, the camera opens the properties for the Wi-Fi controller, tabs over, Internet connection sharing, hits enter, and we have the Wi-Fi controller .
1559560	1562320	And we have a, an interpreter session open on the camera.
1571340	1580720	I open a shell to the camera from the cloud, I just reboot it, because the flag tells it to run as normal camera now.
1583400	1588740	Usual Windows camera app to show you there's no camera found, but it's connected, it will pop it up.
1592740	1593700	Yay!
1605240	1609320	To be honest, this whole demo is structured around this GIF, so I'm not going to show it .
1609320	1610420	That's it.
1613920	1617200	So, um, go have fun.
1617200	1622060	You can buy this camera on Amazon right now, 45 bucks, uh, even cheaper on eBay.
1622920	1631020	Uh, if you're, uh, if you, uh, if you're afraid, if you want to go deeper and you want to play with it, get two.
1631020	1632340	Always get two.
1633060	1634540	Uh, pro tip.
1635340	1636840	And get a flash tool.
1637060	1641600	I recommend, if you have money, buy, uh, Dirty Prog.
1641600	1648460	If you don't, if you have 50 bucks, buy the, uh, the Tigard by Joe Fitz, also known the Tigard King.
1649600	1653880	Um, or any other spy flashing tool.
1655200	1657580	Let's go rent a little bit of the other vendors.
1657580	1662100	So, um, quick question, anyone here from Lenovo?
1662220	1663600	Raise your hand.
1664760	1667140	Don't be shy, I'm not going to do anything bad.
1668180	1670500	No one here from Lenovo?
1671760	1672880	Okay.
1673180	1674760	I'm not offended.
1675820	1683580	Um, so we looked at other cameras, and it turns out there's a bunch of other cameras running Linux.
1684840	1689620	Uh, the Opal Tadpole is running Linux on an Ambarella SOC.
1690260	1700640	Uh, there's a story behind that, I think I'm going to tell that in a second, I don't remember if it's in the slides, but they published the, the, the GPL code yesterday.
1701420	1706920	Next to go is Sigma Star SOC, crickets, nothing.
1706920	1708980	Uh, TP-Link, love it.
1708980	1713520	They already burn, they already got burned by GPL, so they publish it, they don't argue with that.
1713880	1718140	Uh, and OBS Bot is another unknown, uh, brand.
1718140	1726740	OBS is Open Broadcasting Studio, if you're not familiar with it, that's a very popular tool, open source tool to do a lot of video capturing.
1727140	1732200	So, some companies rebranded it, and is selling cameras.
1732760	1739800	Sigma Star SOCs, but newer kernel, ask for GPL, no answer.
1740000	1741580	So, we're going to drop an O there.
1742920	1748740	Um, this is how the Opal Tadpole motherboard looks like.
1748800	1758080	Remember I said, in the beginning, the trifecta, you get the SOC, the RAM, and the storage, it's right there, you can see it, it's three chips.
1758360	1763380	Easiest to recognize, you know, you see this, you get a wide attack surface.
1764820	1775520	OBS Bot, um, Sigma Star SOC, they were kind enough, to mark on the board, T and R, which is TX and RX.
1776360	1783200	So, you connect it, and this is what you get.
1783200	1786120	So, this is going to be an O day, real quick, I'm going to run you through it.
1786540	1804060	Um, you boot, you hold enter, you get into the boot loader, you print the environment variables, remember print env, you see in the environment variables, it mounts the UBI file system as, um, sorry, I'm going faster than my explanation in the video.
1804060	1811900	RO, so it's mounting the NAND as read only, and it in it's, into the Linux RC executable.
1811900	1813660	So, we're going to change those.
1818680	1823800	We're going to set env, RW, and in it to bin SH,
1830160	1832720	and save env.
1832720	1833460	Don't ever forget to save env.
1833460	1833460	So, we're going to
1837480	1841000	reboot , because that doesn't work, so type reset.
1843180	1854100	The camera resets and falls into bin SH, you fall into a root shell, you just change the password, root, root, it's too short, but it will change it anyway.
1856180	1860500	You reboot, you go back into your boot, and then you have to revert your changes.
1861560	1876280	So, you change it back to RW, because you don't want anyone messing with your changes, and Linux RC, the usual stack, and it boots into the normal vertical, the normal code, normal camera code.
1876520	1885260	At the end, it's OBS Linux, OBS boot Linux, you just type root, root, and you have a root shell.
1893270	1896550	Okay, so, I can't believe I'm saying this.
1897350	1903030	There's Linux and webcams now, so, go look at that stuff.
1905350	1919550	There's a whole, like, we've done this 10 years ago, we're going to do this thing again, where you have to do a root of trust, verify firmware signatures, do all that stuff, but now we have to do it in webcams and everything else that runs Linux.
1924560	1933520	Basically, all the stuff that we have to deal with IoT, move that, move that mindset into USB.
1933520	1937920	So, think of every USB device also as an IoT device.
1939120	1940940	Now, GPL compliance.
1944900	1953840	I've done a lot of, of, of complaining to people for GPL code for this project for a while.
1954580	1959140	Basically, any device that runs GPL code, you can ask for the source.
1961520	1966060	They don't usually do that, especially if they're in China.
1966840	1972540	But, you can, you can harass them into compliance.
1973500	1979180	Okay, so, there's, there's a way to do this.
1979180	1983580	You can track people down on LinkedIn and Twitter and social media, which I did in a second.
1984400	1992280	And you can also contact the Software Freedom Conservancy, and they can help as well.
1993180	2000920	What I did, I have no shame, so I just contact Opal co-founders on LinkedIn.
2000920	2004700	I counted the OBS bot CEO on LinkedIn.
2005200	2008320	The next to go co-founder, I just contacted the co-founders.
2008320	2010820	I just went, give me code.
2010980	2017400	And I, pro tip, use GPT to word legal sounding messages.
2019180	2023420	I got a response on Twitter from one of the co-founders of Opal.
2023420	2026180	Any, give me a chance , anyone from Opal here?
2029380	2031480	Ah, thank you for coming.
2032040	2033460	So, good job.
2033460	2034940	Get GPL code.
2037260	2043100	Cool story about Opal, they do firmware updates over web USB.
2044000	2046800	And because they were good, I'm not going to say more about that.
2047620	2055920	Um, so, a, a little bit of experience of how to work with PSIRTs as a security, a security researcher.
2056380	2068960	When you talk to product security response teams, there's a lot of communication that goes on in the background between what the PSIRT team does that face you when you, when you contact Lenovo or any other big OEM.
2069940	2072020	They have to go talk to their product team.
2072020	2075520	So there's a lot of sometimes miscommunications.
2075520	2084000	At first we were told that these devices are end of development and turns out it was not the case.
2084000	2087520	So we have to, we have to change things.
2087520	2094140	Anyway, if you've seen the movie, you know how I feel.
2094640	2097040	This is the Lenovo statement, we're going to skip that.
2097600	2100480	Updates, links, firmware updates over that link.
2101600	2104420	Um, this is the disclosure for them.
2104420	2107080	They, they published it yesterday.
2107540	2110220	Uh, arbitrary code execution as a medium.
2111040	2113300	Someone needs to help me math this.
2113860	2124700	Um, physical access, I don't know, I can have software execution on the host if it's connected to the camera, then I can flash the camera.
2124700	2127760	I guess you can word it as physical access, I don't know.
2128580	2131320	Bottom line, this is not a camera .
2131860	2139660	Uh, I want to thank Rainforest Puppy for, uh, GPL advice and, uh, Case for helping us battling the, the kernel.
2140480	2157420	There is a bunch of shit on this mega link, um, including an OVA VMware image for you to take, download and install and build your own Sigma Star Kernel and other stuff in the GitHub.
2158040	2158840	Questions?
2160080	2161800	Okay, you can clap now, sorry.
2166920	2168660	We were, we were rushing it a little bit.
2168660	2169780	We have five minutes, I know.
2169780	2172780	We, we were stressed out that we won't have enough time.
2174260	2176760	Okay, now we're open for questions.
2178240	2180280	Just yell them out if you have them.
2181160	2183460	Or run to the next talk, it's fine too.
2190860	2197880	Either yell it louder or... How long did it take us to reverse the camera?
2199420	2200420	Minutes.
2201280	2204960	It's, it's basically building blocks that you know exist.
2204960	2209660	Linux, you look at it, it's like hacking classic IOT but over USB.
2211540	2212640	Thank you.
2214560	2216740	More questions, give me more questions.
2217100	2219160	Yes, yell it out.
2223530	2227070	Anybody, anybody can buy one of these, flash it and resell it.
2227070	2227890	Yes.
2228630	2230210	I have a, I have a question.
2230270	2230930	Yeah.
2230930	2246750	I, uh, I bought a, a very similar generic Chinese webcam, uh, about two years ago and a couple of weeks ago I was doing some ADB debugging on my Android phone and when I ran ADB list devices, the camera showed up.
2247110	2248310	Yeah, that, that'll be it.
2248310	2249390	Yeah, have fun.
2249570	2250110	Yeah.
2250110	2250410	Yeah.
2250410	2251870	We do that too.
2253670	2255150	Android's a Linux too.
2255150	2255690	Yeah, go ahead.
2256270	2259410	How many times did Linux fail to build?
2259650	2260690	Oh God.
2261250	2267290	Um, so Linux failed to build a couple of times but maybe mainly because we got incomplete source.
2268110	2268230	Oh.
2268930	2285550	There, there was a bug in... Oh, there, there was a bug in, uh, the HID gadget that we had to patch for getting the, to get the HID stack to work but in the second iteration of GPL code they already gave us the fixed version.
2286210	2287070	Oh, okay.
2287070	2288230	So it works .
2288930	2291150	Yeah, building the kernel is fun.
2291290	2292710	Just take a deep breath before you do it.
2292710	2293370	Go ahead.
2294690	2298650	I think it, you sounded surprised to see Linux in these.
2298650	2301310	I've, I've been an embedded developer for a long time myself.
2301310	2305270	What was it you expected to see, like Wind River, FreeRTOS, something like that?
2305270	2311510	Uh , simple, like it's, it's a freaking convert a CMOS image to USB.
2311510	2311970	That's it.
2311970	2314030	It just takes an image and put it on.
2314130	2314930	Why?
2315090	2317510	Well, it looked like a... Wait, wait, hold on.
2317530	2318910	The AIs, I get it.
2318910	2323710	There's a lot of, you expand things, facial recognition, Windows hello, all that stuff, I get it.
2324490	2335630	But I was surprised to see it because I wasn't expecting it, I was expecting the host to handle most of the processing versus the camera to do all that.
2335710	2341330	Do you feel like that's a trend you see accelerating, just shoveling more horsepower into those things?
2341830	2348010	I'd say over the past ten years there would be a trend of just shoving Linux into things.
2348630	2353010	How's that affecting like the prototyping cycle for these guys?
2353010	2357610	Are they kicking stuff out even faster, figuring they can just patch it?
2358990	2363370	It's, it's a low, it's a, it's a more convenient learning curve.
2363790	2366830	And it, it helps handle your attrition of staff.
2366930	2374590	Because all you need to do is bring in people that know Linux and they can pick up where the other left off and just maintain the stack.
2375430	2377710	I guess it's cheaper.
2377710	2387310	So by attrition of staff you mean you're seeing kind of the same education fall off in everything that isn't Windows or Linux in China as here?
2387310	2390410	When I, when I say education of staff I mean learning curve.
2390410	2398050	If you have a custom SOC with your own custom stack with not, with complicated proprietary code, learning curve is wild.
2398490	2400210	But if you have Linux it's simple.
2400210	2403330	Just bring someone who knows the basics, ramp them up fast.
2407710	2411870	So you mentioned that you were able to get internet access over USB.
2411930	2422390	Is it possible that you could use this method to implement something like say an IP webcam or like functionally upgrade the camera to do something it didn't do before?
2422670	2424770	So funny you mention that.
2425170	2432850	We, we, we were missing files at the end of the, of the cycle of the GPL.
2432850	2434030	Let's call it that way.
2434530	2441210	And some, a couple of those files, not you guys, I'm pointing at Opal, not, not you guys, the, the Sigma Star people.
2442490	2451650	They had kernel modules specifically for the IR SOC, the IR chip and the, the CMOS chip.
2452310	2460270	So we were hoping we can get those kernel modules and just use an interpreter and just webcam, snapshot, go wild.
2460450	2462370	But we didn't get that in time.
2463190	2464210	So, yeah.
2464450	2467950	You can do, you can do crazy stuff with this.
2467950	2469650	It's a computer on a USB.
2469970	2472430	It's a bash bunny basically with a camera.
2475050	2476350	More questions?
2476430	2482550	We got no time, so catch me in the hallway.
