@Override
    public Collection<String> getImpersonationAccounts(final String username, final Optional<? extends Service> service) {
        if (this.eligibleAccounts.containsKey(username)) {
            return this.eligibleAccounts.get(username);
        }
        return new ArrayList<>();
    }
This is {@link SimpleSurrogateAuthenticationService}.

@author Misagh Moayyed
@since 5.1.0
support/cas-server-support-surrogate-core/src/main/java/org/apereo/cas/authentication/surrogate/SimpleSurrogateAuthenticationService.java