Repository navigation
Conversation
Add the SigmaConfig store types (server, project, environment, tag, apiKeySecretRef, caBundle, caProvider), register the provider under the sigmaconfig/all_providers build tags, and implement ValidateStore and read-only Capabilities. NewClient returns a not-implemented error until the client lands. Signed-off-by: Elie Kanaan <eliekanaan757@gmail.com>
Add a read-only Sigma Config API client (GET only, one retry on 502/503/504 and timeouts, never on 4xx, same-host pagination), a process-wide 30s snapshot cache with single-flight fills, and GetSecret with property, version (tag) and template-error by-name fallback. Map API errors to messages that never include the API key or values. NewClient reads the key from the referenced Secret and adds caBundle/caProvider to the system roots. GetSecretMap and GetAllSecrets follow in M3. Signed-off-by: Elie Kanaan <eliekanaan757@gmail.com>
GetSecretMap expands a JSON object parameter into one key per field. GetAllSecrets returns parameters matching find.name.regexp under their original names, skips unset ones, rejects find.tags and find.path, and fails the whole read on a template error so a partial result never drops keys from the target Secret. All read paths share one cached snapshot. Add an e2e suite for Sigma Config cases P-01 to P-18 that reads expected values from the API at run time, never prints values, and skips without SIGMA_CONFIG_API_KEY and SIGMA_CONFIG_NOGRANT_API_KEY; it is listed but disabled in the e2e matrix. Pin tidwall/pretty to the workspace version. Signed-off-by: Elie Kanaan <eliekanaan757@gmail.com>
The previous commit dropped the file mode from 100755 to 100644 when the SIGMA_CONFIG_* env lines were added. Signed-off-by: Elie Kanaan <eliekanaan757@gmail.com>
The cloned default transport keeps h2 in NextProtos while HTTP/2 is disabled on it, so HTTP/2 servers such as the Sigma Config API answered with frames the client could not read. Set NextProtos to http/1.1 on every client, and make the test server offer HTTP/2. Signed-off-by: Elie Kanaan <eliekanaan757@gmail.com>
Signed-off-by: Elie Kanaan <eliekanaan757@gmail.com>
Signed-off-by: Elie Kanaan <eliekanaan757@gmail.com>
Signed-off-by: Elie Kanaan <eliekanaan757@gmail.com> # Conflicts: # go.mod
Signed-off-by: Elie Kanaan <eliekanaan757@gmail.com>
Signed-off-by: Elie Kanaan <eliekanaan757@gmail.com>
Security review: Sigma Config providerThis review looks at security before the PR goes upstream to External Secrets. It was AI-assisted and based only on reading the diff at Must fix before upstream1. A failed external pull is reported as "secret missing" ( 2. The API key can leak through redirects ( Should fix3. A failed external pull silently drops the key ( 4. Pagination has no limit ( 5. Server error text is passed verbatim into errors ( 6. A panic in the cache fill can deadlock all Sigma Config reconciles ( 7. Callers waiting on a shared fetch ignore their own context ( 8. 9. Memory use is effectively unbounded ( 10. Upstream housekeeping
What looks sound
|
Report failed external pulls before null values, refuse redirects, bound pagination, keep server text out of errors, make the cache safe on panic and honour waiter contexts, validate caProvider at admission, use a pseudo-version in go.mod.
Review PR for the Sigma Config provider: the M2 code review, plus M3 bulk reads and the M4 docs.
What's in it
sigmaconfigprovider: single reads (property,version/tag),dataFrom.extract,dataFrom.find.name.regexppage_size=1000), 429/Retry-Afterhandling, one retry on 5xx/timeoutscaBundle/caProvider; the client offers only HTTP/1.1Results on Brindlecove staging
Not for merge into
mainhere. After review, this goes upstream as a PR to external-secrets/external-secrets.AI assistance: Claude Code helped write code, tests and docs. I reviewed and tested every change.
🤖 Generated with Claude Code