Thibaut VARÈNE
1cded2e983
uspot: radius: regroup redundant checks
...
Clarifies intent.
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org >
2023-06-05 13:19:19 +02:00
Thibaut VARÈNE
3219fceb48
uspot: move RADIUS NAS_PORT_TYPE to portal.uc
...
Currently still hardcoded to "19" aka Wireless.
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org >
2023-06-05 13:19:19 +02:00
Thibaut VARÈNE
78c7a3cbfa
uspot: handler-uam: improve auth-client()
...
Simplify the query string parsing logic, allow empty password.
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org >
2023-06-05 13:19:19 +02:00
Thibaut VARÈNE
0a390bea0b
uspot: rename common.uc -> portal.uc
...
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org >
2023-06-05 13:19:19 +02:00
Thibaut VARÈNE
cad21f394e
ucentral-tools: remove dictionary.CoovaChilli
...
This dictionary uses vendor 14122, which is the WISPr vendor code. The
first few attributes defined in this dictionary as integers masked their
WISPr string counterparts, resulting in truncated attributes in RADIUS
requests.
From a quick Google Search, there is no CoovaChilli RADIUS vendor ID, it
seems to use the ChilliSpot ones:
https://support.ignitenet.com/portal/en/kb/articles/what-are-the-supported-radius-attributes-in-coovachilli-captive-portal
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org >
2023-06-05 13:19:19 +02:00
Thibaut VARÈNE
3384986bef
uspot: support ChilliSpot radius ratelimits
...
This commit introduces a helper function "ratelimit_client()", invoked
from allow_client(), which parses the radius reply for known
ratelimiting attributes:
- WISPr-Bandwidth-Max-{Up,Down}
- ChilliSpot-Bandwidth-Max-{Up,Down}
WISPr attributes are expressed in bits/s, ChilliSpot in kbits/s.
If none of the attributes are present, the function is a NOP.
If any of the -Up or -Down is missing, the corresponding limit is not
set. NB: ratelimit currently does not support setting only up OR down
ratelimiting if defaults are not set.
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org >
2023-06-05 13:19:19 +02:00
Thibaut VARÈNE
23073a8ae5
uspot: captive: restart(): include uspot accounting
...
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org >
2023-06-05 13:19:19 +02:00
John Crispin
3ab700de32
ipq807x: fix yuncore fap655 filename
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-06-04 18:04:41 +02:00
John Crispin
454856e5c2
ipq807x: always power on phys when an interface is started
...
Fixes: WIFI-12648
Signed-off-by: John Crispin <john@phrozen.org >
2023-06-04 17:14:18 +02:00
John Crispin
7e4030c0bc
ipq807x: add yuncore fap655 support
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-06-04 12:36:46 +02:00
John Crispin
1deab06c09
ucentral-schema: update to latest HEAD
...
1279e7c fix section names for swconfig devices
Signed-off-by: John Crispin <john@phrozen.org >
2023-06-04 12:34:24 +02:00
John Crispin
a4bc2913e1
ipq807x: add edgecore OAP101e support
...
Fixes: WIFI-12617
Signed-off-by: tanya.singh <tanya.singh@4ipnet.com >
2023-06-01 10:06:39 +02:00
Ken
87dbd3e289
ipq807x: various improvements for CIG-WF-186w
...
1. Using rtl8367c.c file for rtl8367S switch driver to support vlan
2. Configure eth0.1 as WAN and eth0.2 as LAN
3. Add mdio read/write in smi driver followed 5.4 kernel driver
4. add mido clock setting followed 5.4 kernel driver for 186w board
5. Add eth and wifi mac address allocation based of BaseMacAddress
6. Update new bdf for 2G radio
Fixes: WIFI-12650
Signed-off-by: Ken <xshi@actiontec.com >
2023-06-01 08:58:14 +02:00
John Crispin
3f79bc76ac
ucentral-schema: update to latest HEAD
...
137615d add vlan_id to uci sections
Signed-off-by: John Crispin <john@phrozen.org >
2023-06-01 08:58:14 +02:00
John Crispin
4820218fc2
netifd: backport 2 status fixes
...
Fixes: WIFI-12513
Signed-off-by: John Crispin <john@phrozen.org >
2023-06-01 08:58:14 +02:00
John Crispin
b30bcf501a
ramips: fix fap640 mac addresses
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-06-01 08:58:14 +02:00
John Crispin
d9e62da73d
ucentral-client: update to latest HEAD
...
feadd83 handle configuration load/parse error
Fixes: WIFI-12380
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
404a3a4813
ucentral-schema: add strict-isolation example
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
e9f5aec955
ucentral-schema: update to latest HEAD
...
c3d8380 add new dhcp-relay render code
a39410a remove old dhcp-relay code
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
9eada6166c
ucentral-event: add dhcp-relay support
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
e8875a7375
ucode: backport uci.foreach fix
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
33c4c732c9
dnsmasq: drop old option 82 patch
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
2c8e736fa8
ucentral-schema: update to latest HEAD
...
84f53b2 add strict_isolation support
Fixes: WIFI-12577
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
e18d485bdc
ucentral-schema: update to latest HEAD
...
11d7374 always set the developer mode flag when generating capabilities
Fixes: WIFI-12270
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
a1678619be
ucentral-client: update to latest HEAD
...
ffd9d6f indicate crashlog inside the connect reason
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
eec945417d
ucentral-schema: upodate to latest HEAD
...
3afde47 fix generation of bridger block list
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
cd3fb41eb0
ipq807x: update wf196ca 6G BDF file
...
Fixes: WIFI-12538
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
0445caf2b8
ipa807x: various fixes for wf186
...
Fixes: WIFI-12616
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
Venkat Chimata
3bb4304fe4
cybertan: Specify correct images in cybertan profiles
...
Signed-off-by: Venkat Chimata <venkata@shasta.cloud >
2023-05-30 07:56:09 +02:00
Venkat Chimata
2edf5d750c
cybertan: Fix build issues with Cybertan APs
...
Signed-off-by: Venkat Chimata <venkata@shasta.cloud >
2023-05-30 07:56:09 +02:00
John Crispin
89d1213f39
ucentral-client: update to latest HEAD
...
cb5030f crashlog->rebootlog
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
3eb13481c9
ucentral-schema: update to latest HEAD
...
27b1d45 cmd_upgrade: create /ucentral.upgrade
7109e62 add captive portal devices to the bridger block list
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
e2ffc6650c
bridger: re-enable inside default images
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
42be849af8
generic: use latest kernel headers when building eBPF tools
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
Felix Fietkau
d9adc8f7a1
hostapd: fix double free in coa-multi patch
...
Fixes: WIFI-12586
Signed-off-by: Felix Fietkau <nbd@nbd.name >
2023-05-30 07:56:09 +02:00
John Crispin
399f862bb9
ipq807x: various cig,wf660a improvements
...
* fix wifi macs
* reset button had the wrong polarity
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
e73633402c
ipq807x: whitespace cleanup
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
Felix Fietkau
acc3d67cff
wifi-ax: fix mac80211 crash when dealing with AP vlans
...
Signed-off-by: Felix Fietkau <nbd@nbd.name >
2023-05-30 07:56:09 +02:00
John Crispin
c3ab147246
ucentral-schema: update to latest HEAD
...
694fd64 convert vlan_ifaces to an array
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
8cbc9e4fb1
bridger: do not include in builds until it is used
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
John Crispin
3fc4414a84
uspot: fix compile error in radius.c for older GCC
...
/openwrt/build_dir/target-arm_cortex-a7_musl_eabi/uspot/radius.c:264:4: error: label at end of compound statement
default:
^
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-30 07:56:09 +02:00
Thibaut VARÈNE
5d7650a69c
uspot: radius.c: use rc_apply_config()
...
This is required per documentation and may result in segfault if not
used.
Also remove the "servers" settings which is unnecessary in the context
of a single server.
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org >
2023-05-30 07:56:09 +02:00
Thibaut VARÈNE
e4d81ee5b9
uspot: add support for radius location name
...
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org >
2023-05-30 07:56:09 +02:00
Thibaut VARÈNE
8ec07e0588
uspot: partial rewrite of radius-client
...
Streamline the code to make it easier to extend supported attributes,
and to clarify code flow. Improve error checking.
Add licensing information (with permission from John Crispin, original
author).
NB: a few things are still hardcoded toward the end of radius(), to be
revisited.
Cc: John Crispin <john@phrozen.org >
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org >
2023-05-30 07:56:09 +02:00
Thibaut VARÈNE
8262342e1c
uspot: initial documentation of config options
...
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org >
2023-05-30 07:56:09 +02:00
Thibaut VARÈNE
a7341b418e
uspot: introduce mac_passwd and mac_suffix options
...
This carries over two Chilli options used during mac authentication:
- macpasswd, which sets a static password when performing mac-auth
- macsuffix, which allows suffixing the mac address provided as username
These options are implemented in config uspot section as:
- option mac_passwd 'password'
- option mac_suffix 'suffix'
If unset, this commit is a NOP.
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org >
2023-05-30 07:56:09 +02:00
Thibaut VARÈNE
fc80a4aa84
uspot: radius_call: unlink tmp file after exec
...
If debug is disabled, this commit deletes the temporary json files
passed to radius-client.
Furthermore, to reduce the risk of collision, use a different prefix in
accounting.uc ('uacct') vs common.uc ('acct').
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org >
2023-05-30 07:56:09 +02:00
Thibaut VARÈNE
db37e3727d
uspot: captive: honor 'debugoff'
...
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org >
2023-05-30 07:56:09 +02:00
Thibaut VARÈNE
d667c2e2b9
uspot: correctly honor "debug=0" configs
...
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org >
2023-05-30 07:56:09 +02:00
Thibaut VARÈNE
b7f8c7e788
uspot: accouting: spell out config load failure
...
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org >
2023-05-30 07:56:09 +02:00