# Change user password

**URL:** <https://community.ofelia.com/t/change-user-password/6891>\
**Category:** Q&A\
**Created:** [22 January 2016 20:52 UTC](https://community.ofelia.com/t/change-user-password/6891 "2016-01-22T20:52:21Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![mzhu](https://dub1.discourse-cdn.com/flex013/user_avatar/community.ofelia.com/mzhu/32/827_2.png) [@mzhu](https://community.ofelia.com/u/mzhu)\
**Post date:** [22 January 2016 20:52 UTC](https://community.ofelia.com/t/change-user-password/6891/1 "2016-01-22T20:52:21Z")

</div>

Hey guys quick question here, as a user without an admin profile is there a way to change your password?

---

<div class="post-metadata">

**Author:** ![system](https://europe1.discourse-cdn.com/flex013/uploads/community_bonitasoft/original/2X/6/6b7b18c0478f2645369e82e009b65e3b97f2cc12.svg) [@system](https://community.ofelia.com/u/system)\
**Post date:** [25 January 2016 16:52 UTC](https://community.ofelia.com/t/change-user-password/6891/2 "2016-01-25T16:52:48Z")

</div>

Hi,

Natively in Bonita BPM Portal it is not possible but I can suggest two options:

- You can create a new process definition with new password as contract input and use a Groovy script connector on process instance start to call Bonita Engine API to update the password (see [updateUser](http://documentation.bonitasoft.com/javadoc/api/7.1/org/bonitasoft/engine/api/UserAPI.html#updateUser(long,%20org.bonitasoft.engine.identity.UserUpdater)))
- Second option would be to build a [REST API extension](http://documentation.bonitasoft.com/rest-api-extensions), use the same API method as the previous solution and call the REST API extension from your [application page](http://documentation.bonitasoft.com/key-concepts-2).

---

<div class="post-metadata">

**Author:** ![mzhu](https://dub1.discourse-cdn.com/flex013/user_avatar/community.ofelia.com/mzhu/32/827_2.png) [@mzhu](https://community.ofelia.com/u/mzhu)\
**Post date:** [27 January 2016 13:20 UTC](https://community.ofelia.com/t/change-user-password/6891/3 "2016-01-27T13:20:10Z")

</div>

Thnx for answering just another little question, for security purpose I would like to make the person write their old password before they can change their password so I was thinking to create a custome API that connect to the user database of bonita and compare the introduced password with the one stored in the database but I understand that for security reason bonita store their password with a hash so I was wondering what kind of hash does it use?

---

<div class="post-metadata">

**Author:** ![system](https://europe1.discourse-cdn.com/flex013/uploads/community_bonitasoft/original/2X/6/6b7b18c0478f2645369e82e009b65e3b97f2cc12.svg) [@system](https://community.ofelia.com/u/system)\
**Post date:** [27 January 2016 13:44 UTC](https://community.ofelia.com/t/change-user-password/6891/4 "2016-01-27T13:44:02Z")

</div>

Default hash is MD5 (see [MD5CredentialsEncrypter.java](https://github.com/bonitasoft/bonita-engine/blob/master/services/bonita-identity/bonita-identity-impl/src/main/java/org/bonitasoft/engine/identity/impl/MD5CredentialsEncrypter.java)).

Also you might try to use [LoginAPI](http://documentation.bonitasoft.com/javadoc/api/7.1/org/bonitasoft/engine/api/LoginAPI.html) to perform the verification (not sure how it behave if user is already logged in).

---

<div class="post-metadata">

**Author:** ![mzhu](https://dub1.discourse-cdn.com/flex013/user_avatar/community.ofelia.com/mzhu/32/827_2.png) [@mzhu](https://community.ofelia.com/u/mzhu)\
**Post date:** [27 January 2016 13:56 UTC](https://community.ofelia.com/t/change-user-password/6891/5 "2016-01-27T13:56:32Z")

</div>

Awesome thnx a lot Antoine!
