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

net/http: fill Request.TLS field if underlying conn implements ConnectionState like net/http2 #56104

Open
WeidiDeng opened this issue Oct 8, 2022 · 2 comments · May be fixed by #56110
Open
Labels
NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone

Comments

@WeidiDeng
Copy link

WeidiDeng commented Oct 8, 2022

What version of Go are you using (go version)?

$ go version
go version go1.19 darwin/amd64

Does this issue reproduce with the latest release?

Yes

What operating system and processor architecture are you using (go env)?

go env Output
$ go env

What did you do?

Using a custom net.Listener to do traffic multiplexing on the same port.
6ccd66 added tls state field for http2 handler, but currently there is no such thing done for stdlib automatically.

Right now in caddy, I'm using ConnContext to associate net.Conn with context and set it myself in http handler, but I'm hoping stdlib will do it automatically.

What did you expect to see?

http.Request.TLS field is automatically set.

What did you see instead?

http.Request.TLS field is not automatically set.

@gopherbot
Copy link

gopherbot commented Oct 9, 2022

Change https://go.dev/cl/440795 mentions this issue: net/http: set tlsState like http2

@seankhliao seankhliao added the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label Oct 9, 2022
@seankhliao
Copy link
Member

seankhliao commented Oct 9, 2022

cc @neild

@seankhliao seankhliao added this to the Unplanned milestone Oct 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants