Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

appatalks
Copy link
Owner

No description provided.


var bubble = document.createElement("div");
bubble.className = "bubble user-bubble";
bubble.innerHTML = message;

Check warning

Code scanning / CodeQL

DOM text reinterpreted as HTML

[DOM text](1) is reinterpreted as HTML without escaping meta-characters.

var sQuestion = document.getElementById("txtMsg").innerHTML;
sQuestion = sQuestion.replace(/<br>/g, "\n");
const cleanedQuestion = sQuestion.replace(/<[^>]+>/g, "");

Check failure

Code scanning / CodeQL

Incomplete multi-character sanitization

This string may still contain [<script](1), which may cause an HTML element injection vulnerability.
@appatalks
Copy link
Owner Author

take note of codeql results

@appatalks appatalks merged commit da629a0 into main Mar 9, 2024
@appatalks appatalks deleted the appatalks_eva_playground branch March 10, 2024 05:56
appatalks added a commit that referenced this pull request Mar 10, 2024
appatalks added a commit that referenced this pull request Aug 10, 2025
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