Jump to content

Ideas on setting TCP/IP Filters programatically?


Recommended Posts

Hey there...

At my place of work, we enable WinXP's built in TCP/IP Filters (*not* the XP Firewall), and I am trying to pre-set these as part of an Unattended install CD. Th eproblem is that these settings are per adapter, and the adapter registry key is unique per adapter per machine. Are there any scripting geniuses out there who want to take a whack at this?

I figure it will involve dumping "REG QUERY HKLM\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\Interfaces\" to a file then somehow using that file to set the "TCPAllowedPorts" and "RawIPAllowedProtocols" values for each adapter in the file, but I don't know how to do the "file" part.

Anyone?

- John

Link to comment
Share on other sites


Oooo That's also where the registry key is set to turn on the network activity icon in the system tray (blinky lights during net activity next to the clock).

You could do this with a VB script. You would first have to enumerate (get a list of) all the ethernet adapters in the system. Then you would have to figure out which ones were "real" as some are virtual adapters (vpn, dialup connections, etc). Then jump to the registry key you specified and make the change.

Nasty nasty stuff. I'm a batch file guy myself, this type of VB script would take me about 3 days to do properly with the learning curve and all. Any takers?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...