Encrypt a password

You can encrypt a password before specifying it in a DITA CMS configuration file.

To encrypt a password, you use the encrypt utility, available in the following locations:
  • Output Generator: %OutputGenDir%/bin
  • Scheduler: %SchedulerDir%/bin

To encrypt a password:

  1. Run the command as follows:
    • On Windows:
      1. Open a command prompt and go to the directory where the encrypt tool is located.
      2. Enter the following command:
        encrypt <password>
        Where <password> is the password that you want to encrypt. For example, to encrypt the password HelloWorld2014, enter:
        encrypt HelloWorld2014
    • On Linux:
      1. Go to the directory where the encrypt tool is located.
      2. Enter the following command:
        ./encrypt.sh <password>
        Where <password> is the password that you want to encrypt. For example, to encrypt the password HelloWorld2014, enter:
        ./encrypt.sh HelloWorld2014
        Note: If you get an error message indicating that Java could not be found, set the JAVA_HOME environment variable to point to the JRE installation and try again.
  2. The tool returns the encrypted password, as follows:
    C:\ixiasoft\OutputGenerators\OutputGen_Prod\bin>encrypt HelloWorld2014
    IXIASOFT Technologies inc.
    ******************************************
    Encrypting [HelloWorld2014]
    Crypted using TripleDES [#!;dI0W5ubkD08UJImaUNnULlbwu2T/5mlvnARNUTgrEDI=]
    Decrypted using TripleDES [HelloWorld2014]
    ******************************************
    The encrypted password is provided on the "Crypted using TripleDES" line, inside the brackets [], as shown in bold above.
    If you are using special characters in your password (for example, <, >, |, &, and &&), make sure that the password that appears on the "Decrypted using TripleDES" line is the one that you encrypted. If that is not the case, enclose your password in double quotes. For example:
    encrypt "Hello\World"
    If your password includes a double quote, specify it as follows:
    • On Windows: Insert the double quote twice; for example:
      encrypt "Hello""World"
    • On Linux: Insert a backslash before the double quote; for example:
      ./encrypt.sh "Hello\"World"
  3. In the configuration file, enter the encrypted string without specifying the brackets.
    For example, in the outputgenerator.xml file, enter the password as follows:
    <outputgenerator>
       <textml address="localhost" port="2500" forceupdate="false" version="4">
          <docbase>Update36_test</docbase>
          <user domain="ixiasoft" name="outgen" password="#!;dI0W5ubkD08UJImaUNnULlbwu2T/5mlvnARNUTgrEDI="/>
          <timeout>500000</timeout>
       </textml>
    </outputgenerator>