public void setPostFailureUrl ( String postFailureUrl ) { AuthenticationFailureHandler failureHandler = getFailureHandler ( ) ; if ( failureHandler instanceof SocialAuthenticationFailureHandler ) { failureHandler = ( ( SocialAuthenticationFailureHandler ) failureHandler ) . getDelegate ( ) ; } if ( failureHandler instanceof SimpleUrlAuthenticationFailureHandler ) { SimpleUrlAuthenticationFailureHandler h = ( SimpleUrlAuthenticationFailureHandler ) failureHandler ; h . setDefaultFailureUrl ( postFailureUrl ) ; } else { throw new IllegalStateException ( "can't set postFailureUrl on unknown failureHandler, type is " + failureHandler . getClass ( ) . getName ( ) ) ; } }
The URL to redirect to if authentication fails or if authorization is denied by the user .