diff --git a/free/pentest-kit/cmd/pentest_test.go b/free/pentest-kit/cmd/pentest_test.go index fa1060323..ad4ad0f54 100644 --- a/free/pentest-kit/cmd/pentest_test.go +++ b/free/pentest-kit/cmd/pentest_test.go @@ -7,7 +7,6 @@ package main // These tests run offline — no network, no plugin, no Hasura. import ( - "os" "testing" ) @@ -137,13 +136,8 @@ func TestRequirePentestKit_OwnerKeyAccepted(t *testing.T) { // is read from the environment (the primary license env var path). func TestRequirePentestKit_OwnerLicenseEnvVar(t *testing.T) { t.Setenv("NSELF_PENTEST_KIT", "true") - // NSELF_OWNER_LICENSE_KEY is the owner vault variable; simulate it via the - // NSELF_PLUGIN_LICENSE_KEY env var which license.GetKey() checks first. - ownerKey := os.Getenv("NSELF_PLUGIN_LICENSE_KEY_OWNER") - if ownerKey == "" { - ownerKey = "nself_owner_abcdefghijklmnopqrstuvwxyz1234" - } - t.Setenv("NSELF_PLUGIN_LICENSE_KEY", ownerKey) + // A fixed fixture only: a real owner key must never reach a test (X-18). + t.Setenv("NSELF_PLUGIN_LICENSE_KEY", "nself_owner_abcdefghijklmnopqrstuvwxyz1234") err := requirePentestKit() if err != nil {