Compare commits

..

20 Commits

Author SHA1 Message Date
jaspreetsachdev
83db79ea69 Merge pull request #552 from Telecominfraproject/main
Merging  captive portal fixes and strict-forwarding rename
2023-06-27 10:15:21 -04:00
John Crispin
cd461e555e ucentral-schema: update to latest HEAD
9797d7e allow using a shared service->captive for multiple instances
ad7eb8e rename strict-isolation -> strict-forwarding
43c44c1 force spotfilter off prior to config apply
11fffcf captive: fix credentials configuration

Signed-off-by: John Crispin <john@phrozen.org>
2023-06-26 16:24:08 +02:00
John Crispin
9195806206 ucentral-event: rename strict-isolation -> strict-forwarding
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-26 16:20:14 +02:00
John Crispin
9621c21535 spotfilter: add a delay after setting up a captive portal
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-26 16:20:14 +02:00
John Crispin
f74cee802b uspot: fix rate limiting in captive portal/UAM
Fixes: WIFI-12305
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-15 16:22:27 +02:00
Ken
0c7aecde9f ipq807x: CIG WF-186w / update uart pin setting for commucation between ble and soc
Fixes: WIFI-12679
Signed-off-by: Ken <xshi@actiontec.com>
2023-06-15 16:22:27 +02:00
John Crispin
9ab2f5ede9 ucentral-schema: update to latest HEAD
9637b4a disable bridger by default

Fixes: WIFI-12670
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-15 16:22:27 +02:00
John Crispin
a7fe885dc5 radius-gw-proxy: improve header length sanity check
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-15 16:22:27 +02:00
John Crispin
105e55c01a ucentral-schema: update to latest HEAD
48ee8f0 fix cpu core utilisation

Fixes: WIFI-12440
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-15 16:22:27 +02:00
John Crispin
200b759d6f ipq807x: update ion4x_wp dts config
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-15 16:22:27 +02:00
John Crispin
5da87dc07d uspot: fix a typo int he CHAP/PAP handler code
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-15 16:22:27 +02:00
John Crispin
25f42bdcaf ucentral-schema: update to latest HEAD
47f39e9 cmd_upgrade: signature requirement was not properly detected

Fixes: WIFI-12675
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-15 16:22:27 +02:00
John Crispin
43361d0ee7 ucentral-schema: update to latest HEAD
4ddcb12 properly indicate apply errors via an exit() call

Fixes: WIFI-12673
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-15 16:22:27 +02:00
John Crispin
93a8a764a8 ucentral-schema: update to latest HEAD
eea75b3 do not enable vlan accounting for untagged interfaces

Fixes: WIFI-12674
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-15 16:22:27 +02:00
John Crispin
1e515ed1e1 ucentral-schema: update to latest HEAD
04ce23b fix udevstats counters

Fixes: WIFI-12674
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-15 16:22:27 +02:00
John Crispin
78388a8ecf ucentral-event: fix radius rate limiting
Fixes: WIFI-12665
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-15 16:22:27 +02:00
John Crispin
1e1c286f06 ipq40xx: disable the unused container feed
Fixes: WIFI-12672
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-15 16:22:27 +02:00
John Crispin
81f7d7d7ce ramips: enable vlan offloading
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-15 16:22:27 +02:00
John Crispin
2403eb2a87 ipq807x: do not bounce arp frames back in proxy_arp mode
Fixes: WIFI-12653
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-08 11:13:23 +02:00
John Crispin
5a686344e8 ipq807x: update wf-186 5GHz BDF
Fixes: WIFI-12656
Signed-off-by: John Crispin <john@phrozen.org>
2023-06-08 06:32:38 +02:00
12 changed files with 34 additions and 74 deletions

View File

@@ -598,21 +598,13 @@
};
&tlmm {
pinctrl-0 = <&blsp0_uart_pins &phy_led_pins>;
pinctrl-0 = <&phy_led_pins>;
pinctrl-names = "default";
blsp0_uart_pins: uart_pins {
blsp0_uart_rx_tx {
pins = "gpio31", "gpio32", "gpio33", "gpio34";
function = "blsp0_uart1";
bias-disable;
};
};
blsp1_uart_pins: blsp1_uart_pins {
blsp1_uart_rx_tx {
pins = "gpio23", "gpio25", "gpio24", "gpio26";
function = "blsp1_uart2";
pins = "gpio31", "gpio33";
function = "blsp1_uart1";
bias-disable;
};
};

View File

@@ -61,7 +61,7 @@ TARGET_DEVICES += hfcl_ion4xi
define Device/hfcl_ion4xi_wp
DEVICE_TITLE := HFCL ION4Xi_WP
DEVICE_DTS := qcom-ipq6018-hfcl-ion4xi_wp
DEVICE_DTS_CONFIG := config@cp03-c1
DEVICE_DTS_CONFIG := config@cp01-c1
SUPPORTED_DEVICES := hfcl,ion4xi_wp
DEVICE_PACKAGES := ath11k-wifi-hfcl-ion4xi_wp uboot-envtools
endef

View File

@@ -0,0 +1,14 @@
Index: linux-4.4.60-qsdk-11f09717303ecd83c3a64e9efe23f25921dc1016/net/bridge/br_input.c
===================================================================
--- linux-4.4.60-qsdk-11f09717303ecd83c3a64e9efe23f25921dc1016.orig/net/bridge/br_input.c
+++ linux-4.4.60-qsdk-11f09717303ecd83c3a64e9efe23f25921dc1016/net/bridge/br_input.c
@@ -125,7 +125,8 @@ static void br_do_proxy_arp(struct sk_bu
f = __br_fdb_get(br, n->ha, vid);
if (f && ((p->flags & BR_PROXYARP) ||
- (f->dst && (f->dst->flags & BR_PROXYARP_WIFI)))) {
+ (f->dst && (f->dst->flags & BR_PROXYARP_WIFI)))
+ && memcmp(sha, n->ha, 6)) {
arp_send(ARPOP_REPLY, ETH_P_ARP, sip, skb->dev, tip,
sha, n->ha, sha);
BR_INPUT_SKB_CB(skb)->proxyarp_replied = true;

View File

@@ -158,9 +158,15 @@ radius_parse(char *buf, unsigned int len, int port, enum socket_type type, int t
struct radius_tlv *proxy_state = NULL;
char proxy_state_str[256] = {};
void *avp = hdr->avp;
unsigned int len_orig = ntohs(hdr->len);
unsigned int len_orig;
uint8_t localhost[] = { 0x7f, 0, 0, 1 };
if (len < sizeof(*hdr)) {
ULOG_ERR("invalid packet length, %d\n", len);
return -1;
}
len_orig = ntohs(hdr->len);
if (len_orig != len) {
ULOG_ERR("invalid header length, %d %d\n", len_orig, len);
return -1;

View File

@@ -13,6 +13,7 @@ add_interface() {
config_get_bool enabled "$cfg" "configure_spotfilter" 0
[ $enabled -eq 0 ] || /usr/bin/captive generate "$cfg" > /tmp/spotfilter-$cfg.json
ubus call spotfilter interface_add "$(cat /tmp/spotfilter-$cfg.json)"
sleep 5
}
reload_service() {

View File

@@ -93,8 +93,8 @@ let handlers = {
address: notify.data.address,
};
if (notify.data['rate-limit']) {
msg.rate_ingress = notify.data['rate-limit'][0] / 1000000;
msg.rate_egress = notify.data['rate-limit'][1] / 1000000;
msg.rate_ingress = `${notify.data['rate-limit'][0]}`;
msg.rate_egress = `${notify.data['rate-limit'][1]}`;
} else
msg.defaults = hapd.ssid;
ubus.call('ratelimit', 'client_set', msg);
@@ -178,7 +178,7 @@ function hostapd_add(path, obj) {
printf('%.J\n', hostapd[ifname]);
if (+hostapd[ifname].config.strict_isolation)
if (+hostapd[ifname].config.strict_forwarding)
ubus.call('bridger', 'set_device_config', {
name: ifname,
redirect: wan_ports[0]

View File

@@ -4,10 +4,10 @@ PKG_NAME:=ucentral-schema
PKG_RELEASE:=1
PKG_SOURCE_URL=https://github.com/Telecominfraproject/wlan-ucentral-schema.git
PKG_MIRROR_HASH:=a24969c4a04e61bafd90038466934b05860cf42fa03a581b10974cf9378ea466
PKG_MIRROR_HASH:=f8acc28081f960c09839566689a7e31b87ff5fd0b79df80f759ea4e10e8ce2a6
PKG_SOURCE_PROTO:=git
PKG_SOURCE_DATE:=2022-05-29
PKG_SOURCE_VERSION:=1279e7c12220834197597338e587961be95102df
PKG_SOURCE_VERSION:=11fffcf6c8dcbc32a85fa990b7c0d12dd35b0b76
PKG_MAINTAINER:=John Crispin <john@phrozen.org>
PKG_LICENSE:=BSD-3-Clause

View File

@@ -20,7 +20,7 @@ function auth_client(ctx) {
payload.chap_password = ctx.query_string.response;
payload.chap_challenge = ctx.config.uam_secret ? uam.chap_challenge(challenge, ctx.config.uam_secret) : challenge;
} else if ("password" in ctx.query_string) { // allow empty password
payload.password = !ctx.config_uam_secret ? ctx.query_string.password :
payload.password = !ctx.config.uam_secret ? ctx.query_string.password :
uam.password(uam.md5(ctx.config.challenge, ctx.format_mac), ctx.query_string.password, ctx.config.uam_secret);
}
} else {

View File

@@ -177,8 +177,8 @@ function client_ratelimit(interface, mac, state) {
let reply = state.data.radius.reply;
// check known attributes - WISPr: bps, ChiliSpot: kbps
let maxup = reply['WISPr-Bandwidth-Max-Up'] || reply['ChilliSpot-Bandwidth-Max-Up']*1000;
let maxdown = reply['WISPr-Bandwidth-Max-Down'] || reply['ChilliSpot-Bandwidth-Max-Down']*1000;
let maxup = reply['WISPr-Bandwidth-Max-Up'] || (reply['ChilliSpot-Bandwidth-Max-Up']*1000);
let maxdown = reply['WISPr-Bandwidth-Max-Down'] || (reply['ChilliSpot-Bandwidth-Max-Down']*1000);
if (!(+maxdown || +maxup))
return;

View File

@@ -1,52 +0,0 @@
From 7d9a7204d421589a9514cf7f56de170e51889f2a Mon Sep 17 00:00:00 2001
From: John Crispin <john@phrozen.org>
Date: Wed, 4 May 2022 17:08:45 +0200
Subject: [PATCH] ramips: disable switch/bridge offload
This is breaking win10 laptops when vlan_filtering is enabled
Signed-off-by: John Crispin <john@phrozen.org>
---
target/linux/ramips/patches-5.4/992-dsa.patch | 30 +++++++++++++++++++
1 file changed, 30 insertions(+)
create mode 100644 target/linux/ramips/patches-5.4/992-dsa.patch
diff --git a/target/linux/ramips/patches-5.4/992-dsa.patch b/target/linux/ramips/patches-5.4/992-dsa.patch
new file mode 100644
index 0000000000..3c130a5be8
--- /dev/null
+++ b/target/linux/ramips/patches-5.4/992-dsa.patch
@@ -0,0 +1,30 @@
+Index: linux-5.4.158/drivers/net/dsa/mt7530.c
+===================================================================
+--- linux-5.4.158.orig/drivers/net/dsa/mt7530.c
++++ linux-5.4.158/drivers/net/dsa/mt7530.c
+@@ -1608,17 +1608,17 @@ static const struct dsa_switch_ops mt753
+ .port_enable = mt7530_port_enable,
+ .port_disable = mt7530_port_disable,
+ .port_stp_state_set = mt7530_stp_state_set,
+- .port_bridge_join = mt7530_port_bridge_join,
+- .port_bridge_leave = mt7530_port_bridge_leave,
++// .port_bridge_join = mt7530_port_bridge_join,
++// .port_bridge_leave = mt7530_port_bridge_leave,
+ .port_fdb_add = mt7530_port_fdb_add,
+ .port_fdb_del = mt7530_port_fdb_del,
+ .port_fdb_dump = mt7530_port_fdb_dump,
+- .port_vlan_filtering = mt7530_port_vlan_filtering,
+- .port_vlan_prepare = mt7530_port_vlan_prepare,
+- .port_vlan_add = mt7530_port_vlan_add,
+- .port_vlan_del = mt7530_port_vlan_del,
+- .port_mirror_add = mt7530_port_mirror_add,
+- .port_mirror_del = mt7530_port_mirror_del,
++// .port_vlan_filtering = mt7530_port_vlan_filtering,
++// .port_vlan_prepare = mt7530_port_vlan_prepare,
++// .port_vlan_add = mt7530_port_vlan_add,
++// .port_vlan_del = mt7530_port_vlan_del,
++// .port_mirror_add = mt7530_port_mirror_add,
++// .port_mirror_del = mt7530_port_mirror_del,
+ .phylink_validate = mt7530_phylink_validate,
+ .phylink_mac_link_state = mt7530_phylink_mac_link_state,
+ .phylink_mac_config = mt7530_phylink_mac_config,
--
2.25.1

View File

@@ -7,7 +7,6 @@ image: bin/targets/ipq40xx/generic/openwrt-ipq40xx-generic-edgecore_ecw5211-squa
include:
- ucentral-ap
- wifi-ath10k
- container
packages:
- kmod-bluetooth
- kmod-usb-serial