Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
1.6.0
-
None
Description
It looks like message-page.jsp uses X-ProxyContextPath verbatim without sanitizing it or anything. See
I verified this by hitting /nifi-api/access/oidc/callback on an unsecured NiFi host to get the User authentication/authorization is only supported when running over HTTPS message page.
$ curl http://hostname/nifi-api/access/oidc/callback ... <link rel="stylesheet" href="/nifi/assets/reset.css/reset.css" type="text/css" /> ... $ curl --header "X-ProxyContextPath: /nifi/assets/reset.css/reset.css\" type=\"text/css\" /><script type=\"text/javascript\">alert(\"omg\");</script><link rel=\"stylesheet\" href=\"" http://hostname/nifi-api/access/oidc/callback ... <link rel="stylesheet" href="/nifi/assets/reset.css/reset.css" type="text/css" /><script type="text/javascript">alert("omg");</script><link rel="stylesheet" href="/nifi/assets/reset.css/reset.css" type="text/css" /> ...
Presumably we want to do something like this: https://github.com/apache/nifi/commit/5d643edfaba4f5369c94ee1b4eaa5c59e3a9f37a#diff-91119fe15bb6f3b931662093e367b671R20
Attachments
Issue Links
- relates to
-
NIFI-7558 Context path filtering does not work when behind a reverse proxy with a context path
- Resolved
- links to