Skip to content

🛡️ Sentinel: [HIGH] Fix Server-Side Request Forgery (SSRF) in background workers - #91

Open
frkr wants to merge 2 commits into
mainfrom
sentinel/fix-ssrf-background-workers-17945132342917951522
Open

🛡️ Sentinel: [HIGH] Fix Server-Side Request Forgery (SSRF) in background workers#91
frkr wants to merge 2 commits into
mainfrom
sentinel/fix-ssrf-background-workers-17945132342917951522

Conversation

@frkr

@frkr frkr commented Aug 27, 2026

Copy link
Copy Markdown
Owner

🚨 Severity: HIGH
💡 Vulnerability: Background workers (MQDestiny.ts and MQCallback.ts) were susceptible to Server-Side Request Forgery (SSRF). They fetched user-provided dynamic URLs (destiny and callback) retrieved from JSON configs in R2, but did not validate the protocol. This allowed attackers to potentially use schemes like file:// or gopher:// to access unauthorized local files or interact with internal systems.
🎯 Impact: Potential unauthorized access to internal resources, sensitive data exposure, or server compromise.
🔧 Fix: Added explicit protocol validation (http: and https:) in MQDestiny.ts and MQCallback.ts using new URL() to prevent Server-Side Request Forgery (SSRF) attacks when executing fetch against dynamically provided URLs. Messages with invalid protocols are gracefully marked as error to avoid infinite retry loops. Also recorded the security finding in the .jules/sentinel.md journal.
Verification: Unit tests passed verifying no regressions in the task runner. Try providing a file:// or ftp:// scheme in a dynamic destiny or callback configuration; the worker should properly reject the URL and save an error state.


PR created automatically by Jules for task 17945132342917951522 started by @frkr

…und workers

Added explicit protocol validation (`http:` and `https:`) in `MQDestiny.ts` and `MQCallback.ts` to prevent Server-Side Request Forgery (SSRF) attacks when executing `fetch` against dynamically provided URLs.
Updated Sentinel journal with security findings.

Co-authored-by: frkr <185359+frkr@users.noreply.github.com>
@google-labs-jules

Copy link
Copy Markdown
Contributor

👋 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 @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

…und workers

Added explicit protocol validation (`http:` and `https:`) in `MQDestiny.ts` and `MQCallback.ts` to prevent Server-Side Request Forgery (SSRF) attacks when executing `fetch` against dynamically provided URLs.
Updated Sentinel journal with security findings.

Co-authored-by: frkr <185359+frkr@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant