|
The ubiquitous USB socket may hold the key to unlocking all sorts of digital disorder.
At the lowest level, the USB protocol, can be attacked just like current and past TCP stack attacks. Take a look at the USB 1.1 specs. If you find that document painful, try this.
Above the protocol level is the driver level, where there is, I believe, a tremendous probability to find buffer overflows. Consider the design process for a new USB widget. First, the hardware developer selects a few chips to build the device. Next a software developer creates the firmware to run the device. Finally, another developer creates a driver, if needed for the target platform.
How many times has this happened? The hardware guy tells the firmware guy that the device has a 64 byte buffer to transmit data up to the PC. The firmware guy then creates the device's API around that buffer size. Finally, the widget's API is handed to the driver developer who sees that only a 64 byte buffer is needed for incoming data.
int widget_RX_Data(void)
{
char RecvBuf[0x40]; //Smith in HW says this is the limit for the XXXyyy123 chip.
...
}
Can you say BOOM? Somebody is just asking for a stack overflow with that code.
If you think that it is not a problem, because that faulty code is only ever accessed by the device that identifies itself as the widget that the driver was explicitly designed for. You are very wrong, my device can select that same ID, but it won't play nicely with the driver.
|