mirror of
https://github.com/fwbuilder/fwbuilder
synced 2026-03-19 09:47:20 +01:00
see #2551 making sure rules that have route-to option get the call to setRoute() in the importer
This commit is contained in:
parent
d98250b272
commit
6f842f1b99
@ -870,6 +870,8 @@ void PFImporter::pushPolicyRule()
|
|||||||
.arg(rs.address.c_str()).arg(rs.netmask.c_str());
|
.arg(rs.address.c_str()).arg(rs.netmask.c_str());
|
||||||
}
|
}
|
||||||
ropt->setStr("pf_route_opt_addr", route_opt_addr.join(",").toStdString());
|
ropt->setStr("pf_route_opt_addr", route_opt_addr.join(",").toStdString());
|
||||||
|
|
||||||
|
rule->setRouting( ! ropt->getStr("pf_route_option").empty());
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
@ -103,6 +103,12 @@ void PFImporter::run()
|
|||||||
int pass = 0;
|
int pass = 0;
|
||||||
while (1)
|
while (1)
|
||||||
{
|
{
|
||||||
|
if (fwbdebug)
|
||||||
|
{
|
||||||
|
qDebug() << "################################";
|
||||||
|
qDebug() << "Pass " << pass;
|
||||||
|
}
|
||||||
|
|
||||||
QMapIterator<QString, QString> it(macros);
|
QMapIterator<QString, QString> it(macros);
|
||||||
while (it.hasNext())
|
while (it.hasNext())
|
||||||
{
|
{
|
||||||
@ -114,6 +120,13 @@ void PFImporter::run()
|
|||||||
whole_input.replace(macro_instance, macro_value);
|
whole_input.replace(macro_instance, macro_value);
|
||||||
}
|
}
|
||||||
QRegExp any_macro_instance("\\$\\w+\\W");
|
QRegExp any_macro_instance("\\$\\w+\\W");
|
||||||
|
|
||||||
|
if (fwbdebug)
|
||||||
|
{
|
||||||
|
qDebug() << "pf.conf file after line unfolding and macro substitution:";
|
||||||
|
qDebug() << whole_input;
|
||||||
|
}
|
||||||
|
|
||||||
if (! whole_input.contains(any_macro_instance)) break;
|
if (! whole_input.contains(any_macro_instance)) break;
|
||||||
pass++;
|
pass++;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user