5 Replies Latest reply on Aug 18, 2015 9:00 AM by dchatter

    Datasource encryption in Jboss EAP 6.1

    anilj

      Hi All,

       

      I am trying to encrypt the clear text password in Jboss EAP 6.1 by running the below command:

       

      java -cp client\jboss-logging-spi.jar;common\lib\jbosssx.jar \org.jboss.resource.security.SecureIdentityLoginModule PASSWORD

       

      but it is failing with below error when I am running this from Jboss_HOME in the command line:

       

      Error: Could not find or load main class \org.jboss.resource.security.SecureIdentityLoginModule

       

      Please let me know what needs to be done.

       

      Thanks for your help in advance.

       

      Regards,

      Anil

        • 1. Re: Datasource encryption in Jboss EAP 6.1
          nicolasritouet

          The SecureIdentityLoginModule is now located in the PicketBox library.

          I use this tiny bash script to encrypt the password:

          #!/bin/bash
          ## Build ClassPath for command
          MYPATH=`pwd`
          CP=
          CP=${CP}:$MYPATH/../modules/system/layers/base/org/picketbox/main/picketbox-4.0.19.SP2-redhat-1.jar
          CP=${CP}:$MYPATH/../modules/system/layers/base/org/jboss/logging/main/jboss-logging-3.1.2.GA-redhat-1.jar
           
          echo "$CP"
          java -classpath ${CP} org.picketbox.datasource.security.SecureIdentityLoginModule $1
          • 2. Re: Datasource encryption in Jboss EAP 6.1
            anilj

            Hi Nicolas,

             

            Thanks for the information. I will try this.

             

            Regards,

            Anil

            • 3. Re: Datasource encryption in Jboss EAP 6.1
              dchatter

              Hi Anil and Nicolas

               

              I am still facing the same issue in EAP6.1.1

               

              Error: Could not find or load main class org.picketbox.datasource.security.SecureIdentityLoginModule

               

              Below is what input I have tried.

               

              java -cp $JBOSS_HOME/modules/system/layers/base/org/picketbox/main/picketbox-4.0.14.Final-redhat-3.jar:$JBOSS_HOME/modules/system/layers/base/org/picketbox/main/picketbox-commons-1.0.0.final-redhat-2.jar:$JBOSS_HOME/modules/system/layers/base/org/picketbox/main/picketbox-infinispan-4.0.14.Final-redhat-2.jar:$JBOSS_HOME/modules/system/layers/base/org/jboss/logging/main/jboss-logging-3.1.2.GA-redhat-1.jar org.picketbox.datasource.security.SecureIdentityLoginModule PASSWORD

               

              Regards

              Debanjan

              • 4. Re: Datasource encryption in Jboss EAP 6.1
                jdws77

                Hi Debanjan,

                 

                I solved this problem on 6.1 with the following:

                 

                java -cp $JBOSS_HOME/modules/system/layers/base/org/picketbox/main/picketbox-4.0.17.SP2-redhat-2.jar:$JBOSS_HOME/modules/system/layers/base/org/jboss/logging/main/jboss-logging-3.1.2.GA-redhat-1.jar: org.picketbox.datasource.security.SecureIdentityLoginModule PASSWORD

                 

                NOTE: Versions may be different, just change accordingly.

                 

                Regards,

                 

                Joel

                • 5. Re: Datasource encryption in Jboss EAP 6.1
                  dchatter

                  Thanks Joel,

                   

                  I have solved the issue by using Eclipse.

                   

                  Referred Picketbox jar in the project and specified Main class as org.picketbox.datasource.security.SecureIdentityLoginModule and supplied the password as argument.

                   

                  Regards

                  Debanjan