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

Password authentication fails for Postgres (11) connections #158

Open
dspinellis opened this issue Dec 22, 2020 · 4 comments
Open

Password authentication fails for Postgres (11) connections #158

dspinellis opened this issue Dec 22, 2020 · 4 comments

Comments

@dspinellis
Copy link

  • Running node ./node_modules/express-admin/app.js express-admin-examples/config/pg/ errors with password authentication failed for user "liolio".
  • The password and database setup seem to be correct, because providing the same password to psql -W -h 127.0.0.1 express-admin-examples liolio succeeds.
  • The authentication method used by Postgres seems to be the same in both cases, because providing a wrong password to psql causes the connection to fail with exactly the same logged information as that produced by express-admin.
liolio@express-admin-examples DETAIL:  Password does not match for user "liolio".
        Connection matched pg_hba.conf line 94: "host    all             all             127.0.0.1/32            md5"

Could the error stem from an outdated node-postgres library? Currently provided node-posgres connection examples don't seem to work with the library version distributed with express-admin. For example, the first code sample fails with TypeError: Pool is not a constructor.

@simov
Copy link
Owner

simov commented Dec 22, 2020

Yes, last time this module was tested was around 2015 so just by looking at the pg versions on NPM something like https://www.npmjs.com/package/pg/v/4.3.0 should work.

The documentation definitely needs an update.

@dspinellis
Copy link
Author

Thank you for the swift reply! Sadly, running npm install [email protected] does not fix the problem.

@simov
Copy link
Owner

simov commented Feb 17, 2023

Hi again, recently I tested the module again, you can check out my package.json version for reference. Then I tested with these two versions of PostgreSQL.

@dspinellis
Copy link
Author

Thank you! Note that I'm no longer trying to use this package, so I'll not be able to provide feedback.

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

No branches or pull requests

2 participants