diff options
author | Ermal <eri@pfsense.org> | 2013-02-12 12:01:09 +0000 |
---|---|---|
committer | Ermal <eri@pfsense.org> | 2013-02-12 12:01:29 +0000 |
commit | 096f2962a95269a4ac69a38fd615d6e4da0256eb (patch) | |
tree | c2542532a609450f3f344e66bc1d0812f542f9a5 /sbin | |
parent | 443c28221707827578d1df3f7b5fbace62513d7d (diff) | |
download | pfsense-096f2962a95269a4ac69a38fd615d6e4da0256eb.zip pfsense-096f2962a95269a4ac69a38fd615d6e4da0256eb.tar.gz |
Ticket #1629 Another round of fixes related to state clearing
Diffstat (limited to 'sbin')
-rwxr-xr-x | sbin/dhclient-script | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/sbin/dhclient-script b/sbin/dhclient-script index 272bb77..814d1b9 100755 --- a/sbin/dhclient-script +++ b/sbin/dhclient-script @@ -66,8 +66,7 @@ delete_old_states() { $LOGGER "Comparing IPs: Old: ${OLD_IP} New: ${new_ip_address}" if [ -n "${OLD_IP}" ] && [ "${OLD_IP}" != "${new_ip_address}" ]; then $LOGGER "Removing states from old IP '${OLD_IP}' (new IP '${new_ip_address}')" - /sbin/pfctl -k 0.0.0.0/0 -k ${OLD_IP}/32 - /sbin/pfctl -k ${OLD_IP}/32 + /sbin/pfctl -i $interface -Fs pfctl -K ${OLD_IP}/32 fi fi @@ -82,8 +81,7 @@ delete_old_states() { $LOGGER "Comparing Routers: Old: ${OLD_ROUTER} New: ${new_routers}" if [ "${OLD_ROUTER}" != "${new_routers}" ]; then $LOGGER "Removing states through old gateway '${OLD_ROUTER}' (new gateway '${new_routers}')" - /sbin/pfctl -i $interface -k 0.0.0.0/0 -k ${OLD_ROUTER}/32 - /sbin/pfctl -i $interface -k ${OLD_ROUTER}/32 -k 0.0.0.0/0 + /sbin/pfctl -i $interface -Fs -G ${OLD_ROUTER} fi fi } |