API Reference
Class
WindowsFirewallManager
Local Windows Firewall rule helpers for service-style inbound TCP rules.
Inheritance
- Object
- WindowsFirewallManager
Methods
public static WindowsFirewallRuleStatusSnapshot CloseInboundTcpPort(Int32 localPort, String ruleName = null) #Returns:
WindowsFirewallRuleStatusSnapshotRemoves a named inbound TCP rule created for a single local port.
Parameters
- localPort System.Int32
- ruleName System.String = null
public static WindowsFirewallRuleStatusSnapshot GetRuleStatus(String ruleName) #Returns:
WindowsFirewallRuleStatusSnapshotReturns the current state of a firewall rule by display name.
Parameters
- ruleName System.String
public static WindowsFirewallRuleStatusSnapshot OpenInboundTcpPort(Int32 localPort, String ruleName = null, FirewallProfileKind profiles = All, String program = null) #Returns:
WindowsFirewallRuleStatusSnapshotCreates or replaces an inbound TCP allow rule for a single local port.
Parameters
- localPort System.Int32
- ruleName System.String = null
- profiles ComputerX.Firewall.FirewallProfileKind = All
- program System.String = null
Inherited Methods
public override Boolean Equals(Object obj) #Returns:
BooleanInherited from Object
Parameters
- obj Object