In computing, firmware is a computer program that is embedded in a hardware device, for example a microcontroller. It can also be provided on flash memory or as a binary image file that can be uploaded onto existing hardware by a user.
As its name suggests, firmware is somewhere between hardware and software. Like software, it is a computer program which is executed by a microprocessor or a microcontroller. But it is also tightly linked to a piece of hardware, and has little meaning outside of it.
Firmware may expose an externally accessible interface. For example, in some modem implementations the firmware is not directly accessible, but is part of a combination of hardware and firmware that responds to commands from the host system.
Firmware has traditionally been stored in ROM; however cost and performance requirements have driven component vendors to adopt various replacements, including non-volatile media such as EEPROM and Flash, or SRAM solutions, such as the firmware loaded by an operating system device driver, as described below.
Firmware in many devices can now be updated without the need for additional hardware, often through the use of vendor-provided software.
The easiest firmware to update is typically the system boot-related firmware, such as the BIOS in PCs. Some devices, such as video adapters and modems, frequently rely on firmware that is loaded dynamically by the operating system device driver, and thus is updated through the operating system update mechanisms entirely transparent to the user.
In contrast, storage device firmware is rarely updated with the same consistency as other parts of the system. Further, the mechanisms for detecting firmware versions and updating them are not standardized. As a result, these devices tend to have a significantly higher percentage of firmware-driven functionality issues, as compared to other parts of a modern computer system.
These hacks usually take advantage of the firmware update facility on many devices to install or run themselves. Some, however, must resort to exploits in order to run, because the manufacturer has attempted to lock the hardware to stop it from running unlicensed code.