Unknown authenticationOk message type
See original GitHub issueWith postgres 10.1 and SCRAM-SHA-256 password encryption enabled, node-postgres driver throws the following error:
Error: Unknown authenticationOk message typeMessage { name: 'authenticationOk', length: 23 }
Not telling that encryption method is not supported or anything. It took a while to find out why my app is stopped working after i have changed the role name. I think there should be more verbose error for this case.
Issue Analytics
- State:
- Created 6 years ago
- Reactions:14
- Comments:18 (1 by maintainers)
Top Results From Across the Web
node.js - Getting Error: Unknown authenticationOk message ...
I'm trying to set it up in windows. And getting the below error in windows 10. Error: Unknown authenticationOk message typeMessage { name:...
Read more >Db login action script (postgresql) Unknown authenticationOk ...
using the "test' feature on the login script page I get the error: “Unknown authenticationOk message typeMessage { name: 'authenticationOk', ...
Read more >pg: Error: Unknown authenticationOk message typeMessage
Problem: Error: Unknown authenticationOk message typeMessage { name: 'authenticationOk', length: 23 } at Connection.
Read more >SOLVED: RE: unknown authentication type? - PostgreSQL
Message-ID ... TYPE DATABASE IP_ADDRESS MASK AUTH_TYPE AUTH_ARGUMENT host all xx.0.0.1 255.255.255.0 ... Unknown authentication type #201.
Read more >Getting Error: Unknown authenticationOk message ...
Coding example for the question Getting Error: Unknown authenticationOk message typeMessage { name: 'authenticationOk', length: 23 }-postgresql.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Hello, I have the same problem. after migrate postgres 9 to 10, the database switch to SCRAM-SHA-256 password encryption. but this pg_client is not compatible
first, change the postgresql.conf file : password_encryption = md5
and restart database. but not works …
lookup users password encryption whith superuser (postgres) : SELECT rolname, rolpassword FROM “pg_authid”;
if password start with “SCRAM-SHA-256” (and not “md5”), it’s too late, but not the end of world.
–> change all user with SCRAM-SHA-256 password for reset them : (always whith postgres superuser) : alter role xxxxx with password ‘yyyyy’; (with xxxxx is the username, and yyyyy the new password)
–> the password is now encrypted with md5 crypto : SELECT rolname, rolpassword FROM “pg_authid”; –> the password start with “md5”
and now, i can use this pg_client without this error
explanation : the size “23” is because he know password is encrypted with SCRAM-SHA-256, and change the auth message for ask SCRAM password, and it’s not implemented yet …
have fun !
I have same problem and worked around it by installing
pg-nativeand settingNODE_PG_FORCE_NATIVE=1environment variable.