VYPR
Critical severity9.1NVD Advisory· Published Apr 17, 2017· Updated May 13, 2026

CVE-2017-5648

CVE-2017-5648

Description

While investigating bug 60718, it was noticed that some calls to application listeners in Apache Tomcat 9.0.0.M1 to 9.0.0.M17, 8.5.0 to 8.5.11, 8.0.0.RC1 to 8.0.41, and 7.0.0 to 7.0.75 did not use the appropriate facade object. When running an untrusted application under a SecurityManager, it was therefore possible for that untrusted application to retain a reference to the request or response object and thereby access and/or modify information associated with another web application.

Affected packages

Versions sourced from the GitHub Security Advisory.

PackageAffected versionsPatched versions
org.apache.tomcat:tomcat-catalinaMaven
>= 9.0.0.M1, < 9.0.0.M189.0.0.M18
org.apache.tomcat:tomcat-catalinaMaven
>= 8.5.0, < 8.5.138.5.13
org.apache.tomcat:tomcat-catalinaMaven
>= 8.0.0, < 8.0.428.0.42
org.apache.tomcat:tomcat-catalinaMaven
>= 7.0.0, < 7.0.767.0.76
org.apache.tomcat.embed:tomcat-embed-coreMaven
>= 9.0.0.M1, < 9.0.0.M189.0.0.M18
org.apache.tomcat.embed:tomcat-embed-coreMaven
>= 8.5.0, < 8.5.138.5.13
org.apache.tomcat.embed:tomcat-embed-coreMaven
>= 8.0.0, < 8.0.428.0.42
org.apache.tomcat.embed:tomcat-embed-coreMaven
>= 7.0.0, < 7.0.767.0.76

Affected products

149
  • Apache/Tomcat148 versions
    cpe:2.3:a:apache:tomcat:7.0.0:*:*:*:*:*:*:*+ 147 more
    • cpe:2.3:a:apache:tomcat:7.0.0:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.1:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.10:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.11:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.12:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.13:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.14:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.15:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.16:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.17:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.18:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.19:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.2:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.20:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.21:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.22:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.23:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.24:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.25:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.26:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.27:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.28:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.29:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.3:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.30:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.31:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.32:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.33:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.34:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.35:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.36:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.37:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.38:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.39:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.4:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.40:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.41:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.42:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.43:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.44:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.45:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.46:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.47:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.48:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.49:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.5:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.50:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.51:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.52:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.53:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.54:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.55:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.56:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.57:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.58:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.59:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.6:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.60:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.61:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.62:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.63:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.64:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.65:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.66:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.67:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.68:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.69:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.7:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.70:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.71:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.72:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.73:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.74:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.75:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.8:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:7.0.9:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.0:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.0:rc1:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.1:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.10:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.11:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.12:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.13:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.14:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.15:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.16:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.17:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.18:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.19:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.2:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.20:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.21:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.22:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.23:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.24:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.25:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.26:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.27:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.28:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.29:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.3:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.30:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.31:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.32:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.33:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.34:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.35:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.36:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.37:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.38:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.39:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.4:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.40:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.41:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.5:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.6:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.7:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.8:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.0.9:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.5.0:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.5.1:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.5.10:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.5.11:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.5.2:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.5.3:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.5.4:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.5.5:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.5.6:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.5.7:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.5.8:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:8.5.9:*:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone1:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone10:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone11:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone12:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone13:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone14:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone15:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone16:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone17:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone2:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone3:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone4:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone5:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone6:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone7:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone8:*:*:*:*:*:*
    • cpe:2.3:a:apache:tomcat:9.0.0:milestone9:*:*:*:*:*:*
  • Apache Software Foundation/Apache Tomcatv5
    Range: 9.0.0.M1 to 9.0.0.M17

Patches

4
6bb36dfdf644

Ensure request and response facades are used when firing application listeners.

https://github.com/apache/tomcatMark ThomasMar 6, 2017via ghsa
4 files changed · +19 16
  • java/org/apache/catalina/authenticator/FormAuthenticator.java+5 6 modified
    @@ -406,9 +406,9 @@ protected void forwardToLoginPage(Request request,
             RequestDispatcher disp =
                 context.getServletContext().getRequestDispatcher(loginPage);
             try {
    -            if (context.fireRequestInitEvent(request)) {
    +            if (context.fireRequestInitEvent(request.getRequest())) {
                     disp.forward(request.getRequest(), response);
    -                context.fireRequestDestroyEvent(request);
    +                context.fireRequestDestroyEvent(request.getRequest());
                 }
             } catch (Throwable t) {
                 ExceptionUtils.handleThrowable(t);
    @@ -450,12 +450,11 @@ protected void forwardToErrorPage(Request request,
             }
     
             RequestDispatcher disp =
    -            context.getServletContext().getRequestDispatcher
    -            (config.getErrorPage());
    +                context.getServletContext().getRequestDispatcher(config.getErrorPage());
             try {
    -            if (context.fireRequestInitEvent(request)) {
    +            if (context.fireRequestInitEvent(request.getRequest())) {
                     disp.forward(request.getRequest(), response);
    -                context.fireRequestDestroyEvent(request);
    +                context.fireRequestDestroyEvent(request.getRequest());
                 }
             } catch (Throwable t) {
                 ExceptionUtils.handleThrowable(t);
    
  • java/org/apache/catalina/core/AsyncContextImpl.java+1 1 modified
    @@ -135,7 +135,7 @@ public void fireOnComplete() {
                     }
                 }
             } finally {
    -            context.fireRequestDestroyEvent(request);
    +            context.fireRequestDestroyEvent(request.getRequest());
                 clearServletRequestResponse();
                 if (Globals.IS_SECURITY_ENABLED) {
                     PrivilegedAction<Void> pa = new PrivilegedSetTccl(oldCL);
    
  • java/org/apache/catalina/core/StandardHostValve.java+9 9 modified
    @@ -66,7 +66,7 @@ final class StandardHostValve extends ValveBase {
     
         static {
             STRICT_SERVLET_COMPLIANCE = Globals.STRICT_SERVLET_COMPLIANCE;
    -        
    +
             String accessSession = System.getProperty(
                     "org.apache.catalina.core.StandardHostValve.ACCESS_SESSION");
             if (accessSession == null) {
    @@ -146,7 +146,7 @@ public final void invoke(Request request, Response response)
                 if (Globals.IS_SECURITY_ENABLED) {
                     PrivilegedAction<Void> pa = new PrivilegedSetTccl(
                             context.getLoader().getClassLoader());
    -                AccessController.doPrivileged(pa);                
    +                AccessController.doPrivileged(pa);
                 } else {
                     Thread.currentThread().setContextClassLoader
                             (context.getLoader().getClassLoader());
    @@ -156,9 +156,9 @@ public final void invoke(Request request, Response response)
                 request.setAsyncSupported(context.getPipeline().isAsyncSupported());
             }
     
    -        boolean asyncAtStart = request.isAsync(); 
    +        boolean asyncAtStart = request.isAsync();
             boolean asyncDispatching = request.isAsyncDispatching();
    -        if (asyncAtStart || context.fireRequestInitEvent(request)) {
    +        if (asyncAtStart || context.fireRequestInitEvent(request.getRequest())) {
     
                 // Ask this Context to process this request. Requests that are in
                 // async mode and are not being dispatched to this resource must be
    @@ -197,7 +197,7 @@ public final void invoke(Request request, Response response)
                 if (!context.getState().isAvailable()) {
                     return;
                 }
    -    
    +
                 // Look for (and render if found) an application level error page
                 if (response.isErrorReportRequired()) {
                     if (t != null) {
    @@ -208,7 +208,7 @@ public final void invoke(Request request, Response response)
                 }
     
                 if (!request.isAsync() && !asyncAtStart) {
    -                context.fireRequestDestroyEvent(request);
    +                context.fireRequestDestroyEvent(request.getRequest());
                 }
             }
     
    @@ -222,7 +222,7 @@ public final void invoke(Request request, Response response)
             if (Globals.IS_SECURITY_ENABLED) {
                 PrivilegedAction<Void> pa = new PrivilegedSetTccl(
                         StandardHostValve.class.getClassLoader());
    -            AccessController.doPrivileged(pa);                
    +            AccessController.doPrivileged(pa);
             } else {
                 Thread.currentThread().setContextClassLoader
                         (StandardHostValve.class.getClassLoader());
    @@ -258,7 +258,7 @@ public final void event(Request request, Response response, CometEvent event)
             // Ask this Context to process this request
             context.getPipeline().getFirst().event(request, response, event);
     
    -        
    +
             // Error page processing
             response.setSuspended(false);
     
    @@ -469,7 +469,7 @@ private boolean custom(Request request, Response response,
     
                 if (response.isCommitted()) {
                     // Response is committed - including the error page is the
    -                // best we can do 
    +                // best we can do
                     rd.include(request.getRequest(), response.getResponse());
                 } else {
                     // Reset the response (keeping the real error code and message)
    
  • webapps/docs/changelog.xml+4 0 modified
    @@ -193,6 +193,10 @@
             session - if there is a session - when running under a
             <code>SecurityManager</code>. Patch provided by Jan Engehausen. (markt)
           </fix>
    +      <fix>
    +        Ensure request and response facades are used when firing application
    +        listeners. (markt/remm)
    +      </fix>
         </changelog>
       </subsection>
     </section>
    
6d73b079c55e

Ensure request and response facades are used when firing application listeners.

https://github.com/apache/tomcat80Mark ThomasMar 6, 2017via ghsa
4 files changed · +12 9
  • java/org/apache/catalina/authenticator/FormAuthenticator.java+5 6 modified
    @@ -394,9 +394,9 @@ protected void forwardToLoginPage(Request request,
             RequestDispatcher disp =
                 context.getServletContext().getRequestDispatcher(loginPage);
             try {
    -            if (context.fireRequestInitEvent(request)) {
    +            if (context.fireRequestInitEvent(request.getRequest())) {
                     disp.forward(request.getRequest(), response);
    -                context.fireRequestDestroyEvent(request);
    +                context.fireRequestDestroyEvent(request.getRequest());
                 }
             } catch (Throwable t) {
                 ExceptionUtils.handleThrowable(t);
    @@ -438,12 +438,11 @@ protected void forwardToErrorPage(Request request,
             }
     
             RequestDispatcher disp =
    -            context.getServletContext().getRequestDispatcher
    -            (config.getErrorPage());
    +                context.getServletContext().getRequestDispatcher(config.getErrorPage());
             try {
    -            if (context.fireRequestInitEvent(request)) {
    +            if (context.fireRequestInitEvent(request.getRequest())) {
                     disp.forward(request.getRequest(), response);
    -                context.fireRequestDestroyEvent(request);
    +                context.fireRequestDestroyEvent(request.getRequest());
                 }
             } catch (Throwable t) {
                 ExceptionUtils.handleThrowable(t);
    
  • java/org/apache/catalina/core/AsyncContextImpl.java+1 1 modified
    @@ -113,7 +113,7 @@ public void fireOnComplete() {
                     }
                 }
             } finally {
    -            context.fireRequestDestroyEvent(request);
    +            context.fireRequestDestroyEvent(request.getRequest());
                 clearServletRequestResponse();
                 context.unbind(Globals.IS_SECURITY_ENABLED, oldCL);
             }
    
  • java/org/apache/catalina/core/StandardHostValve.java+2 2 modified
    @@ -124,7 +124,7 @@ public final void invoke(Request request, Response response)
             try {
                 context.bind(Globals.IS_SECURITY_ENABLED, MY_CLASSLOADER);
     
    -            if (!asyncAtStart && !context.fireRequestInitEvent(request)) {
    +            if (!asyncAtStart && !context.fireRequestInitEvent(request.getRequest())) {
                     // Don't fire listeners during async processing (the listener
                     // fired for the request that called startAsync()).
                     // If a request init listener throws an exception, the request
    @@ -180,7 +180,7 @@ public final void invoke(Request request, Response response)
                 }
     
                 if (!request.isAsync() && !asyncAtStart) {
    -                context.fireRequestDestroyEvent(request);
    +                context.fireRequestDestroyEvent(request.getRequest());
                 }
             } finally {
                 // Access a session (if present) to update last accessed time, based
    
  • webapps/docs/changelog.xml+4 0 modified
    @@ -113,6 +113,10 @@
             session - if there is a session - when running under a
             <code>SecurityManager</code>. Patch provided by Jan Engehausen. (markt)
           </fix>
    +      <fix>
    +        Ensure request and response facades are used when firing application
    +        listeners. (markt/remm)
    +      </fix>
         </changelog>
       </subsection>
       <subsection name="Coyote">
    
0f7b9465d594

Ensure request and response facades are used when firing application listeners.

https://github.com/apache/tomcatMark ThomasMar 6, 2017via ghsa
4 files changed · +12 9
  • java/org/apache/catalina/authenticator/FormAuthenticator.java+5 6 modified
    @@ -427,9 +427,9 @@ protected void forwardToLoginPage(Request request,
             RequestDispatcher disp =
                 context.getServletContext().getRequestDispatcher(loginPage);
             try {
    -            if (context.fireRequestInitEvent(request)) {
    +            if (context.fireRequestInitEvent(request.getRequest())) {
                     disp.forward(request.getRequest(), response);
    -                context.fireRequestDestroyEvent(request);
    +                context.fireRequestDestroyEvent(request.getRequest());
                 }
             } catch (Throwable t) {
                 ExceptionUtils.handleThrowable(t);
    @@ -471,12 +471,11 @@ protected void forwardToErrorPage(Request request,
             }
     
             RequestDispatcher disp =
    -            context.getServletContext().getRequestDispatcher
    -            (config.getErrorPage());
    +                context.getServletContext().getRequestDispatcher(config.getErrorPage());
             try {
    -            if (context.fireRequestInitEvent(request)) {
    +            if (context.fireRequestInitEvent(request.getRequest())) {
                     disp.forward(request.getRequest(), response);
    -                context.fireRequestDestroyEvent(request);
    +                context.fireRequestDestroyEvent(request.getRequest());
                 }
             } catch (Throwable t) {
                 ExceptionUtils.handleThrowable(t);
    
  • java/org/apache/catalina/core/AsyncContextImpl.java+1 1 modified
    @@ -112,7 +112,7 @@ public void fireOnComplete() {
                     }
                 }
             } finally {
    -            context.fireRequestDestroyEvent(request);
    +            context.fireRequestDestroyEvent(request.getRequest());
                 clearServletRequestResponse();
                 context.unbind(Globals.IS_SECURITY_ENABLED, oldCL);
             }
    
  • java/org/apache/catalina/core/StandardHostValve.java+2 2 modified
    @@ -123,7 +123,7 @@ public final void invoke(Request request, Response response)
             try {
                 context.bind(Globals.IS_SECURITY_ENABLED, MY_CLASSLOADER);
     
    -            if (!asyncAtStart && !context.fireRequestInitEvent(request)) {
    +            if (!asyncAtStart && !context.fireRequestInitEvent(request.getRequest())) {
                     // Don't fire listeners during async processing (the listener
                     // fired for the request that called startAsync()).
                     // If a request init listener throws an exception, the request
    @@ -179,7 +179,7 @@ public final void invoke(Request request, Response response)
                 }
     
                 if (!request.isAsync() && !asyncAtStart) {
    -                context.fireRequestDestroyEvent(request);
    +                context.fireRequestDestroyEvent(request.getRequest());
                 }
             } finally {
                 // Access a session (if present) to update last accessed time, based
    
  • webapps/docs/changelog.xml+4 0 modified
    @@ -157,6 +157,10 @@
             session - if there is a session - when running under a
             <code>SecurityManager</code>. Patch provided by Jan Engehausen. (markt)
           </fix>
    +      <fix>
    +        Ensure request and response facades are used when firing application
    +        listeners. (markt/remm)
    +      </fix>
         </changelog>
       </subsection>
       <subsection name="Coyote">
    
dfa40863421d

Ensure request and response facades are used when firing application listeners.

https://github.com/apache/tomcatMark ThomasMar 6, 2017via ghsa
4 files changed · +12 9
  • java/org/apache/catalina/authenticator/FormAuthenticator.java+5 6 modified
    @@ -427,9 +427,9 @@ protected void forwardToLoginPage(Request request,
             RequestDispatcher disp =
                 context.getServletContext().getRequestDispatcher(loginPage);
             try {
    -            if (context.fireRequestInitEvent(request)) {
    +            if (context.fireRequestInitEvent(request.getRequest())) {
                     disp.forward(request.getRequest(), response);
    -                context.fireRequestDestroyEvent(request);
    +                context.fireRequestDestroyEvent(request.getRequest());
                 }
             } catch (Throwable t) {
                 ExceptionUtils.handleThrowable(t);
    @@ -471,12 +471,11 @@ protected void forwardToErrorPage(Request request,
             }
     
             RequestDispatcher disp =
    -            context.getServletContext().getRequestDispatcher
    -            (config.getErrorPage());
    +                context.getServletContext().getRequestDispatcher(config.getErrorPage());
             try {
    -            if (context.fireRequestInitEvent(request)) {
    +            if (context.fireRequestInitEvent(request.getRequest())) {
                     disp.forward(request.getRequest(), response);
    -                context.fireRequestDestroyEvent(request);
    +                context.fireRequestDestroyEvent(request.getRequest());
                 }
             } catch (Throwable t) {
                 ExceptionUtils.handleThrowable(t);
    
  • java/org/apache/catalina/core/AsyncContextImpl.java+1 1 modified
    @@ -112,7 +112,7 @@ public void fireOnComplete() {
                     }
                 }
             } finally {
    -            context.fireRequestDestroyEvent(request);
    +            context.fireRequestDestroyEvent(request.getRequest());
                 clearServletRequestResponse();
                 context.unbind(Globals.IS_SECURITY_ENABLED, oldCL);
             }
    
  • java/org/apache/catalina/core/StandardHostValve.java+2 2 modified
    @@ -123,7 +123,7 @@ public final void invoke(Request request, Response response)
             try {
                 context.bind(Globals.IS_SECURITY_ENABLED, MY_CLASSLOADER);
     
    -            if (!asyncAtStart && !context.fireRequestInitEvent(request)) {
    +            if (!asyncAtStart && !context.fireRequestInitEvent(request.getRequest())) {
                     // Don't fire listeners during async processing (the listener
                     // fired for the request that called startAsync()).
                     // If a request init listener throws an exception, the request
    @@ -179,7 +179,7 @@ public final void invoke(Request request, Response response)
                 }
     
                 if (!request.isAsync() && !asyncAtStart) {
    -                context.fireRequestDestroyEvent(request);
    +                context.fireRequestDestroyEvent(request.getRequest());
                 }
             } finally {
                 // Access a session (if present) to update last accessed time, based
    
  • webapps/docs/changelog.xml+4 0 modified
    @@ -167,6 +167,10 @@
             session - if there is a session - when running under a
             <code>SecurityManager</code>. Patch provided by Jan Engehausen. (markt)
           </fix>
    +      <fix>
    +        Ensure request and response facades are used when firing application
    +        listeners. (markt/remm)
    +      </fix>
         </changelog>
       </subsection>
       <subsection name="Coyote">
    

Vulnerability mechanics

Generated by null/stub on May 9, 2026. Inputs: CWE entries + fix-commit diffs from this CVE's patches. Citations validated against bundle.

References

41

News mentions

0

No linked articles in our index yet.