github-advanced-security[bot] commented on code in PR #39925:
URL: https://github.com/apache/superset/pull/39925#discussion_r3245681799


##########
superset/views/explore.py:
##########
@@ -33,11 +34,24 @@
     @permission_name("read")
     @event_logger.log_this
     def root(self) -> FlaskResponse:
+        # After `Superset.route_base = ""`, both `Superset.explore` and this
+        # view register at `/explore/`; this view wins. Preserve the legacy
+        # form_data → form_data_key cache-and-redirect contract here so
+        # callers passing `?form_data=...` still get the short cache-key URL.
+        if request.args.get("form_data"):
+            from superset.views.core import Superset  # avoid circular import
+
+            return redirect(Superset.get_redirect_url())

Review Comment:
   ## CodeQL / URL redirection from remote source
   
   Untrusted URL redirection depends on a [user-provided value](1).
   
   [Show more 
details](https://github.com/apache/superset/security/code-scanning/2285)



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to