Set Interface Category in Windows

If a proxy is required by programs in Hyper-V virtual machines...

Sometimes, some programs in a Hyper-V virtual machine need to access some network resources outside firewalls. Therefore, a proxy is required. However, by no means should we set the proxy in the virtual machine, taking into consideration the fact that setting up proxy in the virtual machine is a waste of time and resources. Instead, we can set the proxy in the host machine, and then share the proxy to the virtual machine.

  1. Before we start, we need to make sure that the proxy program is available for private network.

  2. Get network interfaces with Get-NetConnectionProfile.

  3. Set the interface category to private with Set-NetConnectionProfile.

    Set-NetConnectionProfile -InterfaceIndex <InterfaceIndex> -NetworkCategory Private
Built with Hugo
Theme Stack designed by Jimmy