Repository navigation
fix: treat only entries of root-level maps as identifier names - #11
Merged
Merged
Conversation
An automated security review of the last commit of PR #10 found that every key under a map named mcpServers, servers, mcp, plugins, projects or profiles counted as an identifier, at any depth and for any value. A string under a secret name inside such a map, `"mcp": { "apiKey": "…" }`, was therefore no longer redacted by name. Entry maps are now matched by their path from the document root (mcpServers, mcp.servers, enabledPlugins, ...), and only an entry — an object, or a plugin's on/off switch — is named by an identifier. Strings beside the entries, and maps of the same name nested elsewhere, keep the usual rules.
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 48 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Owner
Author
|
@codex review |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
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.
What
This is a follow-up to #10. The automated security review of #10's last commit (which added the entry-map exemption) raised a fail-open:
mcpServers,servers,mcp,plugins,projectsorprofilescounted as an identifier."mcp": { "apiKey": "…" }was no longer redacted by name.How
mcpServers,mcp.servers,enabledPlugins,extraKnownMarketplaces, …true/false).isSecretKeyto leaves, so it needs no change.Regression test:
"treats only entries (objects, plugin switches) of root-level entry maps as names".Checklist
npm run typecheckpassesnpm run testpasses (672 tests)npm run buildsucceedsSecurity impact
This tightens redaction back to
main's level for strings under generic map names, while MCP server names and plugin ids stay identifiers. On the maintainer's real config files nothing changes compared with #10; across all 2635 backed-up text files, no line changes thatmainleft alone.Release
This is a
fix:commit, so it ships as 1.0.2 after merge.