Repository navigation
fix(core): align policy redirection gates, path validation, and workflow parsing - #29506
Conversation
…low parsing - Enforce consistent allowRedirection handling for restricted rules in PolicyEngine. - Convert nonInteractive ASK_USER decisions to DENY across all safety evaluation paths. - Align MCP resources and web search output wrapping with untrusted context standards. - Add device and inode consistency checks to fileUtils buffer reading. - Refactor issue triage and deduplication workflows to ingest structured summary outputs.
|
📊 PR Size: size/L
|
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request significantly enhances the security and consistency of the core engine. Key changes include stricter policy enforcement for redirected commands, robust file integrity checks during read operations, and improved path validation to protect sensitive workspace configurations. Additionally, the PR standardizes the handling of untrusted tool outputs and optimizes CI workflow parsing for better reliability. Highlights
Ignored Files
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize the Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counterproductive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request introduces several security and policy enforcement enhancements, including wrapping untrusted tool outputs (MCP resources and web search results) in <untrusted_context> tags, protecting .gemini configuration files, allowing safe .env templates while blocking other variants, and escalating allowed actions to user confirmation when taint or build file risks are detected. Additionally, it hardens path resolution, PowerShell path validation, and file reading consistency checks via device and inode verification. The review feedback highlights two important improvements: resolving a strict TypeScript compilation error in the taint risk check by casting the object, and addressing a critical Time-of-Check to Time-of-Use (TOCTOU) race condition in the secure file reader by reading directly from the verified file handle.
Note: Security Review did not run due to the size of the PR.
|
Size Change: +3.45 kB (+0.01%) Total Size: 35.4 MB
ℹ️ View Unchanged
|
|
✅ 73 tests passed successfully on gemini-3-flash-preview. 🧠 Model Steering GuidanceThis PR modifies files that affect the model's behavior (prompts, tools, or instructions).
This is an automated guidance message triggered by steering logic signatures. |
…and updated the corresponding tests
Co-authored-by: Adam Weidman <[email protected]>
Co-authored-by: Adam Weidman <[email protected]>
|
/patch stable |
|
🚀 [Step 1/4] Patch workflow(s) waiting for approval! 📋 Details:
⏳ Status: The patch creation workflow has been triggered and is waiting for deployment approval. Please visit the specific workflow links below and approve the runs. 🔗 Track Progress: |
Summary
gemini-automated-issue-triage.yml,gemini-automated-issue-dedup.yml,gemini-scheduled-issue-triage.yml, andgemini-scheduled-issue-dedup.ymlto parse structured summary outputs directly rather than shelling out toecho/gh issue view.allowRedirectiononargsPatternrules andnonInteractiveASK_USERfallbacks behave consistently across approval modes.web-fetchcontext formatting..env.exampletemplates) and workspace configuration directories.fileUtils.Details