summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2005-05-29 05:21:31 +0000
committerScott Ullrich <sullrich@pfsense.org>2005-05-29 05:21:31 +0000
commit0e7427da1fe55763803477eccc4ecfd493e6af8d (patch)
tree446495c515cc033ce96bab33a0e3066c45deaeaa
parente202c5209253ec75e5315cf3b1e567775d70c5a1 (diff)
downloadpfsense-0e7427da1fe55763803477eccc4ecfd493e6af8d.zip
pfsense-0e7427da1fe55763803477eccc4ecfd493e6af8d.tar.gz
Enforce hard timeouts
-rw-r--r--etc/inc/captiveportal.inc10
1 files changed, 4 insertions, 6 deletions
diff --git a/etc/inc/captiveportal.inc b/etc/inc/captiveportal.inc
index 0f91be9..c013490 100644
--- a/etc/inc/captiveportal.inc
+++ b/etc/inc/captiveportal.inc
@@ -254,11 +254,9 @@ function captiveportal_prune_old() {
$timedout = false;
- /* hard timeout? */
- if ($timeout) {
- if ((time() - $cpdb[$i][0]) >= $timeout)
- $timedout = true;
- }
+ /* hard timeout? */
+ if ((time() - $cpdb[$i][0]) >= $timeout)
+ $timedout = true;
/* if an idle timeout is specified, get last activity timestamp from pf */
// XXX: we need a solution for this.
@@ -281,7 +279,7 @@ function captiveportal_prune_old() {
$cpdb[$i][2]); //clientip
syslog(LOG_INFO,"Authenticated user $cpdb[$i][4] timed out");
}
-
+
mwexec("/sbin/pfctl -t captiveportal -T delete {$cpdb[$i][2]}");
unset($cpdb[$i]);
OpenPOWER on IntegriCloud