* @param authType the type of authenticator (BASIC, CLIENT-CERT, DIGEST or FORM) used to authenticate the SSO.
* @param username the username (if any) used for the authentication
* @param password the password (if any) used for the authentication
*/
private void storeCredentials(final String ssoId, String authType, String username, String password) {
final SSOCredentials credentials = new SSOCredentials(authType, username, password);
CredentialOperation<Void> operation = new CredentialOperation<Void>() {
@Override
public Void invoke(Cache<CredentialKey, SSOCredentials> cache) {
cache.getAdvancedCache().withFlags(Flag.SKIP_REMOTE_LOOKUP).put(new CredentialKey(ssoId), credentials);