From 1ee488be054ff3f7d6cde1930b50e169625eb0fe Mon Sep 17 00:00:00 2001 From: Simon Let Date: Mon, 27 Apr 2020 23:57:58 +0200 Subject: [PATCH] only listen on localhost --- cmd/daemon/run-server.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/daemon/run-server.go b/cmd/daemon/run-server.go index 370b662..1dba979 100644 --- a/cmd/daemon/run-server.go +++ b/cmd/daemon/run-server.go @@ -64,7 +64,7 @@ func runServer(config cfg.Config, reshHistoryPath, bashHistoryPath, zshHistoryPa mux.Handle("/inspect", &inspectHandler{sesshistDispatch: sesshistDispatch}) mux.Handle("/dump", &dumpHandler{histfileBox: histfileBox}) - server := &http.Server{Addr: ":" + strconv.Itoa(config.Port), Handler: mux} + server := &http.Server{Addr: "localhost:" + strconv.Itoa(config.Port), Handler: mux} go server.ListenAndServe() // signalhandler - takes over the main goroutine so when signal handler exists the whole program exits