use of org.springframework.webflow.engine.model.TransitionModel in project cas by apereo.
the class DuoMultifactorWebflowConfigurer method createDuoAuthenticationWebflowAction.
private void createDuoAuthenticationWebflowAction(final List<AbstractStateModel> states) {
final ActionStateModel actModel = new ActionStateModel(CasWebflowConstants.STATE_ID_REAL_SUBMIT);
final LinkedList<AbstractActionModel> actions = new LinkedList<>();
actions.add(new EvaluateModel("duoAuthenticationWebflowAction"));
actModel.setActions(actions);
final LinkedList<TransitionModel> trans = new LinkedList<>();
TransitionModel transModel = new TransitionModel();
transModel.setOn(CasWebflowConstants.TRANSITION_ID_SUCCESS);
transModel.setTo(CasWebflowConstants.TRANSITION_ID_SUCCESS);
trans.add(transModel);
transModel = new TransitionModel();
transModel.setOn(CasWebflowConstants.TRANSITION_ID_ERROR);
transModel.setTo(CasWebflowConstants.STATE_ID_INIT_LOGIN_FORM);
trans.add(transModel);
actModel.setTransitions(trans);
states.add(actModel);
}
use of org.springframework.webflow.engine.model.TransitionModel in project cas by apereo.
the class DuoMultifactorWebflowConfigurer method createDuoDoNonWebAuthenticationAction.
private void createDuoDoNonWebAuthenticationAction(final List<AbstractStateModel> states) {
final ActionStateModel actModel = new ActionStateModel("doNonWebAuthentication");
final LinkedList<AbstractActionModel> actions = new LinkedList<>();
actions.add(new EvaluateModel("duoNonWebAuthenticationAction"));
actModel.setActions(actions);
final LinkedList<TransitionModel> trans = new LinkedList<>();
final TransitionModel transModel = new TransitionModel();
transModel.setOn(CasWebflowConstants.TRANSITION_ID_SUCCESS);
transModel.setTo("finalizeAuthentication");
trans.add(transModel);
actModel.setTransitions(trans);
states.add(actModel);
}
use of org.springframework.webflow.engine.model.TransitionModel in project cas by apereo.
the class DuoMultifactorWebflowConfigurer method createDuoInitializeLoginAction.
private LinkedList<AbstractActionModel> createDuoInitializeLoginAction(final List<AbstractStateModel> states) {
final ActionStateModel actModel = new ActionStateModel(CasWebflowConstants.STATE_ID_INIT_LOGIN_FORM);
final LinkedList<AbstractActionModel> actions = new LinkedList<>();
actions.add(new EvaluateModel("initializeLoginAction"));
actModel.setActions(actions);
final LinkedList<TransitionModel> trans = new LinkedList<>();
final TransitionModel transModel = new TransitionModel();
transModel.setOn(CasWebflowConstants.TRANSITION_ID_SUCCESS);
transModel.setTo("determineDuoUserAccount");
trans.add(transModel);
actModel.setTransitions(trans);
states.add(actModel);
return actions;
}
use of org.springframework.webflow.engine.model.TransitionModel in project cas by apereo.
the class DuoMultifactorWebflowConfigurer method createDuoDetermineRequestAction.
private void createDuoDetermineRequestAction(final List<AbstractStateModel> states) {
final ActionStateModel actModel = new ActionStateModel("determineDuoRequest");
final LinkedList<AbstractActionModel> actions = new LinkedList<>();
actions.add(new EvaluateModel("checkWebAuthenticationRequestAction"));
actModel.setActions(actions);
final LinkedList<TransitionModel> trans = new LinkedList<>();
TransitionModel transModel = new TransitionModel();
transModel.setOn(CasWebflowConstants.TRANSITION_ID_YES);
transModel.setTo(STATE_ID_VIEW_LOGIN_FORM_DUO);
trans.add(transModel);
transModel = new TransitionModel();
transModel.setOn(CasWebflowConstants.TRANSITION_ID_NO);
transModel.setTo("doNonWebAuthentication");
trans.add(transModel);
actModel.setTransitions(trans);
states.add(actModel);
}
use of org.springframework.webflow.engine.model.TransitionModel in project cas by apereo.
the class DuoSecurityMultifactorWebflowConfigurer method createDuoDetermineRequestAction.
private static void createDuoDetermineRequestAction(final List<AbstractStateModel> states) {
val actModel = new ActionStateModel(CasWebflowConstants.STATE_ID_DETERMINE_DUO_REQUEST);
val actions = new LinkedList<AbstractActionModel>();
actions.add(new EvaluateModel(CasWebflowConstants.ACTION_ID_CHECK_WEB_AUTHENTICATION_REQUEST));
actModel.setActions(actions);
val trans = new LinkedList<TransitionModel>();
var transModel = new TransitionModel();
transModel.setOn(CasWebflowConstants.TRANSITION_ID_YES);
transModel.setTo(CasWebflowConstants.STATE_ID_VIEW_LOGIN_FORM_DUO);
trans.add(transModel);
transModel = new TransitionModel();
transModel.setOn(CasWebflowConstants.TRANSITION_ID_NO);
transModel.setTo(CasWebflowConstants.STATE_ID_DUO_NON_WEB_AUTHENTICATION);
trans.add(transModel);
actModel.setTransitions(trans);
states.add(actModel);
}
Aggregations