diff options
author | falbertopl <falbertopl@yahoo.com> | 2013-07-02 21:39:06 -0600 |
---|---|---|
committer | Ermal <eri@pfsense.org> | 2013-07-03 06:54:40 +0000 |
commit | 51f98d0dcc69f3de22e70d1a1cb7c30e44c5c49f (patch) | |
tree | b4fca66d0d4878b4475bbd51deeac26882b8324d /etc/inc | |
parent | c49b7c50afa5b6393b93acc88d5d47d5a108664f (diff) | |
download | pfsense-51f98d0dcc69f3de22e70d1a1cb7c30e44c5c49f.zip pfsense-51f98d0dcc69f3de22e70d1a1cb7c30e44c5c49f.tar.gz |
modified radius function to release the pineno
modified radius function to release the pinene if the client is not authenticated properly, and modified function captiveportal_get_next_dn_ruleno to initially takes the value 2000 for the first pipeno.
Diffstat (limited to 'etc/inc')
-rw-r--r-- | etc/inc/captiveportal.inc | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/etc/inc/captiveportal.inc b/etc/inc/captiveportal.inc index 1c2b89a..873dcdb 100644 --- a/etc/inc/captiveportal.inc +++ b/etc/inc/captiveportal.inc @@ -3,7 +3,7 @@ captiveportal.inc part of pfSense (http://www.pfSense.org) Copyright (C) 2004-2011 Scott Ullrich <sullrich@gmail.com> - Copyright (C) 2009-2012 Ermal Luçi <eri@pfsense.org> + Copyright (C) 2009-2012 Ermal Lu�i <eri@pfsense.org> Copyright (C) 2003-2006 Manuel Kasper <mk@neon1.net>. originally part of m0n0wall (http://m0n0.ch/wall) @@ -1228,7 +1228,9 @@ function radius($username,$password,$clientip,$clientmac,$type, $radiusctx = nul $auth_list, $pipeno, $radiusctx); - } + } else { + captiveportal_free_dn_ruleno($pipeno); + } return $auth_list; } @@ -1357,9 +1359,9 @@ function captiveportal_get_next_dn_ruleno($rulenos_start = 2000, $rulenos_range_ } } else { $rules = array_pad(array(), $rulenos_range_max, false); + $ruleno = $rulenos_start; $rules[$rulenos_start] = "used"; $rules[++$rulenos_start] = "used"; - $ruleno = $rulenos_start; } file_put_contents("{$g['vardb_path']}/captiveportaldn.rules", serialize($rules)); unlock($cpruleslck); |