Cunning hacker placed 537 000 advertising domains in a locker the size of a flash drive - and all this for a funny $ 5

Depov

Moderator
Staff member
MODERATOR
ULTIMATE
SUPREME
PREMIUM
MEMBER
Joined
Feb 18, 2025
Messages
345
Reaction score
502
Deposit
0$
The Egyptian developer ZedAxis has assembled an advertising filter on the ESP32-C3 microcontroller, which blocks more than 537 thousand domains and costs about $ 5.





The device works as a backup server of domain names for a home network. The main filtering of the developer is performed by the Pi-hole on the single-board computer Raspberry Pi, and the miniature board replaces it during the reboot or shutdown. Thanks to this scheme, home devices do not switch to a regular server without blocking advertising.





ESP32-C3 has only 400 KB of RAM and 4 MB of flash memory, so it is impossible to save hundreds of thousands of addresses in normal text form. The developer decided to store not the domains themselves, but their short digital prints with a length of 40 bits. The 32-bit option would give too many coincidences, and 64-bit values would take an extra place.

Before loading the database, the program downloads open lock lists, deletes comments and repetitive records, and then converts each domain into a digital fingerprint. The resulting values are sorted and recorded in the flash control of the board. When the network receives a request, ESP32 in the same way processes the address of the site and is looking for a match in the database. The domain found is blocked, the remaining requests are redirected to an external server.





According to ZedAxis, the program occupies about 50 KB of RAM, and about 10 milliseconds takes about 10 milliseconds to the request for a request for a blocked domain. The board also runs a simple control panel, where you can see the statistics and add your own addresses to the lock list.





The number of domains depends on memory markup. Typically, the ESP32 stores two copies of the program to securely install wireless updates. If you save this possibility, about 250 thousand addresses are placed in the database. If you refuse wireless updates and give the second section to the blocking list, the capacity will grow to about 537 thousand domains.





The project does not replace full-fledged systems Pi-hole or AdGuard Home. The miniature filter does not lead a detailed query history, does not show statistics for individual devices and offers only basic settings. But the fee consumes several tens of milliampers and can constantly work as a spare network filter.





ZedAxis connected the device to the USB connector on the home optical router Huawei OptiXstar. The connector transmits only power, and the exchange of data passes through the built-in Wi-Fi module. As a result, a small filter is almost completely hidden behind the router and continues to block ads even when the main server is temporarily disconnected.
 
Top Bottom