1
0
mirror of synced 2026-08-05 17:57:15 +00:00

SEC-1636: Add optimizations for simple pattern cases in AntPathRequestMatcher. "/**" and "**" are treated as universal matches and a trailing "/**" is now optimized using a substring match.

This commit is contained in:
Luke Taylor
2010-12-10 17:47:04 +00:00
parent 523f6add60
commit 2be2660b13
3 changed files with 183 additions and 13 deletions
@@ -35,7 +35,7 @@ public enum MatcherType {
}
public BeanDefinition createMatcher(String path, String method) {
if ("/**".equals(path) && method == null) {
if (("/**".equals(path) || "**".equals(path)) && method == null) {
return new RootBeanDefinition(AnyRequestMatcher.class);
}