🛡️ Sentinel: [HIGH] Harden publish flow against data leakage and injection#118
🛡️ Sentinel: [HIGH] Harden publish flow against data leakage and injection#118calionauta wants to merge 1 commit into
Conversation
…ction This commit addresses several security vulnerabilities in the `publish` module: 1. **Regex Newline Injection**: Replaced `$` with `\Z` in `_is_valid_skill_name` regex to prevent bypasses using trailing newlines. 2. **Symlink Content Leakage**: Configured `shutil.copytree` and `shutil.copy2` to preserve symlinks instead of following them, preventing accidental disclosure of linked sensitive files. 3. **Robust File Exclusions**: Refactored `_ignore_func` to use `fnmatch.filter`, ensuring all `DEFAULT_IGNORE_PATTERNS` (like `sessions/` and `cache/`) are correctly applied. Verified with specialized security tests and full repository test suite. Co-authored-by: calionauta <1719651+calionauta@users.noreply.github.com>
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
There was a problem hiding this comment.
Code Review
This pull request addresses several security and robustness issues in the publishing flow. It updates regex patterns in _is_valid_skill_name to use \Z instead of $ to prevent newline injection, refactors file exclusion logic in _ignore_func to use fnmatch.filter for robust pattern matching, and configures shutil.copytree and shutil.copy2 to preserve symlinks and prevent content leakage of linked files. Additionally, the .jules/sentinel.md file is updated to document these vulnerabilities and prevention strategies. There are no review comments, so no feedback is provided.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
🛡️ Sentinel: [HIGH] Harden publish flow against data leakage and injection
Identified and fixed three security vulnerabilities in the publishing workflow:
local_source.pyandexternal_source.pywas vulnerable to trailing newlines bypass.git_publish.pyfailed to match many patterns in the default exclusion list.All issues have been remediated, verified with targeted scripts, and confirmed not to cause regressions via the full test suite.
PR created automatically by Jules for task 9379680464252856925 started by @calionauta