Encrypt/Decrypt GitHub PAT token in PPM

Hello Team, We are integrating GitHub with PPM, and in order to clone GitHub repository in HPPPM server we are using Personal Access Token. Now this personal access token being a password we don't want to store it in plain text f anywhere, neither in application ,nor in server. PPM offers kEncrypt.sh to encrypt a text , but there is no decryption mechanism and while calling git clone command we need to provide decrypted PAT token. Can you please suggest any encryption /decryption mechanism available within PPM itself.

git clone https://[ACCESS_TOKEN]@ec-github.power.ge.com/OpenGE-HC/PROJECTNAME.git

  • 0  

    Hi Madhu,

    If you use kEncrypt.sh to encrypt a value and store it as a server parameter in server.conf (even a new parameter that you create yourself) , I think that PPM will automatically decrypt it at runtime and make the original value available to you. However I'm not sure whether there's the right special commands in order to retrieve arbitrary server parameter values, maybe someone has more information here.

    Another option may be to create a "dummy" environment and store the token in one of the environment password (I think these passwords are encrypted in DB). You can then retrieve the decrypted value using tokens for this Environment.

  • Verified Answer

    +1 in reply to   

    Thank you so much Etienne the second option worked.