Connecting to SQL Server using credentials stored outside of workflow

Currently at my company, we use KNIME to connect to SQL Server, but we’ve been storing credentials locally in the node and sharing credentials with anyone who uses the KNIME workflows. This has been identified as a security risk, so we’ve decided to explore options for everyone using their credentials and having KNIME reference them separately.

One option is for someone to enter their credentials manually every time they run a KNIME workflow, however, it would be nice if we could set this up so we don’t have to enter credentials manually every time we want to run a workflow.

I know in Alteryx, I was able to store credentials using my Windows ODBC Data Sources Driver, and Alteryx was able to pull them into the workflow. I can’t figure out any way to do something similar in KNIME. Does anyone have any suggestions or ideas for how to do this?

Hi @stevelp,
What you can do is store the credentials in some format on disk, e.g. in a CSV file, and then read them using a CSV Reader. Then you can do Table Row to Variable + Variable to Credentials and then pass the created credentials flow variable to your node. You can also encrypt the content of the CSV using AES Encrypt Column and when you read it use AES Decrypt Column to decrypt it again. You have to be careful not to share an executed workflows with colleagues, though, as the credentials will, at least in a small part of the workflow, be visible in plain text as flow variable values.
For the future, we are currently working on improving this by adding a Credentials store to KNIME Business Hub (our commercial product). This will also come with nodes to retrieve the credentials from the store based on the user the workflow runs for.
Kind regards,


This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.