SimplePasswordAuthenticator implements PasswordAuthenticator { public boolean authenticate(String pUser, String pPassword, ServerSession pSession) { return pUser != null && pUser.equals(user) && password.equals(pPassword); } SimplePasswordAuthenticator(String pUser, String pPassword); boolean authenticate(String pUser, String pPassword, ServerSession pSession);  }
@Test public void simple() { SimplePasswordAuthenticator auth = new SimplePasswordAuthenticator("roland","secret"); assertTrue(auth.authenticate("roland","secret",null)); assertFalse(auth.authenticate("guenther","uebel",null)); }