protected boolean checkLogin ( final String _name , final String _passwd ) { boolean loginOk = false ; Context context = null ; try { context = Context . begin ( ) ; boolean ok = false ; try { if ( this . loginHandler . checkLogin ( _name , _passwd ) != null ) { loginOk = true ; } ok = true ; } finally { if ( ok && Context . isTMActive ( ) ) { Context . commit ( ) ; } else { if ( Context . isTMMarkedRollback ( ) ) { AbstractAuthenticationFilter . LOG . error ( "transaction is marked to roll back" ) ; } else { AbstractAuthenticationFilter . LOG . error ( "transaction manager in undefined status" ) ; } Context . rollback ( ) ; } } } catch ( final EFapsException e ) { AbstractAuthenticationFilter . LOG . error ( "could not check name and password" , e ) ; } finally { context . close ( ) ; } return loginOk ; }
Checks if the user with given name and password is allowed to login .