Browse Source

Bug fix NAT rule variable not being reset

master 2.1p2
Brielle Bruns 1 year ago
parent
commit
cba6893c41
  1. 3
      CHANGELOG
  2. 2
      bin/srfirewall
  3. 2
      lib/iptables.inc
  4. 10
      release.json

3
CHANGELOG

@ -1,3 +1,6 @@
2.1p2 - 02/27/2020
- Fix issue with NAT variable not being reset after being changed
2.1p1 - 01/01/2020
- Refactor NETMAP NAT target so its more flexible. See new example nat.conf file for details

2
bin/srfirewall

@ -19,7 +19,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# Static config options, normally do not need to change
FW_VERSION="2.1p1"
FW_VERSION="2.1p2"
# Important directory locations
FWPREFIX="/usr/local"

2
lib/iptables.inc

@ -459,7 +459,9 @@ function enable_nat {
if [ -e "${FWCONFIGDIR}/ipv${IPVER}/nat.conf" ]; then
${debug} ${DebugColor} "${FUNCNAME}:${DEFAULT_COLOR} read ${FWCONFIGDIR}/ipv${IPVER}/nat.conf successful"
ORIG_NAT=${NAT}
while read -r type srcinterface srcaddress dstinterface dstaddress custom; do
NAT=${ORIG_NAT}
[[ ${type} = \#* ]] && continue
[[ ${type} = "" ]] && continue
([[ ${type} != "SNAT" ]] && [[ ${type} != "MASQ" ]] && [[ ${type} != "NETMAP" ]] && [[ ${type} != "ACCEPT" ]]) \

10
release.json

@ -1,7 +1,7 @@
{
"version": "2.1a1",
"state": "alpha",
"scope": "major changes",
"changes": "Added new custom options for rules in nat, filters, and forwarding (mostly useful with ipsec policy), some code cleanups, changing default rules.",
"download": "https://source.sosdg.org/brielle/srfirewall/repository/archive.tar.bz2?ref=v2.1a1"
"version": "2.1p2",
"state": "stable",
"scope": "minor fixes",
"changes": "See CHANGELOG",
"download": "https://source.sosdg.org/brielle/srfirewall/repository/archive.tar.bz2?ref=v2.1p2"
}
Loading…
Cancel
Save