mirror of https://github.com/apache/archiva.git
[MRM-1147] handling leading / on whitelists is ambiguous
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@756012 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
9b150136fe
commit
3b9173e74f
|
@ -958,8 +958,18 @@ public class DefaultRepositoryProxyConnectors
|
|||
return false;
|
||||
}
|
||||
|
||||
if ( !path.startsWith( "/" ) )
|
||||
{
|
||||
path = "/" + path;
|
||||
}
|
||||
|
||||
for ( String pattern : patterns )
|
||||
{
|
||||
if ( !pattern.startsWith( "/" ) )
|
||||
{
|
||||
pattern = "/" + pattern;
|
||||
}
|
||||
|
||||
if ( SelectorUtils.matchPath( pattern, path, false ) )
|
||||
{
|
||||
return true;
|
||||
|
|
Loading…
Reference in New Issue