Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Dear all,
Our client is not allowed to have the passwords clear text (for example in C:\users\qliksense_account\AppData\Roaming\pgpass.conf )
I read that Integrated Security is possible in Postgresql, editing the pg_hba.conf file and specifying the authentication mode sspi.
But, the services are connecting to the repository with a password!
How to do it? Is it somehow possible?
thanks in advance for your help!
nice regards,
Emma
I also can't save the password in plain text in pgpass for taking repository backup. Any solutions for this?
Try this:
So the .pgpass file needs to be in the user's profile doing the pg_dump command. Reference: https://www.postgresql.org/docs/9.6/static/libpq-pgpass.html
In PowerShell, this style of approach should work:
cd $env:userprofile\AppData\Roaming\postgresql\
if (Test-Path $env:userprofile\AppData\Roaming\postgresql\pgpass.conf) {
} else {
"localhost:4432:$([char]42):postgres:INSERTYOURSUPERUSERPASSWORD" | set-content pgpass.conf -Encoding Ascii
}
Refer this link:
But, in pagpass, the password will be stored in plain text right? I have created a key file and an encrypted password file using powershell. Can I decrypt and use that password in pg_dump? Can I store the files in some other location other than the pgpass location?
May be it helps for encryption:
Remove $env:userprofile\AppData\Roaming\postgresql\pgpass.conf