mirror of
https://gitlab.torproject.org/tpo/anti-censorship/pluggable-transports/snowflake.git
synced 2025-10-13 20:11:19 -04:00
Use Manager.HTTPHandler for automatic TLS support.
This is needed since the recent removal of the TLS-SNI challenge types. https://community.letsencrypt.org/t/tls-sni-challenges-disabled-for-most-new-issuance/50316 The HTTP-01 challenge type requires an additional listener on port 80.
This commit is contained in:
parent
9ab8ea3df4
commit
fcc274ac68
2 changed files with 7 additions and 2 deletions
|
@ -260,6 +260,10 @@ func main() {
|
|||
HostPolicy: autocert.HostWhitelist(acmeHostnames...),
|
||||
Email: acmeEmail,
|
||||
}
|
||||
go func() {
|
||||
log.Printf("Starting HTTP-01 listener")
|
||||
log.Fatal(http.ListenAndServe(":80", certManager.HTTPHandler(nil)))
|
||||
}()
|
||||
|
||||
server.TLSConfig = &tls.Config{GetCertificate: certManager.GetCertificate}
|
||||
err = server.ListenAndServeTLS("", "")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue