Repository navigation
π‘οΈ Sentinel: [security improvement] Harden Discord webhook dispatch - #388
Conversation
Normalize hostname trailing root dots in isValidDiscordWebhookUrl and enforce AbortSignal.timeout(5000) on outbound Discord webhook fetch to prevent socket hanging and resource exhaustion. Co-authored-by: nathfavour <[email protected]>
|
π 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. |
fetch, allowing slow or malicious remote endpoints to tie up socket connections and worker threads indefinitely (resource exhaustion / slowloris DoS). In addition,isValidDiscordWebhookUrldid not strip trailing root dots from hostnames before domain matching.signal: AbortSignal.timeout(5000)to the outbound notificationfetchinapp/api/discord/route.tsand normalizedurl.hostnamewith.replace(/\.+$/, '')before domain checking.app/api/discord/route.test.tsfor trailing dot hostname verification and verifying that an AbortSignal timeout is attached during outbound webhook dispatch. Ran full test suite (all tests pass) and linting.PR created automatically by Jules for task 4982111819576418740 started by @nathfavour