I need to open a specific port for my application.
I tried using the rule INetFwAuthorizedApplicationfor each application for all ports.
fwMgr.LocalPolicy.CurrentProfile.AuthorizedApplications.Add(app)
Alternatively, open one port for all applications using INetFwOpenPort.
firewallManager.LocalPolicy.CurrentProfile.GloballyOpenPorts.Add(port)
Is there a way to programmatically open only one port for each application programmatically? I can do this manually through the firewall settings.
Marek source
share