protected AuthenticationInfo doGetAuthenticationInfo(AuthenticationToken token) throws AuthenticationException {
SimpleAccount account = (SimpleAccount) super.doGetAuthenticationInfo(token);
if (account != null) {
SimplePrincipalCollection principals = new SimplePrincipalCollection();
principals.add(new UserIdPrincipal(USER_ID), getName());
principals.add(new UsernamePrincipal(USERNAME), getName());
account.setPrincipals(principals);
}
return account;