-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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: Make sure user input is not treated as safe in the oauth view #1978
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1978 +/- ##
=======================================
Coverage 78.13% 78.13%
=======================================
Files 71 71
Lines 8612 8612
=======================================
Hits 6729 6729
Misses 1883 1883
Flags with carried forward coverage won't be shown. Click here to find out more. Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
@dpgaspar Can you review this change? It solves a upstream Issue in apache airflow which allows XSS via the next paramter |
Since next parameter shouldn't be used with `safe` Jinja filter (see dpgaspar#1978), to avoid double escaping we can use Jinja's `urlencode`. Also, it might be clearer to work with this parameter in the related libraries, no need to double unquote the url.
Since next parameter shouldn't be used with `safe` Jinja filter (see dpgaspar#1978), to avoid double escaping we can use Jinja's `urlencode`. Also, it might be clearer to work with this parameter in the related libraries, no need to double unquote the url.
Since next parameter shouldn't be used with `safe` Jinja filter (see #1978), to avoid double escaping we can use Jinja's `urlencode`. Also, it might be clearer to work with this parameter in the related libraries, no need to double unquote the url. Co-authored-by: Daniel Vaz Gaspar <[email protected]>
Was an advisory ever published for this issue? I don't think I see it at https://github.com/dpgaspar/Flask-AppBuilder/security |
Description
Fix a security issue issue with the next parameter in the OAUTH Login field.
The user can edit the next field from within the URL, this can cause reflected XSS.
for example /login/?next="-alert(document.location)-" will alert the document location.
ADDITIONAL INFORMATION