2 Replies Latest reply on Jul 15, 2016 5:03 PM by gnik9

    CLI remote execution with encrypted password

    gnik9

      Hi,

       

      I want to use the CLI remotely without the clear-text password.

      I am using below right now, but want to encrypt the password. Any thoughts ?

       

      ./jboss-cli.sh --connect --controller:$HOSTNAME:9999 --user=<userid> --password=<clear-textpassword>

       

      Thanks,

      Nik

        • 1. Re: CLI remote execution with encrypted password
          mchoma

          If you are writing automate script and you are worried about password beeing seen in history and ps output, then you can set password from standard input

           

          jboss-cli.sh -c <<EOF

          user

          password

          <your commands>

          EOF

           

          In that way password won't be shown in history neither in ps output.

          • 2. Re: CLI remote execution with encrypted password
            gnik9

            Thanks, but i have to execute multiple batch with username password passed as the command line input because i don't want to prompt the user multiple times to input the credentials. I could do that in a shell script, by reading the user credentials and passing them to the jboss-cli.sh as a runtime value, but that will show-up in the ps output, at least for sometime and is a security concern, so don't want to do that.

             

            There seems to be some solution at https://access.redhat.com/solutions/970773  but i'm not a registered user ..