@Override public AuthenticationParameters getAuthParameters() { return getWrapped().getAuthParameters(); }
@Override public AuthenticationParameters getAuthParameters() { return getWrapped().getAuthParameters(); }
@Override public AuthenticationParameters getAuthParameters() { return getWrapped().getAuthParameters(); }
@Override public AuthenticationParameters getAuthParameters() { return getWrapped().getAuthParameters(); }
private static boolean hasCredential(HttpMessageContext httpMessageContext) { return httpMessageContext.getAuthParameters().getCredential() != null; }
private static boolean hasCredential(HttpMessageContext httpMessageContext) { return httpMessageContext.getAuthParameters().getCredential() != null; }
@Override public AuthenticationStatus validateRequest(HttpServletRequest request, HttpServletResponse response, HttpMessageContext httpMessageContext) throws AuthenticationException { if (hasCredential(httpMessageContext)) { IdentityStoreHandler identityStoreHandler = CDI.current().select(IdentityStoreHandler.class).get(); return httpMessageContext.notifyContainerAboutLogin( identityStoreHandler.validate( httpMessageContext.getAuthParameters() .getCredential())); } return httpMessageContext.doNothing(); }
@Override public AuthenticationStatus validateRequest(HttpServletRequest request, HttpServletResponse response, HttpMessageContext httpMessageContext) throws AuthenticationException { if (hasCredential(httpMessageContext)) { IdentityStoreHandler identityStoreHandler = CDI.current().select(IdentityStoreHandler.class).get(); return httpMessageContext.notifyContainerAboutLogin( identityStoreHandler.validate( httpMessageContext.getAuthParameters() .getCredential())); } return httpMessageContext.doNothing(); }
private void tryClean(HttpMessageContext httpMessageContext) { // 1. Check if caller aborted earlier flow and does a new request to protected resource if (isOnProtectedURLWithStaleData(httpMessageContext)) { removeSavedRequest(httpMessageContext.getRequest()); removeCallerInitiatedAuthentication(httpMessageContext.getRequest()); } // 2. Check if caller aborted earlier flow and explicitly initiated a new authentication dialog if (httpMessageContext.getAuthParameters().isNewAuthentication()) { saveCallerInitiatedAuthentication(httpMessageContext.getRequest()); removeSavedRequest(httpMessageContext.getRequest()); removeSavedAuthentication(httpMessageContext.getRequest()); } }
private void tryClean(HttpMessageContext httpMessageContext) { // 1. Check if caller aborted earlier flow and does a new request to protected resource if (isOnProtectedURLWithStaleData(httpMessageContext)) { removeSavedRequest(httpMessageContext.getRequest()); removeCallerInitiatedAuthentication(httpMessageContext.getRequest()); } // 2. Check if caller aborted earlier flow and explicitly initiated a new authentication dialog if (httpMessageContext.getAuthParameters().isNewAuthentication()) { saveCallerInitiatedAuthentication(httpMessageContext.getRequest()); removeSavedRequest(httpMessageContext.getRequest()); removeSavedAuthentication(httpMessageContext.getRequest()); } }