Including XP Firewall Exceptions in a Deployment Job
When packaging an application requiring an exception within the XP firewall, you can automate the exception using netsh.
The XP firewall can be configured using the firewall command of the netsh utility. For full usage options, type the following:
netsh firewall ?
To add a program exception to the firewall, you will need to specify a descriptive name for the exception and the path to the executable. For this example, we'll use a description of SomeAppException and an executable path of C:\Program Files\SomeApp\App.exe.
The following script performs a check to ensure that XP is running, then calls the netsh command.
REM Allow exception in XP Firewall REM Only perform this for XP ver | find "XP" > nul if %ERRORLEVEL% == 0 goto Is_XP goto exit :Is_XP :Run Windows XP-specific commands here. netsh.exe firewall set allowedprogram program = "C:\Program Files\SomeApp\App.exe" name = "SomeAppException" mode = ENABLE profile = ALL :exit






Recent comments
20 min 16 sec ago
2 hours 21 min ago
8 hours 12 min ago
11 hours 28 min ago
12 hours 12 min ago
13 hours 15 min ago
13 hours 42 min ago
14 hours 28 min ago
14 hours 28 min ago
14 hours 40 min ago