diff options
Diffstat (limited to '')
| -rw-r--r-- | src/ext/Firewall/ca/firewall.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/ext/Firewall/ca/firewall.cpp b/src/ext/Firewall/ca/firewall.cpp index 2a1ef825..eed6f9df 100644 --- a/src/ext/Firewall/ca/firewall.cpp +++ b/src/ext/Firewall/ca/firewall.cpp | |||
| @@ -3,7 +3,7 @@ | |||
| 3 | #include "precomp.h" | 3 | #include "precomp.h" |
| 4 | 4 | ||
| 5 | LPCWSTR vcsFirewallExceptionQuery = | 5 | LPCWSTR vcsFirewallExceptionQuery = |
| 6 | L"SELECT `Name`, `RemoteAddresses`, `Port`, `Protocol`, `Program`, `Attributes`, `Profile`, `Component_`, `Description`, `Direction` FROM `Wix4FirewallException`"; | 6 | L"SELECT `Name`, `RemoteAddresses`, `Port`, `Protocol`, `Program`, `Attributes`, `Profile`, `Component_`, `Description`, `Direction` FROM `Wix5FirewallException`"; |
| 7 | enum eFirewallExceptionQuery { feqName = 1, feqRemoteAddresses, feqPort, feqProtocol, feqProgram, feqAttributes, feqProfile, feqComponent, feqDescription, feqDirection }; | 7 | enum eFirewallExceptionQuery { feqName = 1, feqRemoteAddresses, feqPort, feqProtocol, feqProgram, feqAttributes, feqProfile, feqComponent, feqDescription, feqDirection }; |
| 8 | enum eFirewallExceptionTarget { fetPort = 1, fetApplication, fetUnknown }; | 8 | enum eFirewallExceptionTarget { fetPort = 1, fetApplication, fetUnknown }; |
| 9 | enum eFirewallExceptionAttributes { feaIgnoreFailures = 1 }; | 9 | enum eFirewallExceptionAttributes { feaIgnoreFailures = 1 }; |
| @@ -49,15 +49,15 @@ static UINT SchedFirewallExceptions( | |||
| 49 | ExitOnFailure(hr, "Failed to initialize"); | 49 | ExitOnFailure(hr, "Failed to initialize"); |
| 50 | 50 | ||
| 51 | // anything to do? | 51 | // anything to do? |
| 52 | if (S_OK != WcaTableExists(L"Wix4FirewallException")) | 52 | if (S_OK != WcaTableExists(L"Wix5FirewallException")) |
| 53 | { | 53 | { |
| 54 | WcaLog(LOGMSG_STANDARD, "Wix4FirewallException table doesn't exist, so there are no firewall exceptions to configure."); | 54 | WcaLog(LOGMSG_STANDARD, "Wix5FirewallException table doesn't exist, so there are no firewall exceptions to configure."); |
| 55 | ExitFunction(); | 55 | ExitFunction(); |
| 56 | } | 56 | } |
| 57 | 57 | ||
| 58 | // query and loop through all the firewall exceptions | 58 | // query and loop through all the firewall exceptions |
| 59 | hr = WcaOpenExecuteView(vcsFirewallExceptionQuery, &hView); | 59 | hr = WcaOpenExecuteView(vcsFirewallExceptionQuery, &hView); |
| 60 | ExitOnFailure(hr, "Failed to open view on Wix4FirewallException table"); | 60 | ExitOnFailure(hr, "Failed to open view on Wix5FirewallException table"); |
| 61 | 61 | ||
| 62 | while (S_OK == (hr = WcaFetchRecord(hView, &hRec))) | 62 | while (S_OK == (hr = WcaFetchRecord(hView, &hRec))) |
| 63 | { | 63 | { |
| @@ -150,7 +150,7 @@ static UINT SchedFirewallExceptions( | |||
| 150 | { | 150 | { |
| 151 | hr = S_OK; | 151 | hr = S_OK; |
| 152 | } | 152 | } |
| 153 | ExitOnFailure(hr, "failure occured while processing Wix4FirewallException table"); | 153 | ExitOnFailure(hr, "failure occured while processing Wix5FirewallException table"); |
| 154 | 154 | ||
| 155 | // schedule ExecFirewallExceptions if there's anything to do | 155 | // schedule ExecFirewallExceptions if there's anything to do |
| 156 | if (pwzCustomActionData && *pwzCustomActionData) | 156 | if (pwzCustomActionData && *pwzCustomActionData) |
| @@ -159,16 +159,16 @@ static UINT SchedFirewallExceptions( | |||
| 159 | 159 | ||
| 160 | if (WCA_TODO_INSTALL == todoSched) | 160 | if (WCA_TODO_INSTALL == todoSched) |
| 161 | { | 161 | { |
| 162 | hr = WcaDoDeferredAction(CUSTOM_ACTION_DECORATION(L"RollbackFirewallExceptionsInstall"), pwzCustomActionData, cFirewallExceptions * COST_FIREWALL_EXCEPTION); | 162 | hr = WcaDoDeferredAction(CUSTOM_ACTION_DECORATION5(L"RollbackFirewallExceptionsInstall"), pwzCustomActionData, cFirewallExceptions * COST_FIREWALL_EXCEPTION); |
| 163 | ExitOnFailure(hr, "failed to schedule firewall install exceptions rollback"); | 163 | ExitOnFailure(hr, "failed to schedule firewall install exceptions rollback"); |
| 164 | hr = WcaDoDeferredAction(CUSTOM_ACTION_DECORATION(L"ExecFirewallExceptionsInstall"), pwzCustomActionData, cFirewallExceptions * COST_FIREWALL_EXCEPTION); | 164 | hr = WcaDoDeferredAction(CUSTOM_ACTION_DECORATION5(L"ExecFirewallExceptionsInstall"), pwzCustomActionData, cFirewallExceptions * COST_FIREWALL_EXCEPTION); |
| 165 | ExitOnFailure(hr, "failed to schedule firewall install exceptions execution"); | 165 | ExitOnFailure(hr, "failed to schedule firewall install exceptions execution"); |
| 166 | } | 166 | } |
| 167 | else | 167 | else |
| 168 | { | 168 | { |
| 169 | hr = WcaDoDeferredAction(CUSTOM_ACTION_DECORATION(L"RollbackFirewallExceptionsUninstall"), pwzCustomActionData, cFirewallExceptions * COST_FIREWALL_EXCEPTION); | 169 | hr = WcaDoDeferredAction(CUSTOM_ACTION_DECORATION5(L"RollbackFirewallExceptionsUninstall"), pwzCustomActionData, cFirewallExceptions * COST_FIREWALL_EXCEPTION); |
| 170 | ExitOnFailure(hr, "failed to schedule firewall uninstall exceptions rollback"); | 170 | ExitOnFailure(hr, "failed to schedule firewall uninstall exceptions rollback"); |
| 171 | hr = WcaDoDeferredAction(CUSTOM_ACTION_DECORATION(L"ExecFirewallExceptionsUninstall"), pwzCustomActionData, cFirewallExceptions * COST_FIREWALL_EXCEPTION); | 171 | hr = WcaDoDeferredAction(CUSTOM_ACTION_DECORATION5(L"ExecFirewallExceptionsUninstall"), pwzCustomActionData, cFirewallExceptions * COST_FIREWALL_EXCEPTION); |
| 172 | ExitOnFailure(hr, "failed to schedule firewall uninstall exceptions execution"); | 172 | ExitOnFailure(hr, "failed to schedule firewall uninstall exceptions execution"); |
| 173 | } | 173 | } |
| 174 | } | 174 | } |
