mirror of
https://github.com/Telecominfraproject/wlan-ap.git
synced 2025-10-31 18:38:10 +00:00
uspot: fix rate limiting in captive portal/UAM
Fixes: WIFI-12305 Signed-off-by: John Crispin <john@phrozen.org>
This commit is contained in:
@@ -177,8 +177,8 @@ function client_ratelimit(interface, mac, state) {
|
|||||||
let reply = state.data.radius.reply;
|
let reply = state.data.radius.reply;
|
||||||
|
|
||||||
// check known attributes - WISPr: bps, ChiliSpot: kbps
|
// check known attributes - WISPr: bps, ChiliSpot: kbps
|
||||||
let maxup = reply['WISPr-Bandwidth-Max-Up'] || reply['ChilliSpot-Bandwidth-Max-Up']*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;
|
let maxdown = reply['WISPr-Bandwidth-Max-Down'] || (reply['ChilliSpot-Bandwidth-Max-Down']*1000);
|
||||||
|
|
||||||
if (!(+maxdown || +maxup))
|
if (!(+maxdown || +maxup))
|
||||||
return;
|
return;
|
||||||
|
|||||||
Reference in New Issue
Block a user