mirror of
https://github.com/bolkedebruin/rdpgw.git
synced 2025-07-30 06:16:18 +02:00
Improve configurability
This commit is contained in:
parent
93b31ec9b6
commit
01345b9416
4 changed files with 97 additions and 53 deletions
13
main.go
13
main.go
|
@ -89,7 +89,18 @@ func main() {
|
|||
TLSNextProto: make(map[string]func(*http.Server, *tls.Conn, http.Handler)), // disable http2
|
||||
}
|
||||
|
||||
http.HandleFunc("/remoteDesktopGateway/", protocol.HandleGatewayProtocol)
|
||||
// create the gateway
|
||||
handlerConfig := protocol.HandlerConf{
|
||||
TokenAuth: true,
|
||||
RedirectFlags: protocol.RedirectFlags{
|
||||
Clipboard: true,
|
||||
},
|
||||
}
|
||||
gw := protocol.Gateway{
|
||||
HandlerConf: &handlerConfig,
|
||||
}
|
||||
|
||||
http.HandleFunc("/remoteDesktopGateway/", gw.HandleGatewayProtocol)
|
||||
http.HandleFunc("/connect", handleRdpDownload)
|
||||
http.Handle("/metrics", promhttp.Handler())
|
||||
http.HandleFunc("/callback", handleCallback)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue