When we use Connect Database activity the connection string with username and password is not encrypt. Does UiPath provide anyway to secure Database connection string? Thanks a lot.
What you can do here is use the Get Password activity to encrypt your connectionString and then pass that to the Connect activity.
Thanks, thats a great solution, but I dont understand how it works, so I have some difficulty applying it. Would you help me understand?
Lets say my db connectionstring is a string variable:
value “user id=abc;password=123;data source=TNS1”
if I use connStrTxt as the password parameter for the GetPassword activity, and set the output string to use a string variable named “connStrEncrypted”, and then use the connStrEncrypted as the ConectionString in the DatabaseConnect activity it will fail.
If instead I put the value of connStrTxt, without including the starting " and the ending ", in Get Password activity, the run will succeed.
I would like to be able to input a variable name, not its value in the Get Password activity, so I can build a parameterized string.
I hope I made myself understandable.
Best regards Mikkel
Set your DB password as secure encrypted string in Get Password activity with mysecuredbpswd as output parameter and then Use your connection string in Connect Database activity as below -
“Data Source=;Initial Catalog=;Persist Security Info=True;User ID=;Password=”+ mysecuredbpswd +“”
In this way you could encrypt any part of the connection string by using multiple get password activities
But doesn’t the password still initially have to be a string, which is then converted into a encrypted sting? Is that safe?