voxpupuli / puppet-zabbix

Puppet module for creating and maintaining zabbix components with puppet.
https://forge.puppet.com/puppet/zabbix
Apache License 2.0
80 stars 227 forks source link

Escape string inside update_pgpass command #831

Closed src386 closed 11 months ago

src386 commented 2 years ago

Pull Request (PR) description

The update_pgpass resource may fail when using strong ${database_password} that contain special characters such as & because the echoed string is not escaped. This Pull request adds double quotes shell_escape() (as suggested by @smortex).

This Pull Request (PR) fixes the following issues

ekohl commented 11 months ago

In https://github.com/voxpupuli/puppet-zabbix/pull/904 I've taken another approach where I provide all the data via env vars, removing the need for the pgpass file altogether.