It would be helpful to have an AuthorizationManager that takes the needed authorities as context.

Something like (pseudocode):

AuthorizationManager<Collection<String>> manager = (authentication, authorities) -> 
        (authentication hasAnyAuthority authorities) ? granted : denied;

Comment From: evgeniycheban

Hi, @jzheaux I created a PR that adds this new AuthorizationManager and refactors the existing AuthorityAuthorizationManager to use it internally.