Proxy server settings do not work on IoT Core

Mickey-0613 21 Reputation points

Our Windows IoT Core devices sit behind a firewall that blocks all outgoing traffic except what goes through a proxy server. We have tried many ways to configure the proxy server settings but all have failed. Note that we have been developing a custom FFU using the IoT Core ADK Addon kit. We are using Windows IoT Core v.10.0.17763.253 LTSC build. However we have tried the below with several versions of IoT Core and have not had success on other versions either.

1) Netsh winhttp set proxy is not a feature in this version of Windows IoT Core (BIG miss guys...ugh)

2) We used Windows Configuration Designer to create a provisioning package and deployed to c$\Windows\Provisioning\Packages. We rebooted several times and tried many provisioning settings, but the proxy server setting does not work. We have successfully changed many other settings with provisioning packages, so we think we are doing it right, but we see no changes being made to the registry and it appears that nothing happens. (this should work..???)

3) We tried WebRequest.DefaultWebProxy = new WebProxy("", false); This did not work.

4) We used the code how-setup-proxy-server-for-ftp-and-vnc-in-windows-10-core-iot-for-imax-6-solo-series by Michael Xu. This partially works. It changes the registry settings below:

HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Internet Settings
IE5_UA_Backup_Flag REG_SZ 5.0
User Agent REG_SZ Mozilla/5.0 (compatible; MSIE 9.0; Win32)
EnableNegotiate REG_DWORD 0x1
ProxyEnable REG_DWORD 0x1
ProxyServer REG_SZ

These changes do enable HttpWebRequests through the proxy for current user. We are able to Invoke-WebRequest and it will go through the proxy.

The problem is that other services like Windows Update, Azure IoT DM Client, and our Azure IoT Hub connections that run in our background applications do not go through the proxy. We can see them being blocked by the firewall. On a desktop, these types of requests use WinHttpSettings, so we tried to change those....

5) We manually edited the WinHttpSettings registry key below. We took the registry key from a Windows PC (where the proxy server works fine for background processes) and copied it to the IoT Core device, but it did not work. No changes to WinHttpSettings seem to direct background traffic through proxy.
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Internet Settings\Connections
WinHttpSettings REG_BINARY 28000000000000000300000016000000687474703D3139322E3136382E312E38373A3830383000000000

Out of ideas and stuck... can't rollout until this is solved. We are not experts in how the InternetSetOption API and IoT Core are working under the covers to determine the proper configuration, if that is even the right way...

Appreciate any help!

Windows for IoT
Windows for IoT
A family of Microsoft operating systems designed for use in Internet of Things (IoT) devices.
380 questions
0 comments No comments
{count} votes

Accepted answer
  1. Michael Xu 336 Reputation points

    As far as i know, Windows Update can not work when the Windows IoT Core using proxy settings, we can not use Netsh winhttp command on Windows IoT Core. For Azure IoT DM Client, and our Azure IoT Hub connections, you may try to use HTTP communication, instead of MQTT or AMQP. In addition , may i know if you know IoT Edge? IoT Edge devices send HTTPS requests to communicate with IoT Hub. If your device is connected to a network that uses a proxy server, you need to configure the IoT Edge runtime to communicate through the server. Proxy servers can also affect individual IoT Edge modules if they make HTTP or HTTPS requests that aren't routed through the IoT Edge hub. Please refer to this document.

    If the answer is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    1 person found this answer helpful.

1 additional answer

Sort by: Most helpful
  1. Shane Russo 1 Reputation point

    Unfortunately I do not have an answer to your question, other than to say I asked the same thing around 2 years ago. After trying everything to get Windows 10 IoT to use the proxy I ended up giving up. I took the device off the network altogether and added a 4G USB dongle to get internet access.

    Not sure if Microsoft is still actively still developing or Windows 10 IoT which is a shame.

    Hopefully someone else can come back with a better answer.