HCL Commerce Developer

Setting the spiuser password in HCL Commerce Developer

You must set the spiuser user password in your HCL Commerce development environment to allow for your HCL Commerce servers to function together as expected.

About this task

All servers in HCL Commerce Developer are hard coded to use a default spiuser user password.
The default password for the spiuser user in the provided sample DB2 Docker container is:
  • HCL Commerce Version 9.1.9.0 or laterHCL Commerce 9.1.9.0 or greater:

    QxV7uCk6RRiwvPVaa4wdD78jaHi2za8ssjneNMdu3vgqi

  • HCL Commerce 9.1.0.0 to 9.1.8.0:

    passw0rd (with a zero)

If you specified a different password during Loading the HCL Commerce Developer database schema, then you must update your server properties so that the password is synchronized with the one that is in the database.
HCL Commerce Version 9.1.9.0 or laterImportant: Even if you are using the default provided password with HCL Commerce 9.1.9.0 or greater, you must run the setSpiuserPassword utility with the default password. For your convenience, the example in the procedure includes the default password value.

Procedure

  1. Open a command line interface and navigate to the WCDE_installdir\bin\ directory.
    Set your spiuser user password in your HCL Commerce development environment. The method that you will use depends on the version of HCL Commerce Developer that you are using.
    VersionProcedure
    Using HCL Commerce 9.1.9.0 or greater
    1. Use the setSpiuserPassword utility to set the spiuser user password throughout your HCL Commerce development environments.
      In the command prompt, run:
      setSpiuserPassword spiuser_plain_text_password
      For example:
      setSpiuserPassword QxV7uCk6RRiwvPVaa4wdD78jaHi2za8ssjneNMdu3vgqi
    2. Generate the merchantKey encrypted password, and store it in the database.
      1. Obtain the salted spiuser password from the database.
        Open a database command line prompt, and run the following against your database.
        select salt from userreg where logonid='spiuser';
      2. Generate the encrypted spiuser password.

        In a separate command prompt, run the following HCL Commerce command utility located in the /opt/WebSphere/CommerceServer90/bin/ directory.

        ./wcs_password.bat plain_text_spiuser_password salt unencrypted_merchantKey_value
      3. Store the encrypted password in the database.
        In the database command line prompt, update the encrypted password.
        update userreg set logonpassword=x'encrypted_hexadecimal_output' where logonid = 'spiuser';
        Note: The x'encrypted_hex_output' is required to store the value in hexadecimal format.
    Using HCL Commerce 9.1.0.0 to 9.1.8.0
    1. Encrypt the spiuser user password, and update your Transaction server.
      1. Navigate to the WCDE_installdir\bin\ directory.
      2. Run the wcs_encrypt command to encrypt the spiuser user password.
        wcs_encrypt.bat spiuser_plain_text_password
        Ensure that the spiuser_plain_text_password is the same plain text password that you specified in Loading the HCL Commerce Developer database schema.
      3. Copy the ASCII encrypted string.
      4. Update the password for the Transaction server.
        1. Open the WCDE_installdir/wasprofile/config/cells/localhost/nodes/localhost/servers/server1/server.xml file.
        2. Update the value of the system property spi.password with the ASCII encrypted string.
    2. Generate the merchantKey encrypted password, and store it in the database.
      1. Obtain the salted spiuser password from the database.
        Open a database command line prompt, and run the following against your database.
        select salt from userreg where logonid='spiuser';
      2. Generate the encrypted spiuser password.

        In a separate command prompt, run the following HCL Commerce command utility located in the /opt/WebSphere/CommerceServer90/bin/ directory.

        ./wcs_password.bat plain_text_spiuser_password salt unencrypted_merchantKey_value
      3. Store the encrypted password in the database.
        In the database command line prompt, update the encrypted password.
        update userreg set logonpassword=x'encrypted_hexadecimal_output' where logonid = 'spiuser';
        Note: The x'encrypted_hex_output' is required to store the value in hexadecimal format.
    3. Update the ASCII encoded password value in the Search server and Store server to the one that was generated in step #a.ii.
      1. Open the Liberty_installdir/usr/servers/crsServer/jvm.options file.
      2. Update the value of the spi.password with the ASCII encrypted string.
      3. Open the Liberty_installdir/usr/servers/searchServer/jvm.options file.
      4. Update the value of the spi.password with the ASCII encrypted string.
      5. Save and close both files.
    4. Update the encrypted password in the WebSphere Application Server V8.5.5 Liberty configuration for the Search server and Customization server.
      1. In a command line interface, go to Liberty_installdir/bin/.
      2. Run the following command to encrypt the plain text spiuser password.
        securityUtility.bat encode spiuser_plain_text_password
      3. Copy the output string.
        For example,
        {xor}Lz4sLChvLTs=
      4. Open the Liberty_installdir/usr/servers/searchServer/configDropins/overrides/userregistry.xml file.
      5. Update the value of the password with the output string.
      6. Open the Liberty_installdir/usr/servers/commerceueServer/configDropins/overrides/userregistry.xml file.
      7. Update the value of the password with the output string.
      8. Save and close both files.
  2. If the Transaction, Search, Store, or Customization servers are running, restart the servers.

Results

The spiuser user password has been set in your HCL Commerce development environment to correspond with the one that is encrypted in the associated development database.