diff options
author | Ermal <eri@pfsense.org> | 2011-01-10 16:56:56 +0000 |
---|---|---|
committer | Ermal <eri@pfsense.org> | 2011-01-10 17:00:19 +0000 |
commit | d0d70b03bb35824adc977560d615c5d944025341 (patch) | |
tree | ec162449abb60ccca1c1d9eab1608ae81b1fad1f | |
parent | c97297fda0548bf9e2c32dce97ffcea0f2f1bb8e (diff) | |
download | pfsense-d0d70b03bb35824adc977560d615c5d944025341.zip pfsense-d0d70b03bb35824adc977560d615c5d944025341.tar.gz |
Ticket #1013. Force NAS_PORT to be of type integer to avoid it being interpreted as char and generate wrong radius packet.
-rw-r--r-- | usr/local/captiveportal/radius_accounting.inc | 4 | ||||
-rw-r--r-- | usr/local/captiveportal/radius_authentication.inc | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/usr/local/captiveportal/radius_accounting.inc b/usr/local/captiveportal/radius_accounting.inc index 958fabf..67bb523 100644 --- a/usr/local/captiveportal/radius_accounting.inc +++ b/usr/local/captiveportal/radius_accounting.inc @@ -126,7 +126,7 @@ function RADIUS_ACCOUNTING_START($ruleno, $username, $sessionid, $radiusservers, // Default attributes $racct->putAttribute(RADIUS_SERVICE_TYPE, RADIUS_LOGIN); $racct->putAttribute(RADIUS_NAS_PORT_TYPE, RADIUS_ETHERNET); - $racct->putAttribute(RADIUS_NAS_PORT, $nas_port); + $racct->putAttribute(RADIUS_NAS_PORT, $nas_port, 'integer'); $racct->putAttribute(RADIUS_ACCT_SESSION_ID, $sessionid); // Extra data to identify the client and nas @@ -319,4 +319,4 @@ function remainder($bytes) { } -?>
\ No newline at end of file +?> diff --git a/usr/local/captiveportal/radius_authentication.inc b/usr/local/captiveportal/radius_authentication.inc index 1349e8e..142ab0e 100644 --- a/usr/local/captiveportal/radius_authentication.inc +++ b/usr/local/captiveportal/radius_authentication.inc @@ -103,7 +103,7 @@ function RADIUS_AUTHENTICATION($username,$password,$radiusservers,$clientip,$cli // Default attributes $rauth->putAttribute(RADIUS_SERVICE_TYPE, RADIUS_LOGIN); $rauth->putAttribute(RADIUS_NAS_PORT_TYPE, RADIUS_ETHERNET); - $rauth->putAttribute(RADIUS_NAS_PORT, $nas_port); + $rauth->putAttribute(RADIUS_NAS_PORT, $nas_port, 'integer'); // Extra data to identify the client and nas $rauth->putAttribute(RADIUS_FRAMED_IP_ADDRESS, $clientip, addr); @@ -152,4 +152,4 @@ function RADIUS_AUTHENTICATION($username,$password,$radiusservers,$clientip,$cli } -?>
\ No newline at end of file +?> |