Skip to main content

Firewall

Open inbound or outbound exceptions in Windows Firewall for your application.

Applies to: MSI and MSIX.


firewallExceptions – add firewall exceptions

Properties

PropertyTypeRequiredDefaultDescription
namestringyesDisplay name in wf.msc.
pathstringyesFull path to the file. Can be inside or outside the package.
boundstring[]yesSubset of ["in", "out"].
profilestring[]yesSubset of ["private", "public", "domain", "any"].
protocolenumyesOne of "tcp", "udp", "any". (Single string, not an array.)

Examples

Outbound TCP for the updater on private/domain networks

"firewallExceptions": [
{
"name": "My Application Updater - Outbound",
"path": "$.installDir\\My Application.Service.exe",
"bound": ["out"],
"profile": ["private", "domain"],
"protocol": "tcp"
}
]

Inbound and outbound, UDP, all profiles

{
"name": "My Application Discovery",
"path": "$.installDir\\MyApp.exe",
"bound": ["in", "out"],
"profile": ["any"],
"protocol": "udp"
}

MSI vs MSIX behavior

Both formats register Windows Firewall rules at install. The rules are removed on uninstall.


Validation rules

ValidatorCatch
requiredname, path, bound, profile, protocol are mandatory.
valid pathfirewallExceptions.path is syntactically valid.
valid valueEnum-based fields must use a valid value.