Package org.apache.geronimo.jetty8

Examples of org.apache.geronimo.jetty8.Messages


        ContextManager.popCallers((Callers) previousIdentity);

    }

    public Object setRunAs(UserIdentity userIdentity, RunAsToken token) {
        GeronimoRunAsToken geronimoRunAsToken = (GeronimoRunAsToken) token;
        Subject runAsSubject = geronimoRunAsToken == null? null: geronimoRunAsToken.getRunAsSubject();
        return ContextManager.pushNextCaller(runAsSubject);
    }
View Full Code Here


        return new GeronimoUserIdentity(null, null, defaultAcc);
    }

    public RunAsToken newRunAsToken(String runAsName) {
        Subject runAsSubject = runAsSource.getSubjectForRole(runAsName);
        return new GeronimoRunAsToken(runAsSubject);
    }
View Full Code Here

        ContextManager.popCallers((Callers) previousIdentity);

    }

    public Object setRunAs(org.eclipse.jetty.server.UserIdentity userIdentity, RunAsToken token) {
        GeronimoRunAsToken geronimoRunAsToken = (GeronimoRunAsToken) token;
        Subject runAsSubject = geronimoRunAsToken == null? null: geronimoRunAsToken.getRunAsSubject();
        return ContextManager.pushNextCaller(runAsSubject);
    }
View Full Code Here

        return new GeronimoJettyUserIdentity(newUserIdentity(subject));
    }

    public RunAsToken newRunAsToken(String runAsName) {
        Subject runAsSubject = runAsSource.getSubjectForRole(runAsName);
        return new GeronimoRunAsToken(runAsSubject);
    }
View Full Code Here

        ContextManager.popCallers((Callers) previousIdentity);

    }

    public Object setRunAs(UserIdentity userIdentity, RunAsToken token) {
        GeronimoRunAsToken geronimoRunAsToken = (GeronimoRunAsToken) token;
        Subject runAsSubject = geronimoRunAsToken == null? null: geronimoRunAsToken.getRunAsSubject();
        return ContextManager.pushNextCaller(runAsSubject);
    }
View Full Code Here

        return new GeronimoUserIdentity(null, null, defaultAcc);
    }

    public RunAsToken newRunAsToken(String runAsName) {
        Subject runAsSubject = runAsSource.getSubjectForRole(runAsName);
        return new GeronimoRunAsToken(runAsSubject);
    }
View Full Code Here

//            final ServletCallbackHandler callbackHandler = new ServletCallbackHandler(loginService);
            final Subject subject = new Subject();
            final AccessControlContext acc = ContextManager.registerSubjectShort(subject, null, null);
            securityHandlerFactory = new ServerAuthenticationGBean(new Authenticator() {
                public Authentication validateRequest(ServletRequest request, ServletResponse response, boolean mandatory) throws ServerAuthException {
                    return new UserAuthentication("test", new GeronimoUserIdentity(subject, new GeronimoUserPrincipal("foo"), acc));
                }// most likely validatedUser is not needed here.

                public boolean secureResponse(ServletRequest request, ServletResponse response, boolean mandatory, Authentication.User validatedUser) throws ServerAuthException {
                    return true;
                }
View Full Code Here

    }

    public UserIdentity newUserIdentity(Subject subject, Principal userPrincipal, String[] roles) {
        if (subject != null) {
            AccessControlContext acc = ContextManager.registerSubjectShort(subject, userPrincipal, roles == null? null: Arrays.asList(roles));
            return new GeronimoUserIdentity(subject, userPrincipal, acc);
        }
        return new GeronimoUserIdentity(null, null, defaultAcc);
    }
View Full Code Here

        Subject runAsSubject = runAsSource.getSubjectForRole(runAsName);
        return new GeronimoRunAsToken(runAsSubject);
    }

    public UserIdentity getSystemUserIdentity() {
        return new GeronimoUserIdentity(null, null, defaultAcc);
    }
View Full Code Here

//            final ServletCallbackHandler callbackHandler = new ServletCallbackHandler(loginService);
            final Subject subject = new Subject();
            final AccessControlContext acc = ContextManager.registerSubjectShort(subject, null, null);
            securityHandlerFactory = new ServerAuthenticationGBean(new Authenticator() {
                public Authentication validateRequest(ServletRequest request, ServletResponse response, boolean mandatory) throws ServerAuthException {
                    return new UserAuthentication(this, new GeronimoUserIdentity(subject, new GeronimoUserPrincipal("foo"), acc));
                }// most likely validatedUser is not needed here.

                public boolean secureResponse(ServletRequest request, ServletResponse response, boolean mandatory, Authentication.User validatedUser) throws ServerAuthException {
                    return true;
                }
View Full Code Here

TOP

Related Classes of org.apache.geronimo.jetty8.Messages

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.