[openwrt/openwrt] wifi-scripts: use OWE + country for 6GHz

LEDE Commits lede-commits at lists.infradead.org
Tue Dec 30 05:46:39 PST 2025


hauke pushed a commit to openwrt/openwrt.git, branch openwrt-25.12:
https://git.openwrt.org/1818f4fbceca41ccb68d679ad546fa65a0e9bc25

commit 1818f4fbceca41ccb68d679ad546fa65a0e9bc25
Author: Hauke Mehrtens <hauke at hauke-m.de>
AuthorDate: Sun Dec 28 23:03:32 2025 +0100

    wifi-scripts: use OWE + country for 6GHz
    
    Wifi on the 6GHz band does not support open networks, configure owe by
    default. 6GHz wifi also needs a country code, configure a broken country
    code '00' by default to hint the user to change it.
    
    Link: https://github.com/openwrt/openwrt/pull/21313
    Signed-off-by: Hauke Mehrtens <hauke at hauke-m.de>
    (cherry picked from commit 01a87f4bd0cdbfc84bbc172920e865c1600f7a45)
---
 package/network/config/wifi-scripts/files/lib/wifi/mac80211.uc | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/package/network/config/wifi-scripts/files/lib/wifi/mac80211.uc b/package/network/config/wifi-scripts/files/lib/wifi/mac80211.uc
index e82525e247..34a7269778 100644
--- a/package/network/config/wifi-scripts/files/lib/wifi/mac80211.uc
+++ b/package/network/config/wifi-scripts/files/lib/wifi/mac80211.uc
@@ -78,7 +78,13 @@ for (let phy_name, phy in board.wlan) {
 
 		band_name = lc(band_name);
 
-		let country, defaults, num_global_macaddr;
+		let country, encryption, defaults, num_global_macaddr;
+		if (band_name == '6g') {
+			country = '00';
+			encryption = 'owe';
+		} else {
+			encryption = 'open';
+		}
 		if (board.wlan.defaults) {
 			defaults = board.wlan.defaults.ssids?.[band_name]?.ssid ? board.wlan.defaults.ssids?.[band_name] : board.wlan.defaults.ssids?.all;
 			country = board.wlan.defaults.country;
@@ -105,7 +111,7 @@ set ${si}.device='${name}'
 set ${si}.network='lan'
 set ${si}.mode='ap'
 set ${si}.ssid='${defaults?.ssid || "OpenWrt"}'
-set ${si}.encryption='${defaults?.encryption || "none"}'
+set ${si}.encryption='${defaults?.encryption || encryption}'
 set ${si}.key='${defaults?.key || ""}'
 
 `);




More information about the lede-commits mailing list