Skip to content

Navigation Menu

Sign in
Sign up

Use Proxy For websockets #29

Unanswered
sdoshidensity asked this question in Q&A
Discussion options

How can we use proxy for websockets?

url1, err := url.Parse("http://dummy.com") // proxy url
fmt.Println(url1, err)
fialer := websocket.DefaultDialer
fialer.Proxy = transport.ProxyURL(url1)

con, res, err := fialer.Dial(m.wsEndpoint, nil)
if err != nil {
fmt.Println(err, "====================================", res)
return err
}

this is giving **Proxy Authentication Required** error.
You must be logged in to vote

Replies: 0 comments

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant

AltStyle によって変換されたページ (->オリジナル) /