Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
crypto/tls, net/http: make PeerCertificates and other information availabe from within an http Handler #1317
The http.ResonseWriter exposes a UsingTLS() method which is good, but the other info stored in the tls.Conn structure is not available. Could the interface be extended/changed to allow access to more of the TLS properties? (this is related to https://golang.org/issue/155) Which compiler are you using (5g, 6g, 8g, gccgo)? 6g Which operating system are you using? linux,x86_64 Which revision are you using? (hg identify) d206790cdd7d tip Please provide any additional information below. I can "patch in" by creating a custom Listener that mimics the tls.Listener and gets the information there, but I can't figure out a way of propagating that info up the stack to the actual handlers without: a) hacking in the http/server.go and adding an accessor there similar to the way UsingTLS() is implemented - which is not real nice I guess. or b) writing a custom equivalent of http.conn/http.response, which is a lot of duplicated code.
Fixed by: http://code.google.com/p/go/source/detail?r=806b068f39b8fbcb160ffc9fec94fcec7a60d832 and http://code.google.com/p/go/source/detail?r=0e09be41e7a534bff8f70d3ff0dd806d0a21a74d
Owner changed to bradf...@golang.org.
Status changed to Fixed.
This issue was closed.