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: 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.
Procedure
-
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.
-
Encrypt the spiuser user password by running the following command.
-
Copy the ASCII encoded string.
-
Update the ASCII encoded password for the Transaction server.
-
Open the
WCDE_installdir/wasprofile/config/cells/localhost/nodes/localhost/servers/server1/server.xml
file.
-
Update the value of the system property spi.password with
the ASCII encoded string.
-
Generate the merchantKey encrypted password, and store it in the database.
-
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';
-
Encrypt the salted password with the merchantKey.
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
-
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.
-
Update the ASCII encoded password in the Search server and
Store server.
-
Open the
Liberty_installdir/usr/servers/crsServer/jvm.options
file.
-
Update the value of the spi.password with the ASCII encoded
string.
-
Open the
Liberty_installdir/usr/servers/searchServer/jvm.options
file.
-
Update the value of the spi.password with the ASCII
encrypted string.
-
Update the encrypted password in the Search server and Customization serverWebSphere Application Server Liberty configuration for the
Search server and Customization server.
-
In a command line interface, go to
Liberty_installdir/bin/.
-
Run the following command to encrypt the plain text spiuser password.
securityUtility.bat encode spiuser_plain_text_password
-
Copy the output string.
For example,
{xor}Lz4sLChvLTs=
-
Open the
Liberty_installdir/usr/servers/searchServer/configDropins/overrides/userregistry.xml
file.
-
Update the value of the password with the output
string.
-
Open the
Liberty_installdir/usr/servers/commerceueServer/configDropins/overrides/userregistry.xml
file.
-
Update the value of the password with the output
string.
-
Save and close both files.
-
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.