diff --git a/main.go b/main.go index e08c83f..cd47454 100644 --- a/main.go +++ b/main.go @@ -28,6 +28,8 @@ import ( "golang.org/x/sys/windows/registry" ) +const AppVersion = "2.2" + type Config struct { DomainsOfInterest []string `toml:"domains_of_interest"` DictFile string `toml:"dict_file"` @@ -75,7 +77,7 @@ func main() { setConsoleUTF8() } - fmt.Println("MITM Proxy Server v2.0") + fmt.Println("MITM Proxy Server v" + AppVersion) // Load configuration config, err := loadConfig("config.toml") @@ -330,7 +332,7 @@ func (p *ProxyServer) setupHandlers() { } } - if p.verbose || p.isDomainOfInterest(ctx.Req.Host) { + if p.verbose || (p.debugMode && p.isDomainOfInterest(ctx.Req.Host)) { fmt.Printf( "[%s][INFO][Interest=%v] HTTP Response: %s %s\n", time.Now().Format("20060102T15:04:05.000000"),