net.unicon.cas.mfa.authentication.MultiFactorAuthenticationRequestResolver Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of cas-mfa-java Show documentation
Show all versions of cas-mfa-java Show documentation
This module is intended to include all the Java you need to add to a CAS implementation
to take advantage of the extended multifactor authentication features in this project.
package net.unicon.cas.mfa.authentication;
import org.jasig.cas.authentication.Authentication;
import org.jasig.cas.authentication.principal.Response.ResponseType;
import org.jasig.cas.authentication.principal.WebApplicationService;
import java.util.List;
/**
* A strategy interface for resolving requests for multifactor authentication from existing primary authentication data.
*
* Example implementations might use primary authenticated principal's attribute or some other piece of contextual data
* available in passed in Authentication
object instance. Implementations may choose to return multiple contexts.
*
* @author Dmitriy Kopylenko
* @author Unicon inc.
*/
public interface MultiFactorAuthenticationRequestResolver {
/**
* Resolve potential {@link net.unicon.cas.mfa.authentication.MultiFactorAuthenticationRequestContext} from passed in primary
* authentication instance, for a passed in target service.
*
* @param authentication primary authentication instance
* @param targetService target service
* @param responseType response type required by the service
*
* @return list instance of MultiFactorAuthenticationRequestContext
or null if no mfa request can be resolved
*/
List resolve(Authentication authentication, WebApplicationService targetService,
ResponseType responseType);
}