aristanetworks / aristanetworks/goeapi
Does not work when using SOCKS5 proxy
- Dominant language
- Go
- Stars
- 60
- Forks
- 36
- PR merge metrics
- No merged PRs in 30d
Description
Solution:
In eapilib.go, http.Transport is being initialized to set TLSClientConfig. Adding one line would resolve this issue.
```
func (conn *HTTPSEapiConnection) send(data []byte) (*JSONRPCResponse, error) {
...
tr := &http.Transport{
+ Proxy: http.ProxyFromEnvironment, // adding this line resolves the issue
TLSClientConfig: &tls.Config{InsecureSkipVerify: true},
}
}
```
Request you to make this change.
Refer to `DefaultTransport` in https://golang.org/pkg/net/http/
Contributor guide
Research direction
Open eapilib.go and inspect HTTPSEapiConnection.send, where http.Transport is initialized with TLSClientConfig. Read the net/http DefaultTransport and ProxyFromEnvironment documentation first; done means requests honor the configured SOCKS5 proxy environment settings.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- networking
- Issue type
- Bug
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 42/100