Skip to content

πŸ”’ Fix XSS vulnerability in nv-modal - #33

Open
manupawickramasinghe wants to merge 3 commits into
mainfrom
fix-nv-modal-xss-10182982558503608552
Open

πŸ”’ Fix XSS vulnerability in nv-modal#33
manupawickramasinghe wants to merge 3 commits into
mainfrom
fix-nv-modal-xss-10182982558503608552

Conversation

@manupawickramasinghe

Copy link
Copy Markdown
Member

🎯 What: Fixed a Cross-Site Scripting (XSS) vulnerability in nv-modal.ts caused by injecting unescaped user input directly into the .innerHTML property of the modal body.
⚠️ Risk: If left unfixed, any external system, component, or user capable of triggering the nv-modal event could pass a malicious payload in the body field. This payload would then be executed within the context of the user's browser, potentially leading to session hijacking, unauthorized actions, or complete compromise of the application context.
πŸ›‘οΈ Solution: Imported the standard DOMPurify library and used DOMPurify.sanitize(this.mBody) to thoroughly clean and neutralize any potentially malicious input before assigning it to the DOM. Also added @types/dompurify for typescript type checking.


PR created automatically by Jules for task 10182982558503608552 started by @manupawickramasinghe

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

Copy link
Copy Markdown

πŸ‘‹ 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.

Copilot AI lite review requested due to automatic review settings August 14, 2026 19:34

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

google-labs-jules Bot and others added 2 commits August 14, 2026 20:42
Co-authored-by: manupawickramasinghe <73810867+manupawickramasinghe@users.noreply.github.com>
Co-authored-by: manupawickramasinghe <73810867+manupawickramasinghe@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.

2 participants