Admin password in default authentication - Alfresco Content Services - 23.4 - 23.4 - Ready - Alfresco - external - Alfresco/Alfresco-Content-Services/23.4/Alfresco-Content-Services/Administer/Manage-Security/Authorization/Admin-password-in-default-authentication - 2025-11-03

Alfresco Content Services

Platform
Alfresco
Product
Alfresco Content Services
Release
23.4
License
ft:locale
en-US

The Admin user password is used by the default authentication system.

The Admin password for default authentication is set as a part of the initial bootstrap. This is located in config\alfresco\bootstrap\alfrescoUserStore.xml. The password is MD4 encoded, as required by alfrescoNTLM.

Note: Choose a strong, unique password for your admin account, and consider changing it regularly.

If you lose or forget the password for the admin user, you can reset the password in the database use the following method:

  1. To verify which encoder is being used to store the admin password, perform the following steps:
    Note: You must encode the password using the result of the query.
    1. Enter the following query:
      SELECT anp1.node_id,
              anp1.qname_id,
              anp1.string_value
       FROM alf_node_properties anp1
          INNERJOIN alf_qname aq1 ON aq1.id = anp1.qname_id
          INNERJOIN alf_node_properties anp2 ON anp2.node_id = anp1.node_id
          INNERJOIN alf_qname aq2 ON aq2.id = anp2.qname_id
       WHERE aq1.local_name <LIKEstatement>
       AND aq2.local_name = 'username'
       AND anp2.string_value = 'admin';
    2. Replace <LIKEstatement> with the correct LIKE statement for your database type.
      Note: For the required LIKE statement for your specific database type, search for LIKE syntax, operator, or condition in your database documentation.
    3. Execute the query.
    The current password encoding is displayed, such as in the following example:
     +---------+----------+--------------+
     | node_id | qname_id | string_value |
     +---------+----------+--------------+
     |       4 |       94 | **bcrypt10**   |
     +---------+----------+--------------+
     1 row in set (0.01 sec)
    

    If no rows are returned, set the password using the instructions shown above (md4 encoding).

    If a row is returned, encode the password using the result of the query, which can either be md4 or sha256 or bcrypt10 encoding.

  2. To find the identifying parameters for how the admin password is stored, perform the following steps:
    1. Enter the following query:
      SELECT anp1.node_id,
              anp1.qname_id,
              anp1.string_value
       FROM alf_node_properties anp1
          INNERJOIN alf_qname aq1 ON aq1.id = anp1.qname_id
          INNERJOIN alf_node_properties anp2 ON anp2.node_id = anp1.node_id
          INNERJOIN alf_qname aq2 ON aq2.id = anp2.qname_id
       WHERE aq1.local_name <LIKEstatement>
       AND aq2.local_name = 'username'
       AND anp2.string_value = 'admin';
      
    2. Replace <LIKEstatement> with the correct LIKE statement for your database type.
      Note: For the required LIKE statement for your specific database type, search for LIKE syntax, operator, or condition in your database documentation.
    3. Execute the query.
    The current hashed password for the admin user is displayed, such as in the following example:
     +---------+----------+--------------------------------------------------------------+
     | node_id | qname_id | string_value                                                 |
     +---------+----------+--------------------------------------------------------------+
     |       4 |       93 |**$2a$10$dq/2zNUA.MmECYipl1WMoOyGHYbaygh23PUa3Ox5xDHH7Z0guqF42**|
     +---------+----------+--------------------------------------------------------------+
     1 row in set (0.00 sec)
    
  3. To update the password, use the following command:
    UPDATE alf_node_properties
      SET string_value='209c6174da490caeb422f3fa5a7ae634'
      WHERE
      node_id=THENODEIDABOVE
      and
      qname_id=THEQNAMEVALUEABOVE
    

    Replace THENODEIDABOVE and THEQNAMEVALUEABOVE with the result values of node_id and qname_id, obtained in the previous step. In this example, it is 4 and 93, respectively.

    Note: Ensure that you use appropriate AND conditions in the UPDATE query.
  4. Restart Content Services.