io.dropwizard.auth.PermitAllAuthorizer Maven / Gradle / Ivy
package io.dropwizard.auth;
import org.checkerframework.checker.nullness.qual.Nullable;
import javax.ws.rs.container.ContainerRequestContext;
import java.security.Principal;
/**
* An {@link Authorizer} that grants access for any principal in any role.
*
* @param the type of the principal
*/
public class PermitAllAuthorizer
implements Authorizer
{
@Override
public boolean authorize(P principal, String role, @Nullable ContainerRequestContext ctx) {
return true;
}
}