From c562a013ef7e40e3a7f6126a6d327552f2bc557f Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Fri, 4 Sep 2020 16:07:26 +0300 Subject: add ssh relaxed auth mode --- cmd/dserver/main.go | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'cmd') diff --git a/cmd/dserver/main.go b/cmd/dserver/main.go index d889dc9..07f5270 100644 --- a/cmd/dserver/main.go +++ b/cmd/dserver/main.go @@ -34,6 +34,7 @@ func main() { flag.BoolVar(&debugEnable, "debug", false, "Activate debug messages") flag.BoolVar(&displayVersion, "version", false, "Display version") + flag.BoolVar(&config.ServerRelaxedAuthEnable, "relaxedAuth", false, "Enable relaxced SSH auth mode (don't use in production!)") flag.BoolVar(&noColor, "noColor", false, "Disable ANSII terminal colors") flag.IntVar(&pprof, "pprof", -1, "Start PProf server this port") flag.IntVar(&shutdownAfter, "shutdownAfter", 0, "Automatically shutdown after so many seconds") @@ -67,6 +68,10 @@ func main() { logger.Start(ctx, logger.Modes{Server: true, Debug: debugEnable || config.Common.DebugEnable}) + if config.ServerRelaxedAuthEnable { + logger.Fatal("SSH relaxed-auth mode enabled") + } + if pprof > -1 { // For debugging purposes only pprofArgs := fmt.Sprintf("0.0.0.0:%d", pprof) -- cgit v1.2.3