From c502e94ade9e050849a2d7fd2431c28ea77f4f0a Mon Sep 17 00:00:00 2001 From: Domenico Francesco Bruscino Date: Mon, 13 Dec 2021 12:11:14 +0100 Subject: [PATCH] ARTEMIS-3605 Upgrade jetty version to 9.4.44.v20210927 --- .../activemq/artemis/component/WebServerComponent.java | 5 +++++ pom.xml | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/artemis-web/src/main/java/org/apache/activemq/artemis/component/WebServerComponent.java b/artemis-web/src/main/java/org/apache/activemq/artemis/component/WebServerComponent.java index c03a3fe354..98b580a07f 100644 --- a/artemis-web/src/main/java/org/apache/activemq/artemis/component/WebServerComponent.java +++ b/artemis-web/src/main/java/org/apache/activemq/artemis/component/WebServerComponent.java @@ -32,6 +32,7 @@ import org.apache.activemq.artemis.components.ExternalComponent; import org.apache.activemq.artemis.dto.AppDTO; import org.apache.activemq.artemis.dto.ComponentDTO; import org.apache.activemq.artemis.dto.WebServerDTO; +import org.eclipse.jetty.security.DefaultAuthenticatorFactory; import org.eclipse.jetty.server.ConnectionFactory; import org.eclipse.jetty.server.Connector; import org.eclipse.jetty.server.HttpConfiguration; @@ -342,6 +343,10 @@ public class WebServerComponent implements ExternalComponent { webapp.setAttribute("org.eclipse.jetty.webapp.basetempdir", temporaryWarDir.toFile().getAbsolutePath()); + // Set the default authenticator factory to avoid NPE due to the following commit: + // https://github.com/eclipse/jetty.project/commit/7e91d34177a880ecbe70009e8f200d02e3a0c5dd + webapp.getSecurityHandler().setAuthenticatorFactory(new DefaultAuthenticatorFactory()); + handlers.addHandler(webapp); return webapp; } diff --git a/pom.xml b/pom.xml index 3095f69d93..517a0a27ad 100644 --- a/pom.xml +++ b/pom.xml @@ -100,7 +100,7 @@ 1.16 30.1-jre 3.4.2.Final - 9.4.43.v20210629 + 9.4.44.v20210927 3.6.13.Final 2.9.0 3.0.0-M3