Index: chrome/installer/util/advanced_security_firewall_manager_win.h |
diff --git a/chrome/installer/util/advanced_security_firewall_manager_win.h b/chrome/installer/util/advanced_security_firewall_manager_win.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..692d6bb73f53d535e36702702ceeeb76439f6bf3 |
--- /dev/null |
+++ b/chrome/installer/util/advanced_security_firewall_manager_win.h |
@@ -0,0 +1,45 @@ |
+// Copyright 2014 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef CHROME_INSTALLER_UTIL_ADVANCED_SECURITY_FIREWALL_MANAGER_WIN_H_ |
+#define CHROME_INSTALLER_UTIL_ADVANCED_SECURITY_FIREWALL_MANAGER_WIN_H_ |
+ |
+#include <windows.h> |
+#include <netfw.h> |
+ |
+#include "base/basictypes.h" |
+#include "base/files/file_path.h" |
+#include "base/strings/string16.h" |
+#include "base/win/scoped_comptr.h" |
+#include "chrome/installer/util/firewall_manager.h" |
+ |
+namespace installer { |
+ |
+class AdvancedSecurityFirewallManager : public FirewallManager { |
+ public: |
+ AdvancedSecurityFirewallManager(); |
+ virtual ~AdvancedSecurityFirewallManager(); |
+ |
+ bool Init(BrowserDistribution* dist, const base::FilePath& chrome_path); |
+ |
+ // FirewallManager methods. |
+ virtual bool AddUDPFirewallRuleIfAbsent() OVERRIDE; |
+ virtual void DeleteUDPFirewallRule() OVERRIDE; |
+ virtual bool CanUseLocalUDPPort() OVERRIDE; |
+ |
+ private: |
+ base::string16 GetUDPRuleName(); |
+ base::string16 GetUDPRuleDescription(); |
+ base::win::ScopedComPtr<INetFwRule> CreateUDPRule(); |
+ |
+ BrowserDistribution* distribution_; |
+ base::FilePath chrome_path_; |
+ base::win::ScopedComPtr<INetFwPolicy2> firewall_policy_; |
+ |
+ DISALLOW_COPY_AND_ASSIGN(AdvancedSecurityFirewallManager); |
+}; |
+ |
+} // namespace installer |
+ |
+#endif // CHROME_INSTALLER_UTIL_ADVANCED_SECURITY_FIREWALL_MANAGER_WIN_H_ |