summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2005-09-27 17:00:20 +0000
committerScott Ullrich <sullrich@pfsense.org>2005-09-27 17:00:20 +0000
commit1de584c9079f60374794ece3fc9d9caad44d3caa (patch)
treebcbfa1bf4742606915c7a8c35fa1a2cc59da6fe7 /etc
parent5b0272bf56f4df0a562b2c90693925a294bc1c5d (diff)
downloadpfsense-1de584c9079f60374794ece3fc9d9caad44d3caa.zip
pfsense-1de584c9079f60374794ece3fc9d9caad44d3caa.tar.gz
pass through mac entries should always exist. the reason
for this is because we do not have native mac address filtering mechanisms. this allows us to filter by mac address easily and get around this limitation. I consider this a bug in m0n0wall and pfSense as m0n0wall does not have native mac filtering mechanisms as well.
Diffstat (limited to 'etc')
-rw-r--r--etc/inc/captiveportal.inc15
1 files changed, 15 insertions, 0 deletions
diff --git a/etc/inc/captiveportal.inc b/etc/inc/captiveportal.inc
index 68fc08d..1ec1f9c 100644
--- a/etc/inc/captiveportal.inc
+++ b/etc/inc/captiveportal.inc
@@ -556,6 +556,21 @@ function captiveportal_passthrumac_configure() {
fclose($fd);
}
+ /* pass through mac entries should always exist. the reason
+ * for this is because we do not have native mac address filtering
+ * mechanisms. this allows us to filter by mac address easily
+ * and get around this limitation. I consider this a bug in
+ * m0n0wall and pfSense as m0n0wall does not have native mac
+ * filtering mechanisms as well. -Scott Ullrich
+ */
+ if (is_array($config['captiveportal']['passthrumac'])) {
+ mwexec("/sbin/ipfw delete 50");
+ foreach($config['captiveportal']['passthrumac'] as $ptm) {
+ /* create the pass through mac entry */
+ mwexec("/sbin/ipfw add 50 skipto 50000 from any to any MAC {$ptm['mac']}");
+ }
+ }
+
captiveportal_unlock();
return 0;
OpenPOWER on IntegriCloud