mirror of
https://github.com/bolkedebruin/rdpgw.git
synced 2026-03-30 15:36:36 +00:00
TLS updates
This commit is contained in:
@@ -49,7 +49,7 @@ server:
|
|||||||
keyFile: key.pem
|
keyFile: key.pem
|
||||||
# gateway address advertised in the rdp files
|
# gateway address advertised in the rdp files
|
||||||
gatewayAddress: localhost
|
gatewayAddress: localhost
|
||||||
# port to listen on
|
# port to listen on (change to 80 or equivalent if not using TLS)
|
||||||
port: 443
|
port: 443
|
||||||
# list of acceptable desktop hosts to connect to
|
# list of acceptable desktop hosts to connect to
|
||||||
hosts:
|
hosts:
|
||||||
|
|||||||
@@ -143,7 +143,11 @@ func main() {
|
|||||||
http.HandleFunc("/tokeninfo", api.TokenInfo)
|
http.HandleFunc("/tokeninfo", api.TokenInfo)
|
||||||
http.HandleFunc("/callback", api.HandleCallback)
|
http.HandleFunc("/callback", api.HandleCallback)
|
||||||
|
|
||||||
err = server.ListenAndServeTLS("", "")
|
if conf.Server.DisableTLS {
|
||||||
|
err = server.ListenAndServe()
|
||||||
|
} else {
|
||||||
|
err = server.ListenAndServeTLS("", "")
|
||||||
|
}
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Fatal("ListenAndServe: ", err)
|
log.Fatal("ListenAndServe: ", err)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user