public boolean matches(String pattern, String source) { return match(pattern, source); }
public boolean matches(String pattern, String source) { return match(pattern, source); }
public boolean matches(String pattern, String source) { return match(pattern, source); }
static List<AuthzHandler> getJdbcAuthzHandler(HttpServletRequest request) { /* if(authzMaps.containsKey(controllerClassName)){ return true; }*/ List<AuthzHandler> result = new ArrayList<AuthzHandler>(); String url = WebUtils.getPathWithinApplication(request); for (String key : authzJdbcMaps.keySet()) { if (antPathMatcher.match(key, url)) { result.add(authzJdbcMaps.get(key)); if (!and) break; } } return result; }
static List<AuthzHandler> getJdbcAuthzHandler(HttpServletRequest request) { /* if(authzMaps.containsKey(controllerClassName)){ return true; }*/ List<AuthzHandler> result = new ArrayList<AuthzHandler>(); String url = WebUtils.getPathWithinApplication(request); for (String key : authzJdbcMaps.keySet()) { if (antPathMatcher.match(key, url)) { result.add(authzJdbcMaps.get(key)); if (!and) break; } } return result; }
@Override protected void handlePlexusResourceSecurity(PlexusResource resource) { PathProtectionDescriptor descriptor = resource.getResourceProtection(); if (descriptor == null) { return; } // sanity check: path protection descriptor path and resource URI must align if (!shiroAntPathMatcher.match(descriptor.getPathPattern(), resource.getResourceUri())) { throw new IllegalStateException(String.format( "Plexus resource %s would attach to URI=%s but protect path=%s that does not matches URI!", resource.getClass().getName(), resource.getResourceUri(), descriptor.getPathPattern())); } String filterExpression = descriptor.getFilterExpression(); if (filterExpression != null && !filterExpression.contains("authcNxBasic")) { // don't create session unless the user logs in from the UI filterExpression = "noSessionCreation," + filterExpression; } // HACK: Disable CSRFGuard support for now, its too problematic //if (filterExpression != null // && (filterExpression.contains("authcBasic") || filterExpression.contains("authcNxBasic"))) { // filterExpression += ",csrfToken"; //} this.protectedPathManager.addProtectedResource("/service/local" + descriptor.getPathPattern(), filterExpression); }