diff --git a/extensions/vertx-http/runtime/src/main/java/io/quarkus/vertx/http/runtime/ForwardedProxyHandler.java b/extensions/vertx-http/runtime/src/main/java/io/quarkus/vertx/http/runtime/ForwardedProxyHandler.java index 6ba0cb9d1cc07..cde4f0d034fd8 100644 --- a/extensions/vertx-http/runtime/src/main/java/io/quarkus/vertx/http/runtime/ForwardedProxyHandler.java +++ b/extensions/vertx-http/runtime/src/main/java/io/quarkus/vertx/http/runtime/ForwardedProxyHandler.java @@ -45,7 +45,11 @@ public ForwardedProxyHandler(TrustedProxyCheck.TrustedProxyCheckBuilder proxyChe @Override public void handle(HttpServerRequest event) { - if (event.remoteAddress().isDomainSocket()) { + if (event.remoteAddress() == null) { + // client address may not be available with virtual http channel + LOGGER.debug("Client address is not available, 'Forwarded' and 'X-Forwarded' headers are going to be ignored"); + handleForwardedServerRequest(event, denyAll()); + } else if (event.remoteAddress().isDomainSocket()) { // we do not support domain socket proxy checks, ignore the headers LOGGER.debug("Domain socket are not supported, 'Forwarded' and 'X-Forwarded' headers are going to be ignored"); handleForwardedServerRequest(event, denyAll());