aws / amazon-ssm-agent

An agent to enable remote management of your EC2 instances, on-premises servers, or virtual machines (VMs).
https://aws.amazon.com/systems-manager/
Apache License 2.0
1.03k stars 323 forks source link

Diagnostic cli does not detect proxy like agent does. #504

Open henrivdr01 opened 1 year ago

henrivdr01 commented 1 year ago

The diagnostic cli does not detect the proxy setting on Windows the same way as the agent does. The agent goes through the documented order of methods to read the settings. But the cli only reads the system environment variables -

The result is that the diagnostics is not a true reflection of the agent's connectivity.

I had a look at the code, and it seems like the cli calls GetProxyConfig() in https://github.com/aws/amazon-ssm-agent/blob/mainline/agent/proxyconfig/proxy.go instead of https://github.com/aws/amazon-ssm-agent/blob/mainline/agent/proxyconfig/proxy_windows.go