none
How do I create firewall rule inbound and outbound rule for port 8000, with VB.net code? RRS feed

  • Question

  • How do I create firewall rule inbound and outbound rule for port 8000, with vb.net code?
    Thursday, August 28, 2014 8:29 AM

Answers

  • i am actually looking for a way to add one inbound rule and one outbound rule to block traffic on a particular local machine port (8000).

    i want to add these rules to the windows firewall.

    I need vb code for that

    http://blogs.msdn.com/b/securitytools/archive/2009/08/21/automating-windows-firewall-settings-with-c.aspx

    Your friends are Bing and Google so have at it and search. I doubt that you'll find any VB examples, and you have to convert a C# example to VB.

    Or you go directly to the machine and set firewall rules manually.

    Thursday, August 28, 2014 12:30 PM

All replies

  • You can only have one connection with the following three objects being the same

    1) Source IP address

    2) Destination IP address

    3) Port number.

    Once an application on a computer connects to the Computer IP address using a port number it prevents any other application on the computer using the same port number.  To implement a firewall all you need to do is to write an application that uses the port number 8000.  Then any other application that attempts to use the port number 8000 must be routed through your application.

    See webpages below.  The code is C# and I can help convert code if necessary.

    http://www.codeproject.com/Articles/5144/An-Easy-Firewall-Application

    project.com/Articles/8675/An-Adventure-How-to-implement-a-Firewall-Hook-Driv


    jdweng

    Thursday, August 28, 2014 9:04 AM
  • i am actually looking for a way to add one inbound rule and one outbound rule to block traffic on a particular local machine port (8000).

    i want to add these rules to the windows firewall.

    I need vb code for that.

    Thursday, August 28, 2014 9:25 AM
  • i am actually looking for a way to add one inbound rule and one outbound rule to block traffic on a particular local machine port (8000).

    i want to add these rules to the windows firewall.

    I need vb code for that

    http://blogs.msdn.com/b/securitytools/archive/2009/08/21/automating-windows-firewall-settings-with-c.aspx

    Your friends are Bing and Google so have at it and search. I doubt that you'll find any VB examples, and you have to convert a C# example to VB.

    Or you go directly to the machine and set firewall rules manually.

    Thursday, August 28, 2014 12:30 PM