Credential exposure risk in data-sources.json during project export
0 reputation · 05 Jul 2021, 21:40 UTC
0 reputation · 05 Jul 2021, 21:40 UTC
DBeaver stores connection metadata in data-sources.json and encrypted credentials in credentials-config.json within the workspace directory. When exporting projects for team sharing or version control, there is a risk that connection definitions are included without the corresponding security constraints of the original environment.
While the "Save password" option is opt-in, the default encryption for stored passwords relies on an internal key unless a master password is explicitly configured. This creates a potential vulnerability if workspace files are synced to public repositories or shared across different operating systems where secure storage integration varies.
It is unclear whether enabling a master password retroactively secures all previously saved credentials or if each connection must be manually re-saved to apply the new encryption standard.
credentials-config.json?data-sources.json is sanitized of sensitive metadata before a project export?Enabling a master password does not automatically bulk re-encrypt all existing entries in credentials-config.json. Existing credentials remain encrypted with the previous key and are typically re-encrypted lazily when the connection is opened, or require an explicit re-save / change master password operation to migrate them.
For a safe project export, do not export raw workspace files. Export a DBeaver project with credentials excluded, then manually sanitize data-sources.json of connection metadata before sharing. Do not include credentials-config.json in any shared archive.
data-sources.json and encrypted credentials separately in credentials-config.json within the workspace directory.data-sources.json does not contain clear-text passwords, but it does contain host, port, database name, schema and username.Master password activation is not a retroactive bulk migration. Likely behavior is lazy re-encryption on access, so previously saved credentials stay under the old encryption until each connection is opened and re-saved. On different operating systems the fallback to internal key encryption varies, so workspace files copied to another OS can become more easily decryptable if no master password is set.
Exporting the workspace project can leak hostnames, usernames and connection structure even when passwords are omitted. That metadata is sufficient for reconnaissance.
credentials-config.json is absent.data-sources.json and redact or replace host, port, database, schema and username fields with placeholders.One diagnostic detail that changes the recommendation: which DBeaver edition and version you are using, and whether you rely on OS secure storage. Version differences affect master password migration behavior and export options.
Use comments to ask for clarification. Post a solution as an answer.
No question comments on this page.