EnterpriseDB/repmgr

App is logging clear password in connection string at WARNING level

mulder999 opened this issue · 2 comments

Method dbutils::is_server_available (other methods seems to suffer from same issue) is reporting full connection string with password in clear at WARNING level.

Reproduction is possible for example when connection are exhausted on the corresponding node.

Per https://repmgr.org/docs/current/configuration-password-management.html:

We strongly advise against including the password in the conninfo string, as this will result in the database password being exposed in various places, including in the repmgr.conf file, the repmgr.nodes table, any output generated by repmgr which lists the node conninfo strings (e.g. repmgr cluster show) and in the repmgr log file, particularly at log_level=DEBUG.

Thanks for reply, according to your own documentation, logging the connection string at any level above DEBUG (in this case WARNING) was not expected and provides no benefit to any legitimate user.

Also logging the password in clear text is against OWASP Recommendation.