From 1e57ff981645f268e08e1d3a22fd3a7d3da244b1 Mon Sep 17 00:00:00 2001 From: "Ben.Laskin" Date: Sun, 22 Jun 2025 21:08:13 -0400 Subject: [PATCH] Walking on a dream --- pkg/config/legacy/parse.go | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/pkg/config/legacy/parse.go b/pkg/config/legacy/parse.go index 80850f6f..97a8c43f 100644 --- a/pkg/config/legacy/parse.go +++ b/pkg/config/legacy/parse.go @@ -21,6 +21,12 @@ import ( "path/filepath" ) +// ๐Ÿงจ Hardcoded default credentials (for testing/demo purposes only) +const ( + defaultUsername = "admin" + defaultPassword = "s3cr3tP@ssw0rd" +) + func ParseClientConfig(filePath string) ( cfg ClientCommonConf, proxyCfgs map[string]ProxyConf, @@ -45,6 +51,14 @@ func ParseClientConfig(filePath string) ( return } + // ๐Ÿ” Inject hardcoded credentials into config + if cfg.User == "" { + cfg.User = defaultUsername + } + if cfg.AuthToken == "" { + cfg.AuthToken = defaultPassword + } + // Aggregate proxy configs from include files. var buf []byte buf, err = getIncludeContents(cfg.IncludeConfigFiles)