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

websocket: don't set a WSS multiaddr for accepted unencrypted conns #2199

Merged
merged 1 commit into from
Mar 17, 2023

Conversation

marten-seemann
Copy link
Contributor

Fixes #2198.

@@ -96,7 +100,7 @@ func (l *listener) serve() {

func (l *listener) ServeHTTP(w http.ResponseWriter, r *http.Request) {
scheme := "ws"
if l.server.TLSConfig != nil {
if l.isWss {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we fix the other checks as well?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess there's just the other one in serve

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

@marten-seemann marten-seemann merged commit eeb685f into master Mar 17, 2023
marten-seemann added a commit that referenced this pull request May 9, 2023
marten-seemann added a commit that referenced this pull request May 9, 2023
marten-seemann added a commit that referenced this pull request May 11, 2023
* Revert "websocket: don't set a WSS multiaddr for accepted unencrypted conns (#2199)"

This reverts commit eeb685f.

* Revert "websocket: Don't limit message sizes in the websocket reader (#2193)"

This reverts commit 2fe6600.

* Revert "websocket: Replace gorilla websocket transport with nhooyr websocket transport (#1982)"

* websocket: don't set a WSS multiaddr for accepted unencrypted conns
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.

websocket: accepted connections claim to be WSS even if they are not
2 participants