[openwrt/openwrt] hostapd: add ifname and vlan_id to sta-authorized notifications

LEDE Commits lede-commits at lists.infradead.org
Wed Oct 2 06:20:27 PDT 2024


blogic pushed a commit to openwrt/openwrt.git, branch main:
https://git.openwrt.org/711885ad686ca5f8b4901334ab8f9e94a3ba7438

commit 711885ad686ca5f8b4901334ab8f9e94a3ba7438
Author: John Crispin <john at phrozen.org>
AuthorDate: Wed Sep 18 14:47:31 2024 +0200

    hostapd: add ifname and vlan_id to sta-authorized notifications
    
    Signed-off-by: John Crispin <john at phrozen.org>
---
 package/network/services/hostapd/src/src/ap/ubus.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/package/network/services/hostapd/src/src/ap/ubus.c b/package/network/services/hostapd/src/src/ap/ubus.c
index 2d9a48d368..d84d41f930 100644
--- a/package/network/services/hostapd/src/src/ap/ubus.c
+++ b/package/network/services/hostapd/src/src/ap/ubus.c
@@ -1870,6 +1870,9 @@ void hostapd_ubus_notify_authorized(struct hostapd_data *hapd, struct sta_info *
 
 	blob_buf_init(&b, 0);
 	blobmsg_add_macaddr(&b, "address", sta->addr);
+	if (sta->vlan_id)
+		blobmsg_add_u32(&b, "vlan", sta->vlan_id);
+	blobmsg_add_string(&b, "ifname", hapd->conf->iface);
 	if (auth_alg)
 		blobmsg_add_string(&b, "auth-alg", auth_alg);
 




More information about the lede-commits mailing list