Use constants for default action values

This commit is contained in:
Daniel
2022-10-13 14:18:34 +02:00
parent 106793b56a
commit c99c4aeeff
4 changed files with 18 additions and 14 deletions

View File

@@ -174,7 +174,7 @@ func createSpecialProfile(profileID string, path string) *Profile {
// Resolved domain from the system resolver are checked again when
// attributed to a connection of a regular process. Otherwise, users
// would see two connection prompts for the same domain.
CfgOptionDefaultActionKey: "permit",
CfgOptionDefaultActionKey: DefaultActionPermitValue,
// Explicitly allow incoming connections.
CfgOptionBlockInboundKey: status.SecurityLevelOff,
// Explicitly allow localhost and answers to multicast protocols that
@@ -211,7 +211,7 @@ func createSpecialProfile(profileID string, path string) *Profile {
Source: SourceLocal,
PresentationPath: path,
Config: map[string]interface{}{
CfgOptionDefaultActionKey: "block",
CfgOptionDefaultActionKey: DefaultActionBlockValue,
CfgOptionEndpointsKey: []string{
"+ Localhost",
"+ .safing.io",
@@ -226,7 +226,7 @@ func createSpecialProfile(profileID string, path string) *Profile {
Source: SourceLocal,
PresentationPath: path,
Config: map[string]interface{}{
CfgOptionDefaultActionKey: "block",
CfgOptionDefaultActionKey: DefaultActionBlockValue,
CfgOptionEndpointsKey: []string{
"+ Localhost",
},