Examples of changePassword()


Examples of org.apache.jackrabbit.api.security.user.User.changePassword()

        modify("/", PrivilegeConstants.REP_WRITE, true);

        UserManager testUserMgr = getUserManager(testSession);
        User user = (User) testUserMgr.getAuthorizable(userId);
        try {
            user.changePassword("pw2");
            testSession.save();
            fail();
        } catch (AccessDeniedException e) {
            // success
        }
View Full Code Here

Examples of org.apache.jackrabbit.api.security.user.User.changePassword()

        // after granting user-mgt privilege changing the pw must succeed.
        modify("/", PrivilegeConstants.REP_USER_MANAGEMENT, true);

        UserManager testUserMgr = getUserManager(testSession);
        User user = (User) testUserMgr.getAuthorizable(userId);
        user.changePassword("pw2");
        testSession.save();
    }

    @Test
    public void testDisableUserWithoutPermission() throws Exception {
View Full Code Here

Examples of org.apache.jackrabbit.api.security.user.User.changePassword()

            throw new NotExecutableException();
        }

        User user = getTestUser(superuser);
        try {
            user.changePassword("pw");
            superuser.save();

            // make sure the user can login with the new pw
            Session s = getHelper().getRepository().login(new SimpleCredentials(user.getID(), "pw".toCharArray()));
            s.logout();
View Full Code Here

Examples of org.apache.jackrabbit.api.security.user.User.changePassword()

            // make sure the user can login with the new pw
            Session s = getHelper().getRepository().login(new SimpleCredentials(user.getID(), "pw".toCharArray()));
            s.logout();
        } finally {
            user.changePassword(oldPw);
            superuser.save();
        }
    }

    @Test
View Full Code Here

Examples of org.apache.jackrabbit.api.security.user.User.changePassword()

            throw new NotExecutableException();
        }

        User user = getTestUser(superuser);
        try {
            user.changePassword("pw");
            superuser.save();

            Session s = getHelper().getRepository().login(new SimpleCredentials(user.getID(), oldPw.toCharArray()));
            s.logout();
            fail("superuser pw has changed. login must fail.");
View Full Code Here

Examples of org.apache.jackrabbit.api.security.user.User.changePassword()

            s.logout();
            fail("superuser pw has changed. login must fail.");
        } catch (LoginException e) {
            // success
        } finally {
            user.changePassword(oldPw);
            superuser.save();
        }
    }

    @Test
View Full Code Here

Examples of org.apache.jackrabbit.api.security.user.User.changePassword()

        }

        User user = getTestUser(superuser);
        try {
            try {
                user.changePassword("pw", "wrongOldPw");
                superuser.save();
                fail("old password didn't match -> changePassword(String,String) should fail.");
            } catch (RepositoryException e) {
                // success.
            }
View Full Code Here

Examples of org.apache.vysper.xmpp.authorization.AccountManagement.changePassword()

                }
               
                if(sessionContext.getState().equals(SessionState.AUTHENTICATED)) {
                    if(accountManagement.verifyAccountExists(user)) {
                        // account exists
                        accountManagement.changePassword(user, password);
                    } else {
                        throw new AccountCreationException("Account does not exist");
                    }
                } else {
                    if(accountManagement.verifyAccountExists(user)) {
View Full Code Here

Examples of org.jivesoftware.smack.AccountManager.changePassword()

            if (BuddyList.getInstance().checkConnection()) {
                AccountManager manager = BuddyList.getInstance()
                        .getConnection().getAccountManager();
                try {
                    manager.changePassword(newPass);
                } catch (XMPPException e) {
                    if (e.getXMPPError() == null)
                        errorMessage = e.getMessage();
                    else
                        errorMessage = resources.getString("xmppError"
View Full Code Here

Examples of org.jresearch.gossip.dao.UserDAO.changePassword()

            if (MD5Digest.digest( user.getName(),
                        ((ChangePasswordForm) form).getPassword()
                       )
                       .equals(user.getPassword())) {
                dao.changePassword(((ChangePasswordForm) form).getPassword1(),
                    user.getName());
                log(request, "logs.LOG8");
                user = dao.getUser(user.getName(),
                        ((ChangePasswordForm) form).getPassword1());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.