/** * Check if a user is in a role. * * @param role name of role to check */ public boolean isUserInRole(String role) { return realm.isUserInRole(getUserPrincipal(), role); }
if ("*".equals(role) || realm.isUserInRole(principal, role)) { authorized = true;