-
Couldn't load subscription status.
- Fork 3.7k
Basic local AI Token management tools #2062
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
base: master
Are you sure you want to change the base?
Conversation
With code taken directly from CodeQL's manual. https://codeql.github.com/codeql-query-help/javascript/js-incomplete-multi-character-sanitization/
| return htmlString | ||
| .replace(/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/ig, "") | ||
| .replace(/(<[^>]*?>)|(\s+)/g, function(match, tag, spaces) { | ||
| if (tag) { | ||
| return tag; | ||
| } else if (spaces) { | ||
| return ""; | ||
| } | ||
| }) |
Check failure
Code scanning / CodeQL
Incomplete multi-character sanitization High
<script
| return htmlString | ||
| .replace(/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/ig, "") |
Check failure
Code scanning / CodeQL
Incomplete multi-character sanitization High
<script
| */ | ||
| replaceSpacesOutsideTags(htmlString) { | ||
| return htmlString | ||
| .replace(/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/ig, "") |
Check failure
Code scanning / CodeQL
Bad HTML filtering regexp High
Adding the following: