Repository navigation
fix: harden secret provider plugins and add plugin contribution rules - #190
Merged
Merged
Conversation
Plugins (AWS Secrets Manager, Azure Key Vault, Delinea Secret Server): - Report only fixed text, HTTP status or provider error type on stderr. Itential Gateway copies stderr into its error log unredacted. No more AWS error bodies, credential-process command lines, file paths, managed identity response bodies or tracebacks. - Do not follow redirects (urllib forwards Authorization headers). - Require https:// for Azure and Delinea URLs; URL-encode path and key. - Fail with "key not found" instead of returning the whole secret. READMEs: add "How the Secret Value Is Handled", make the direct test command not print the value, keep credentials out of shell history. Add Secret Provider Plugins rules to STANDARDS.md, a CONTRIBUTING.md checklist item, an AGENTS.md note and .github/scripts/check-secret-plugins.py.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hardens the three secret provider plugins so a failed lookup can't put sensitive data in Itential Gateway's error log, makes the READMEs say plainly how the secret value is handled, and adds contribution rules for secret provider plugins.
Itential Gateway copies a failed plugin's stderr into its error log unredacted, so stderr is the main place a plugin can leak.
Plugins
AWS_CREDENTIAL_PROCESScommand line, file paths, Azure managed identity response bodies, and tracebacks (a top-level handler prints the exception type only).urllibforwards theAuthorizationheader to the redirect target.https://URLs, andpath/keyare URL-encoded.keyis given and the secret is a JSON object without that field, the AWS and Azure plugins now fail with "key not found in secret" instead of returning the whole object.READMEs
config.envdescription said "non-sensitive values". Every--envvalue is sent on stdin, so it now says to keep credentials in files.Contribution rules
STANDARDS.md: Secret Provider Plugins section.CONTRIBUTING.md: checklist item.AGENTS.md: one line..github/scripts/check-secret-plugins.py: regex checks for the patterns above. It reports 0 findings on these plugins. It is not wired into CI.Testing
Run locally with mock servers and marker values, no real secrets:
__typeall return "unknown error".Authorizationheader.keyextraction, with the HTTP layer faked.Not tested: the real AWS, Azure and Delinea services, the Azure IMDS success path, and Itential Gateway 5.5.3 running the patched plugins.