Get my application to be allowed access through firewall using c#
问题 i am trying to get my application to be allowed through firewall, as I have to do ftp in active and passive mode is not an option as servers are not configured for that. so i tried the below code which compiles fine, I exexcute it using: MyApp.Classes.INetFwMgr mgr = new MyApp.Classes.INetFwMgr(); mgr.AuthorizeApplication(Application.ProductName, Application.StartupPath, NET_FW_SCOPE_.NET_FW_SCOPE_ALL, NET_FW_IP_VERSION_.NET_FW_IP_VERSION_ANY); And the class which does the job: private const