Original issue: https://github.com/Azure/iotedge/issues/852
I'm behind a corporate proxy so I configured the edge node as suggested (https://docs.microsoft.com/en-us/azure/iot-edge/how-to-configure-proxy-support). However I doubt that the the proxy_host in format user:password@proxy_host is used correctly everywhere - still it should work as https://docs.microsoft.com/en-us/azure/iot-edge/how-to-configure-proxy-support documents.
/etc/iotedge/config.yaml:
https_proxy: "http://user:password@proxy-server:8080/"
UpstreamProtocol: "AmqpWs"Logging of the azure IOT Edge container:
If I take a look at the tcpdump I see that the proxy is answering with a "HTTP/1.1 407 Proxy Authentication Required" to the connect request of the edgeAgent container - but the connect from the edgeAgent doesn't provide an authentication header (also it should).
My guess is that the edge correctly detects the proxy credentials (proofed by the logging line "Detected proxy http://[user]:**@[proxy]:8080/") but for whatever reason doesn't use the provided credentials to connect via AmqpWs to the IotHub.
iotedge delegates IoT hub connection details to the device SDK. This comment provides some background: https://github.com/Azure/iotedge/issues/852#issuecomment-663080655
[UNKNOWN]
To confirm, you are able to have the requests forwarded via a proxy, if you set up a proxy without authentication?
From this comment: https://github.com/Azure/iotedge/issues/852#issuecomment-662233451
I encountered this problem first in February 2019, but then we used a proxy without authentication and everything works fine
Specifically, "Credentials didn't seem to make it to the connect telegram to the proxy (sic)" where the proxy is set up with basic authentication.
If the issue is that the ModuleClient doesn't respect the proxy settings when sending the HSM request to the edgelet, then can you test this branch out? https://github.com/Azure/azure-iot-sdk-csharp/tree/timtay/hsmProxySupport
In this branch, the module client should pass the proxy settings down into the HSM request, and the HSM request should go through the configured proxy and should include the proxy authentication header.
Closing this issue due to inactivity
@abhipsaMisra, @R25l84IHeXjIxy6HO1QXn0y0Dq9mt8EN, @timtay-microsoft, thank you for your contribution to our open-sourced project! Please help us improve by filling out this 2-minute customer satisfaction survey
Most helpful comment
From this comment: https://github.com/Azure/iotedge/issues/852#issuecomment-662233451
Specifically, "Credentials didn't seem to make it to the connect telegram to the proxy (sic)" where the proxy is set up with basic authentication.