Package com.bradmcevoy.http.AuthenticationService

Examples of com.bradmcevoy.http.AuthenticationService.AuthStatus


        }
    }

    public AuthStatus checkAuthentication( HttpManager manager, Resource resource, Request request ) {
        log.trace( "checkAuthentication" );
        AuthStatus authStatus = authenticationService.authenticate( resource, request ); //handler.authenticate( auth.user, auth.password );
        if( authStatus == null ) {
            log.trace("checkAuthentication: null authStatus");
            return null;
        } else {
            log.trace("checkAuthentication: authStatus.failed =" + authStatus.loginFailed);
View Full Code Here


        }
    }

    public boolean checkAuthorisation( HttpManager manager, Resource resource, Request request ) {
        log.trace("checkAuthorisation");
        AuthStatus authStatus = checkAuthentication( manager, resource, request );
       
        // a null authStatus means that no authentication was attempted, eg an anonymous request
        // it is up to the implementation to decide whether or not to allow anonymous access
        // however a failed login must always be rejected
        if( authStatus != null && authStatus.loginFailed ) {
View Full Code Here

                }
                responseHandler.respondMethodNotImplemented( resource, response, request );
                return;
            }

            AuthStatus authStatus = resourceHandlerHelper.checkAuthentication( manager, resource, request );
            if( authStatus != null && authStatus.loginFailed ) {
                if( log.isTraceEnabled() ) {
                    log.trace( "authentication failed. respond with: " + responseHandler.getClass().getCanonicalName() + " resource: " + resource.getClass().getCanonicalName() );
                }
                responseHandler.respondUnauthorised( resource, response, request );
View Full Code Here

                log.debug( "resource not compatible. Resource class: " + resource.getClass() + " handler: " + getClass() );
                responseHandler.respondMethodNotImplemented( resource, response, request );
                return;
            }

            AuthStatus authStatus = resourceHandlerHelper.checkAuthentication( manager, resource, request );
            if( authStatus != null && authStatus.loginFailed ) {
                log.debug( "authentication failed. respond with: " + responseHandler.getClass().getCanonicalName() + " resource: " + resource.getClass().getCanonicalName() );
                responseHandler.respondUnauthorised( resource, response, request );
                return;
            }
View Full Code Here

TOP

Related Classes of com.bradmcevoy.http.AuthenticationService.AuthStatus

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.