ARTEX - AI autonomous penetration testing system (English translation; upstream: Autumn-27/ARTEX, AGPL-3.0)
Go aiai-agentsautonomous-agentsbug-bountydockergolanglinuxllmmcpnextjspenetration-testingpentestpostgresqlreareactred-teamsecuritysecurity-automationsqlitetypescript
fix(server): seal ARTEX_PG_PASSWORD with the other startup secrets
Coff0xc8b4f890e61ec
diff --git a/server/envseal.go b/server/envseal.goindex 165552d..9df3620 100644--- a/server/envseal.go+++ b/server/envseal.go@@ -13,8 +13,9 @@ import (// Sealing the server environment. ScrubSecretEnv removes the secrets from the Go// environment, but the kernel keeps the environment block the process was executed-// with: /proc/<pid>/environ still shows ARTEX_PG_DSN, ARTEX_SECRET_KEY and the API-// keys to any process that can read it. SealProcessEnv re-executes the server once,+// with: /proc/<pid>/environ still shows ARTEX_PG_DSN, ARTEX_PG_PASSWORD,+// ARTEX_SECRET_KEY and the API keys to any process that can read it.+// SealProcessEnv re-executes the server once,// with those variables left out of the block; the values travel to the new image// through an inherited pipe and are put back into the Go environment there, so the// readers that run next see the same configuration.diff --git a/server/envseal_linux_test.go b/server/envseal_linux_test.goindex 3a50e09..a11176b 100644--- a/server/envseal_linux_test.go+++ b/server/envseal_linux_test.go@@ -51,6 +51,7 @@ func TestSealedEnvironmentHandoff(t *testing.T) {}want := map[string]string{"ARTEX_PG_DSN": "postgres://artex:p@[email protected]/artex?sslmode=disable\nsecond line\twith tab",+ "ARTEX_PG_PASSWORD": "p/ss w@rd?#%","ARTEX_SECRET_KEY": "","ANTHROPIC_API_KEY": "sk-ant-test","OPENAI_API_KEY": "=leading-equals",