Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't log value of :connection-uri in db-spec #193

Merged
merged 1 commit into from
Oct 21, 2020

Conversation

whenceforth
Copy link
Contributor

A fix for #189

When logging the db-spec on a connection failure, it replaces a non-empty value
for key :connection-uri entirely, to avoid the difficulties of parsing the uri
and removing only the password.

A fix for yogthos#189

When logging the db-spec on a connection failure, it replaces a non-empty value
for key :connection-uri entirely, to avoid the difficulties of parsing the uri
and removing only the password.
(censor-password
"jdbc:postgresql://fake.example.org/my_dev?user=my_user&password=thisIsNot123ARealPass")))
(is (= {:connection-uri "uri-censored"}
(censor-password {:connection-uri "jdbc:postgresql://fake.example.org/my_dev?user=my_user&password=thisIsNot123ARealPass"})))
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately, my previous change did not handle the case of a map with key :connection-uri, which is what occurs when migratus is called from luminus-migrations.

@yogthos yogthos merged commit 8edb73d into yogthos:master Oct 21, 2020
@yogthos
Copy link
Owner

yogthos commented Oct 21, 2020

Ah thanks for the update, pushed out 1.3.2 with the fix just now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants