Browse Source

fix(infisical): dataFrom.find.path should filter by secret path not name (#6086)

Johnvox 4 weeks ago
parent
commit
3cd418b572
1 changed files with 1 additions and 1 deletions
  1. 1 1
      providers/v1/infisical/client.go

+ 1 - 1
providers/v1/infisical/client.go

@@ -174,7 +174,7 @@ func (p *Provider) GetAllSecrets(_ context.Context, ref esv1.ExternalSecretFind)
 
 	selected := map[string][]byte{}
 	for _, secret := range secrets {
-		if (matcher != nil && !matcher.MatchName(secret.SecretKey)) || (ref.Path != nil && !strings.HasPrefix(secret.SecretKey, *ref.Path)) {
+		if (matcher != nil && !matcher.MatchName(secret.SecretKey)) || (ref.Path != nil && !strings.HasPrefix(secret.SecretPath, *ref.Path)) {
 			continue
 		}
 		selected[secret.SecretKey] = []byte(secret.SecretValue)