Allow A-F in hex representaiton of tcclasses MARK column

git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@8496 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
This commit is contained in:
teastep 2008-05-13 14:54:35 +00:00
parent 62b90cfa91
commit 44472dd288
3 changed files with 9 additions and 3 deletions

View File

@ -2,6 +2,8 @@ Changes in 4.2.0-Beta1
1) Fix handling of firewall marks.
2) Allow upper-case A-F in hex representation of MARK in tcclasses.
Changes in 4.1.8
1) Fix some parsing issues with absurd configurations.

View File

@ -77,11 +77,15 @@ Migration Issues.
Problems Corrected in Shorewall 4.2.0 Beta 1
1) Previously, Shorewall was generating an incorrect tc filter when
MARK values were used in /etc/shorewall/tcclasses (the filter
1) Previously, Shorewall-perl was generating an incorrect tc filter
when MARK values were used in /etc/shorewall/tcclasses (the filter
matched when the mark value was equal to the minor class ID rather
than the contents of the MARK column).
2) Shorewall-perl now accepts upper case A through F in the MARK
column of the tcclasses file when the mark value is expressed in
hex. Previously, only lower-case A through F were accepted.
Other Changes in Shoreall 4.2.0 Beta 1.
New Features in Shorewall 4.2.

View File

@ -482,7 +482,7 @@ sub validate_tc_class( $$$$$$ ) {
if ( $devref->{classify} ) {
warning_message "INTERFACE $device has the 'classify' option - MARK value ($mark) ignored";
} else {
fatal_error "Invalid Mark ($mark)" unless $mark =~ /^([0-9]+|0x[0-9a-f]+)$/ && numeric_value( $mark ) <= 0xff;
fatal_error "Invalid Mark ($mark)" unless $mark =~ /^([0-9]+|0x[0-9a-fA-F]+)$/ && numeric_value( $mark ) <= 0xff;
$markval = numeric_value( $mark );
fatal_error "Invalid MARK ($markval)" unless defined $markval;