This is an automated email from the ASF dual-hosted git repository. schultz pushed a commit to branch 10.1.x in repository https://gitbox.apache.org/repos/asf/tomcat.git
commit 68626e431940e37eb28dea1b339aeb9fddaca517 Author: Christopher Schultz <ch...@christopherschultz.net> AuthorDate: Wed Oct 18 21:31:05 2023 -0400 Fail faster if a file does not exist. --- .../apache/tomcat/util/digester/ServiceBindingPropertySource.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/java/org/apache/tomcat/util/digester/ServiceBindingPropertySource.java b/java/org/apache/tomcat/util/digester/ServiceBindingPropertySource.java index c6b7b6ae12..fd882fcf63 100644 --- a/java/org/apache/tomcat/util/digester/ServiceBindingPropertySource.java +++ b/java/org/apache/tomcat/util/digester/ServiceBindingPropertySource.java @@ -105,6 +105,11 @@ public class ServiceBindingPropertySource implements IntrospectionUtils.SecurePr } Path path = Paths.get(serviceBindingRoot, parts[0], parts[1]); + + if (!path.toFile().exists()) { + return null; + } + try { if (classLoader instanceof PermissionCheck) { Permission p = new FilePermission(path.toString(), "read"); --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org