Example #1
0
File: UPnP.cs Project: nhz2f/xRAT
 public static void RemovePort(ushort port)
 {
     try
     {
         IStaticPortMappingCollection portMap = new UPnPNAT().StaticPortMappingCollection;
         if (portMap != null)
             portMap.Remove(port, "TCP");
     }
     catch
     { }
 }
Example #2
0
 public static void RemovePort(ushort port)
 {
     try
     {
         IStaticPortMappingCollection portMap = new UPnPNAT().StaticPortMappingCollection;
         if (portMap != null)
         {
             portMap.Remove(port, "TCP");
         }
     }
     catch
     { }
 }
Example #3
0
 public static void RemovePort()
 {
     try
     {
         IStaticPortMappingCollection portMap = new UPnPNAT().StaticPortMappingCollection;
         if (portMap != null)
         {
             portMap.Remove(Port, "TCP");
         }
         IsPortForwarded = false;
     }
     catch
     {
     }
 }
Example #4
0
File: UPnP.cs Project: he0x/xRAT
 public static void RemovePort()
 {
     try
     {
         IStaticPortMappingCollection portMap = new UPnPNAT().StaticPortMappingCollection;
         if (portMap != null)
             portMap.Remove(Port, "TCP");
         IsPortForwarded = false;
     }
     catch
     {
     }
 }
Example #5
0
        public static void Remove(int eport, ProtocolType type)
        {
            var mapping = new UPnPNAT().StaticPortMappingCollection;

            mapping.Remove(eport, type.ToString().ToUpper());
        }