Can I change TCP/IP Filetering from batch file?

  • Thread starter Thread starter Brett Chapman
  • Start date Start date
B

Brett Chapman

Does anyone know if there is a way from the command line
or from and API to change the TCP/IP Filtering settings?
Ideally, I would like to open/close ports on an as needed
basis.
 
Hi Brett. Thank-you for your post.

I believe that the filter settings for the "advanced TCP/IP filters" are
kept in the registry. So you should be able to manipulate them
programmatically one way or another. The drawback to using this approach
is that when you make changes to these filters, the system always has to be
rebooted before the changes take affect.

I recommend using IPSec filters instead. Changes to these filters can be
made via a script and changes take affect without rebooting the system.

These article will help you do this:

813878 How to Block Specific Network Protocols and Ports by Using IPSec
http://support.microsoft.com/?id=813878

I hope that helps.

Tim Rains
Product Support Services
Microsoft Corporation

This posting is provided "AS IS" with no warranties, and confers no rights.
 
Back
Top