Brussels / 1 & 2 February 2025

schedule

APuP: A Hundred-Line Hack to Make Wi-Fi Great Again


In many scenarios, such as community networks, the need to maximize the possible communication paths between nodes arises. In a classical AP-STA approach, it is not possible to guarantee communication between all nodes in every scenario, even by resorting to very complex configurations.

To overcome this issue, ad-hoc mode was used in the past, which solved the basic connectivity problem. However, its implementation was not of high quality, and its design had significant flaws, which eventually led to it becoming unmaintained after a few years. Luckily, as ad-hoc mode became outdated, 802.11s emerged with some improvements. However, certain design choices—such as the complex methods for bridging other networks and routing between nodes—were fossilized into the standard, increasing Wi-Fi driver complexity. This ultimately led to its silent demise. New radio drivers and firmware do not support 802.11s well. New Wi-Fi standards do not bring many improvements to 802.11s mesh mode, although they significantly improve AP-STA modes. Nonetheless, the need for nodes to communicate with anyone in range remains strong

In this context, while searching for a modern solution, I began asking myself: is there a hard-to-resolve problem that prevents AP nodes in sight from communicating directly with each other? After discussing my ideas with Felix Fietkau (nbd), we agreed that it might be possible for AP nodes to communicate directly with each other. Since AP mode receives the most support and improvements, we realized that with slight modifications, we could enable all APs in range to communicate with one another. This could solve a problem that has plagued Wi-Fi since its inception. With a bit of luck and a lot of persistence, I demonstrated that seamless AP-AP communication is possible by modifying the hostapd code, without requiring any kernel or driver changes.

Within a few months, this interesting experiment evolved into a new mode named APuP, now included by default in both OpenWrt and DD-WRT. It opens a new rabbit hole that could make Wi-Fi development and usage exciting again, potentially rendering Ad-Hoc, WDS, 802.11s, Multi-AP, Wi-Fi Direct, and EasyMesh obsolete.

Let’s embark on a journey through this code, and then we’ll have even more fun digging together 🕳️🐇⏰.

https://openwrt.org/ https://gitlab.com/g10h4ck/hostap/-/commit/6bb15f81e6857989c0b722fc1a49275492114148

Speakers

Photo of Gioacchino Mazzurco | G10h4ck Gioacchino Mazzurco | G10h4ck