1 Reply Latest reply on Mar 12, 2015 3:14 PM by Bill Robinson

    jython : connecting to BSA with a credential file "user_info.dat"

    Guillaume Pierre

      Hi all,


      I'm using BSA 8.3.

      I'm developing a jython script that performs actions in BSA.

      This script is not run within the NSH context, it is run with the following command :

      bljython /path/to/my/script/my_script.py (+ args)

      Up to now, my script authenticates to BSA in that way (by building an object "BMCBackend") :


      from bladelogic.cli import CLI


      class BMCBackend(object):

           def __init__(self, user, password, role, profile):

                self.jli = CLI.CLI()







      And it works fine.


      My problem is that the "password" is read by "my_script.py" from a file that can be opened by other persons.

      I have a credential file "user_info.dat" and i would like my script to authenticate to BSA with it.

      I insist on the fact that this is not read in the NSH context, so my script cannot call blcred command.


      Does anyone have a suggestion on this ?

      Thank you in advance for it.