mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-27 11:13:24 +02:00
IPsec: Rename ipsec-block script to ipsec-policy
This is a more general name for a script that will be extended soon to do more than just add blocking rules. Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
This commit is contained in:
@@ -152,8 +152,8 @@ void turn_connection_on(char *name, char *type) {
|
||||
"/usr/sbin/ipsec down %s >/dev/null", name);
|
||||
safe_system(command);
|
||||
|
||||
// Reload the IPsec block chain
|
||||
safe_system("/usr/lib/firewall/ipsec-block >/dev/null");
|
||||
// Reload the IPsec firewall policy
|
||||
safe_system("/usr/lib/firewall/ipsec-policy >/dev/null");
|
||||
|
||||
// Reload the configuration into the daemon (#10339).
|
||||
ipsec_reload();
|
||||
@@ -182,8 +182,8 @@ void turn_connection_off (char *name) {
|
||||
// Reload, so the connection is dropped.
|
||||
ipsec_reload();
|
||||
|
||||
// Reload the IPsec block chain
|
||||
safe_system("/usr/lib/firewall/ipsec-block >/dev/null");
|
||||
// Reload the IPsec firewall policy
|
||||
safe_system("/usr/lib/firewall/ipsec-policy >/dev/null");
|
||||
}
|
||||
|
||||
int main(int argc, char *argv[]) {
|
||||
@@ -316,7 +316,7 @@ int main(int argc, char *argv[]) {
|
||||
|
||||
// start the system
|
||||
if ((argc == 2) && strcmp(argv[1], "S") == 0) {
|
||||
safe_system("/usr/lib/firewall/ipsec-block >/dev/null");
|
||||
safe_system("/usr/lib/firewall/ipsec-policy >/dev/null");
|
||||
safe_system("/usr/sbin/ipsec restart >/dev/null");
|
||||
exit(0);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user