I would like to make a change to an existing Windows Firewall rule, the 'File and Printer Sharing (SMB-in)" private profile remoteip. By default Windows set the private profile remoteip to 'localsubnet', I want to change this to 'any'. I have thousands of Windows computers on the network and I find that they randomly set their network profile to private or public and I don't know the reason behind them. I have tried to use the set-netconnectionprofile to change their network profile to private or public, vice versa but I find that after restart their revert the netconnectionprofile. Because of this problem, I would like to change the default rule of the "File and Printer Sharing (SMB-in)" remoteip to any on the private profile if a computer keeps setting its network connection profile to private. I had tried these: netsh advfirewall firewall set rule name="File and Printer Sharing (SMB-in)" profile=private remoteip=any This shows error "For 'set' command, the 'new' keyword must be present and must not be the last argument provided. netsh advfirewall firewall set rule name="File and Printer Sharing (SMB-in)" profile=private new remoteip=any This shows error "No rule match the specified criteria". What need to be done to make it correct?
