summaryrefslogtreecommitdiff
path: root/cmd/vpnweb/vpnweb.go
diff options
context:
space:
mode:
authorkali kaneko (leap communications) <kali@leap.se>2020-01-24 22:24:26 -0600
committerkali kaneko (leap communications) <kali@leap.se>2020-01-24 22:24:26 -0600
commitd3b21e5adc27cbb472e688b7c602e3bd721dec31 (patch)
tree4db7bd5dcdff857e543a64932caa03285f6b4df9 /cmd/vpnweb/vpnweb.go
parentd437b73a8c2dda9884c92d2be44727e66c2289e2 (diff)
protect certificate handler
Diffstat (limited to 'cmd/vpnweb/vpnweb.go')
-rw-r--r--cmd/vpnweb/vpnweb.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/cmd/vpnweb/vpnweb.go b/cmd/vpnweb/vpnweb.go
index 86fc38c..2305d98 100644
--- a/cmd/vpnweb/vpnweb.go
+++ b/cmd/vpnweb/vpnweb.go
@@ -5,6 +5,7 @@ import (
"net/http"
//"0xacab.org/leap/pkg/auth"
+ "0xacab.org/leap/vpnweb/pkg/auth"
"0xacab.org/leap/vpnweb/pkg/config"
"0xacab.org/leap/vpnweb/pkg/web"
)
@@ -22,10 +23,9 @@ func main() {
/* TODO ----
http.HandleFunc("/3/auth", auth.AuthMiddleware(opts.Auth))
http.HandleFunc("/3/refresh-token", auth.RefreshAuthMiddleware(opts.Auth))
- http.HandleFunc("/3/cert", jwtMiddleware.Handler(ch.certResponder))
*/
- http.HandleFunc("/3/cert", ch.CertResponder)
+ http.Handle("/3/cert", auth.AuthMiddleware(opts.Auth, ch))
/* static files */