4 ms·
Nothing says "I love you" more than malware persistently embedded in your USB devices. Here's how hardware teams work (in my experience) ---- Manager: "Hmmm.
by kabdib 11y ago
Nothing says "I love you" more than malware persistently embedded in your USB devices.
Here's how hardware teams work (in my experience)
----
Manager: "Hmmm... we need firmware. Hey, who can update the USB stack for the next version of our USB toaster?"
Team: shrug
Manager: "Figby! Don't you do Arduino stuff on the weekends? You do it. Be done next Friday."
Figby: "Meep?"
USB is hard enough to get working properly, now you need to add "resistance to attack from the host" to the feature set. Figby is in trouble because he's being crushed under four rocks now:
1. USB is hard to get working. The standard is pretty complicated, and speaking frankly here, the device class standards are pretty badly fucked up. Camel-by-committee class bad. You spend a lot of time getting edge cases to work. (Don't get me started on DFU, OMFG).
2. Figby probably has a bunch of legacy to deal with. If the USB stack he's working with started from a fine commercial framework, he's better off. But he's likely working with something horrible hatched by a former semi-hardware guy a while ago, who was fired because six months into the prior version of the project, management finally realized he could barely spell 'C'. Oh, and the code makes liberal use of #define, and the source doesn't use curly braces, but DO..OD and WHILE..ELIHW, and there is deep, deep misunderstanding of what 'volatile' actually does.
3. Figby also has to work with the host driver team. If they are not actively hiding from the hardware team they are either on the wrong side of the planet, or have absolutely no time to devote to USB issues. The new driver will arrive about three days after Fibgy's "golden master" date.
4. Figby has no time. Everything is feature work. If there are security bugs in the code (... and there are) they have been ignored or deferred as "won't fix" for several product versions. If there are security reviews, they are cursory check-off meetings where people who don't know anything about security make collective shrugs around bugs that are embedded in the product at the level of DNA. The code is swiss-cheese and would take months to make a dent in. Besides, this is a hardware company; isn't the OS supposed to keep us safe?
... now this WebUSB thing lands on Figby's plate. "Marketing really really wants this feature so they can add another checkbox to the package." What are the chances that Figby's going to fix security issues in the product before just turning the thing on for the whole internet to see? Because Friday.
Figby adds command handlers and descriptors for WebUSB. He'll get to the security stuff later, when the rest of everything else works.
Yeah.
This is a horrible idea.