Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Stored XSS #4

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Fix Stored XSS #4

wants to merge 1 commit into from

Conversation

gtsp233
Copy link

@gtsp233 gtsp233 commented Oct 29, 2023

Hi, I've discovered a stored Cross-Site Scripting (XSS) vulnerability in your GitHub repository:

Vulnerability Details:
Version Affected: All versions
Severity: [High/Critical – Stored XSS can have a significant impact. Adjust based on your assessment]
Description: The vulnerability allows malicious attacks to inject scripts through a direct network request. Once embedded, any user viewing the story list or the specific story's details will execute the malicious script.
Steps to Reproduce:
Send a direct network request (bypassing the user interface) to /api/user/create with a payload content containing the malicious script: .
After the blog is successfully created, any user who views the blog list or the specific blog’s details will run the malicious script.
Suggested Fix or Mitigation:
Server-side: Within the /create controller, it's essential to sanitize the user's input (content) before processing it to ensure malicious scripts are neutralized.
Client-side: Prior to displaying the story's content using dangerouslySetInnerHtml, ensure that the content is sanitized using tools like DOMPurify to avert script execution.

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.

None yet

1 participant