Search in sources :

Example 1 with ChainContextImpl

use of org.simbasecurity.core.chain.ChainContextImpl in project simba-os by cegeka.

the class ResetPasswordController method handleRequest.

@Override
public ModelAndView handleRequest(HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse) throws Exception {
    RequestData requestData = RequestUtil.createRequestData(httpServletRequest, simbaWebUrlResolver.resolveSimbaWebURL(httpServletRequest));
    ChainContextImpl context = new ChainContextImpl(requestData, sessionService.getSession(requestData.getSsoToken()), configurationService, loginMappingService);
    resetPasswordChain.execute(context);
    ActionDescriptor actionDescriptor = context.getActionDescriptor();
    RequestActionFactory actionFactory = new RequestActionFactory(httpServletRequest, httpServletResponse);
    actionFactory.execute(actionDescriptor);
    return null;
}
Also used : ChainContextImpl(org.simbasecurity.core.chain.ChainContextImpl) RequestData(org.simbasecurity.api.service.thrift.RequestData) ActionDescriptor(org.simbasecurity.api.service.thrift.ActionDescriptor) RequestActionFactory(org.simbasecurity.common.filter.action.RequestActionFactory)

Example 2 with ChainContextImpl

use of org.simbasecurity.core.chain.ChainContextImpl in project simba-os by cegeka.

the class ChangePasswordController method handleRequest.

public ModelAndView handleRequest(HttpServletRequest request, HttpServletResponse response) throws Exception {
    RequestData requestData = RequestUtil.createRequestData(request, simbaWebUrlResolver.resolveSimbaWebURL(request));
    ChainContextImpl context = new ChainContextImpl(requestData, sessionService.getSession(requestData.getSsoToken()), configurationService, loginMappingService);
    credentialChain.execute(context);
    ActionDescriptor actionDescriptor = context.getActionDescriptor();
    RequestActionFactory actionFactory = new RequestActionFactory(request, response);
    actionFactory.execute(actionDescriptor);
    return null;
}
Also used : ChainContextImpl(org.simbasecurity.core.chain.ChainContextImpl) RequestData(org.simbasecurity.api.service.thrift.RequestData) ActionDescriptor(org.simbasecurity.api.service.thrift.ActionDescriptor) RequestActionFactory(org.simbasecurity.common.filter.action.RequestActionFactory)

Example 3 with ChainContextImpl

use of org.simbasecurity.core.chain.ChainContextImpl in project simba-os by cegeka.

the class NewPasswordController method handleRequest.

@Override
public ModelAndView handleRequest(HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse) throws Exception {
    RequestData requestData = RequestUtil.createRequestData(httpServletRequest, simbaWebUrlResolver.resolveSimbaWebURL(httpServletRequest));
    ChainContextImpl context = new ChainContextImpl(requestData, sessionService.getSession(requestData.getSsoToken()), configurationService, loginMappingService);
    newPasswordChain.execute(context);
    ActionDescriptor actionDescriptor = context.getActionDescriptor();
    RequestActionFactory actionFactory = new RequestActionFactory(httpServletRequest, httpServletResponse);
    actionFactory.execute(actionDescriptor);
    return null;
}
Also used : ChainContextImpl(org.simbasecurity.core.chain.ChainContextImpl) RequestData(org.simbasecurity.api.service.thrift.RequestData) ActionDescriptor(org.simbasecurity.api.service.thrift.ActionDescriptor) RequestActionFactory(org.simbasecurity.common.filter.action.RequestActionFactory)

Aggregations

ActionDescriptor (org.simbasecurity.api.service.thrift.ActionDescriptor)3 RequestData (org.simbasecurity.api.service.thrift.RequestData)3 RequestActionFactory (org.simbasecurity.common.filter.action.RequestActionFactory)3 ChainContextImpl (org.simbasecurity.core.chain.ChainContextImpl)3