Navigation Menu

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix proxying when target protocol differs from proxy protocol #76

Merged
merged 1 commit into from May 28, 2017

Conversation

rexxars
Copy link
Member

@rexxars rexxars commented May 17, 2017

When you use an HTTP proxy (say, http://proxy.my.enterprise) and an EventSource that lives on an HTTPS host (say, https://espen.codes/sse), the EventSource client parses the target URL, sees an HTTPS URL and tries to use the https module for the outgoing request. The same happens in the reverse situation (http target, https proxy).

This PR fixes this situation, and adds tests for proxying.
Closes #73

@rexxars rexxars merged commit 7ece6ba into EventSource:master May 28, 2017
@rexxars rexxars deleted the fix-proxy-issue branch May 28, 2017 13:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Error behind proxy with Authentication
1 participant