bug with --datestop in fwb_ipt

This commit is contained in:
Vadim Kurland
2008-09-13 16:49:36 +00:00
parent 18d602849c
commit bb14529ff6
3 changed files with 14 additions and 7 deletions
+7
View File
@@ -1,3 +1,10 @@
2008-09-13 Vadim Kurland <vadim@vk.crocodile.org>
* PolicyCompiler_PrintRule.cpp (PrintRule::_printTimeInterval):
fixed bug (no #): compiler for iptables used date entered for the
beginning of the interval in "Time" object both for the beginning
and for the end.
2008-09-12 Vadim Kurland <vadim@vk.crocodile.org>
* GroupObjectDialog.cpp (GroupObjectDialog::applyChanges): fixed
+3 -3
View File
@@ -1156,9 +1156,9 @@ string PolicyCompiler_ipt::PrintRule::_printTimeInterval(PolicyRule *r)
if (eday>0 && emonth>0 && eyear>0)
{
ostr << "--datestop "
<< setw(2) << setfill('0') << syear << "-"
<< setw(2) << setfill('0') << smonth << "-"
<< setw(2) << setfill('0') << sday << "T"
<< setw(2) << setfill('0') << eyear << "-"
<< setw(2) << setfill('0') << emonth << "-"
<< setw(2) << setfill('0') << eday << "T"
<< setw(2) << setfill('0') << ehour << ":"
<< setw(2) << setfill('0') << emin << ":00Z ";
use_timestart_timestop = false;
+4 -4
View File
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE FWObjectDatabase SYSTEM "fwbuilder.dtd">
<FWObjectDatabase xmlns="http://www.fwbuilder.org/1.0/" version="10" lastModified="1219534909" id="root">
<FWObjectDatabase xmlns="http://www.fwbuilder.org/1.0/" version="10" lastModified="1221323996" id="root">
<Library id="sysid99" ro="False" name="Deleted Objects" comment="">
<ICMP6Service id="idE0C27650" code="0" type="1" name="ipv6 dest unreachable" comment="No route to destination"/>
<IPv4 id="id41D295E2" name="firewall30:ppp.200*:ip" comment="" address="192.168.1.1" netmask="255.255.255.0"/>
@@ -7059,7 +7059,7 @@
<Option name="verify_interfaces">False</Option>
</FirewallOptions>
</Firewall>
<Firewall id="id3B0C6380" host_OS="linux24" inactive="False" lastCompiled="1215360278" lastInstalled="1142003872" lastModified="1184801731" platform="iptables" ro="False" version="" name="firewall4" comment="this object is used to test a configuration where firewall has dynamic address ">
<Firewall id="id3B0C6380" host_OS="linux24" inactive="False" lastCompiled="1215360278" lastInstalled="1142003872" lastModified="1221323996" platform="iptables" ro="False" version="" name="firewall4" comment="this object is used to test a configuration where firewall has dynamic address ">
<NAT id="id3B0C6381" name="NAT" comment="" ipv6_rule_set="False" top_rule_set="True">
<NATRule id="id3B0C6382" disabled="False" position="0" comment="">
<OSrc neg="False">
@@ -26433,7 +26433,7 @@ echo '%FWBPROMPT%'; sh /tmp/%FWSCRIPT%
<Option name="verify_interfaces">True</Option>
</FirewallOptions>
</Firewall>
<Firewall id="id4845077415791" host_OS="linux24" inactive="False" lastCompiled="1215360293" lastInstalled="0" lastModified="1215123525" platform="iptables" ro="False" version="1.4.0" name="firewall61" comment="testing time litmiting for iptables 1.4.0&#10;">
<Firewall id="id4845077415791" host_OS="linux24" inactive="False" lastCompiled="1215360293" lastInstalled="0" lastModified="1221323996" platform="iptables" ro="False" version="1.4.0" name="firewall61" comment="testing time litmiting for iptables 1.4.0&#10;">
<NAT id="id484507B715791" name="NAT" comment="" ipv6_rule_set="False" top_rule_set="True"/>
<Policy id="id4845077A15791" name="Policy" comment="" ipv6_rule_set="False" top_rule_set="True">
<PolicyRule id="id4845077B15791" action="Deny" direction="Both" disabled="False" log="True" position="0" comment="">
@@ -33058,7 +33058,7 @@ echo '%FWBPROMPT%'; sh /tmp/%FWSCRIPT%
</ObjectGroup>
<IntervalGroup id="stdid11_1" name="Time" comment="">
<Interval id="id3D6864D0" days_of_week="0,1" from_day="-1" from_hour="1" from_minute="1" from_month="-1" from_weekday="0" from_year="-1" to_day="-1" to_hour="2" to_minute="2" to_month="-1" to_weekday="1" to_year="-1" name="test time 1" comment=""/>
<Interval id="id45F8C4E013056" days_of_week="0,1" from_day="13" from_hour="1" from_minute="1" from_month="3" from_weekday="0" from_year="2007" to_day="1" to_hour="2" to_minute="2" to_month="1" to_weekday="1" to_year="2010" name="test time 2" comment=""/>
<Interval id="id45F8C4E013056" days_of_week="0,1" from_day="13" from_hour="1" from_minute="1" from_month="3" from_weekday="0" from_year="2008" to_day="1" to_hour="2" to_minute="2" to_month="1" to_weekday="1" to_year="2010" name="test time 2" comment=""/>
</IntervalGroup>
<ObjectRef ref="id483F5B7623190"/>
<ObjectRef ref="id4833F6316131"/>