Pages

Tuesday, November 23, 2010

Encoding websphere commerce or websphere commerce build and deploy properties files with sensitive information like userId and password

Encoding websphere commerce or websphere commerce build and deploy properties files with sensitive information like userId and password

Generally, Websphere Commerce Build and Deploy (WCBD) have many properties files containing information about the build and deployment. Usually you would store userId and Password for configuration manager like an svn or a cvs.

To encode properties in a file, follow the steps below

  1. Open a command window and change directory to the application server bin directory.
For example,
C:\RAD601\runtimes\base_v6\profiles\default\bin assuming C:\RAD601 is my RAD installation directory and base_v6 is the websphere 6 installation directory.

  1. Execute the following command

PropFilePasswordEncoder.bat  <<source_file path>> <<properties_to_encode>> [-Backup/-noBackup]

Provide the source properties file path followed by comma separated properties to encode and optionally specify whether the original file has to be backed up or not.

PropFilePasswordEncoder.bat "C:\Documents and Settings\chetanr\Desktop\extract-svn.private.properties" svn.user,svn.password -Backup

In the above example, I have properties file containing svn login information for my websphere commerce build. I need to encode the login information to secure it from being viewable to other users of the system.

This is not a fool proof way for the userid and password to be stored since it is a basic Base64 encoding done by websphere.

No comments:

Post a Comment