Package com.adito.security.forms

Examples of com.adito.security.forms.AuthenticationSchemesForm


    public ShowAuthenticationSchemesDispatchAction() {
        super(PolicyConstants.AUTHENTICATION_SCHEMES_RESOURCE_TYPE, PolicyConstants.AUTHENTICATION_SCHEMES_RESOURCE_TYPE);
    }

    private AuthenticationScheme getAuthenticationScheme(ActionForm form) throws Exception {
        AuthenticationSchemesForm schemesForm = (AuthenticationSchemesForm) form;
        int id = schemesForm.getSelectedResource();
        AuthenticationScheme scheme = SystemDatabaseFactory.getInstance().getAuthenticationSchemeSequence(id);
        if (scheme == null) {
            throw new Exception("No scheme with Id of " + id + ".");
        }
        return scheme;
View Full Code Here


     *      javax.servlet.http.HttpServletRequest,
     *      javax.servlet.http.HttpServletResponse)
     */
    public ActionForward confirmRemove(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws Exception {
        PolicyUtil.checkPermission(getResourceType(), PolicyConstants.PERM_DELETE, request);
        AuthenticationSchemesForm schemesForm = (AuthenticationSchemesForm) form;
        int id = schemesForm.getSelectedResource();
        AuthenticationScheme scheme = getAuthenticationScheme(form);
        if (scheme.isSystemScheme()) {
            throw new Exception("Cannot remove system schemes.");
        }
       
View Full Code Here

     * @throws Exception on any error
     */
    public ActionForward disable(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response)
                    throws Exception {
        PolicyUtil.checkPermission(PolicyConstants.AUTHENTICATION_SCHEMES_RESOURCE_TYPE, PolicyConstants.PERM_EDIT_AND_ASSIGN, request);
        AuthenticationSchemesForm schemesForm = (AuthenticationSchemesForm) form;
        int id = schemesForm.getSelectedResource();
        AuthenticationScheme scheme = getAuthenticationScheme(form);

        List resourceIds = PolicyDatabaseFactory.getInstance().getGrantedResourcesOfType(getSessionInfo(request).getUser(),
            PolicyConstants.AUTHENTICATION_SCHEMES_RESOURCE_TYPE);
        // remove the WebDav and Embedded Client as they are not sign-on-able.
View Full Code Here

        response.setHeader("Cache-Control", "no-cache");
        response.setHeader("Pragma", "must-revalidate");
       
        CoreUtil.clearFlow(request);

        AuthenticationSchemesForm schemesForm = (AuthenticationSchemesForm) form;
        schemesForm.initialize(getSessionInfo(request), getSessionInfo(request).getNavigationContext() == SessionInfo.MANAGEMENT_CONSOLE_CONTEXT ?
                        SystemDatabaseFactory.getInstance().getAuthenticationSchemeSequences(getSessionInfo(request).getUser().getRealm().getRealmID())
                        : ResourceUtil.getGrantedResource(getSessionInfo(request), getResourceType()));
        Util.noCache(response);
        return mapping.findForward("display");
    }
View Full Code Here

TOP

Related Classes of com.adito.security.forms.AuthenticationSchemesForm

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.