-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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 XSS in some dashboards queries #2785
Conversation
@@ -111,6 +122,6 @@ | |||
except InputParameterError as e: | |||
msgStr = str(e) | |||
log.warning('%s', msgStr) | |||
return HttpResponseBadRequest(escape(msgStr)) | |||
return HttpResponseBadRequest(htmlEscape(msgStr)) |
Check warning
Code scanning / CodeQL
Information exposure through an exception
10e0e4f
to
b8c492f
Compare
|
||
|
||
def is_unclean_str(s): | ||
for symbol in '&<>~!@#$%^*()`': |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minimal set of unsafe symbols is &<>
. May be other symbols are accepted ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's stick to wide set for now, we'll fix later, if needed
It would be nice to have a release incorporating this as it has now been indicated in 3 different CVEs: CVE-2022-4730, CVE-2022-4729 & CVE-2022-4728. |
Agreed, will do release soon |
* prevent xss on time range text fields * prevent xss on dashbord queries (cherry picked from commit 2f178f4) # Conflicts: # webapp/graphite/errors.py # webapp/tests/base.py
💚 All backports created successfully
Questions ?Please refer to the Backport tool documentation |
[1.1.x] Fix XSS in some dashboards queries (#2785)
Fixes XSS in some dashboards queries:
issue #2744
issue #2745
Also fix:
issue #2746