MWB: Fix firewall rule to allow remote connections from IPs outside the local subnet (#39595)

* remove unnecessary restrict for local subnet only in firewal

* remoteip set to any
This commit is contained in:
Kai Tao
2025-05-21 13:10:03 +08:00
committed by GitHub
parent 9b3f8951f8
commit bdf0b5ea23

View File

@@ -567,7 +567,7 @@ public:
executable_args.append(L"\" & echo \"Adding an inbound firewall rule for PowerToys.MouseWithoutBorders.exe\"");
executable_args.append(L" & netsh advfirewall firewall add rule name=\"PowerToys.MouseWithoutBorders\" dir=in action=allow program=\"");
executable_args.append(executable_path);
executable_args.append(L"\" enable=yes remoteip=LocalSubnet profile=any protocol=tcp & pause\"");
executable_args.append(L"\" enable=yes remoteip=any profile=any protocol=tcp & pause\"");
SHELLEXECUTEINFOW sei{ sizeof(sei) };
sei.fMask = { SEE_MASK_NOCLOSEPROCESS | SEE_MASK_FLAG_NO_UI };