Comments (9)
Just for reference, I had this issue in a fresh npm install (node v0.2.0 and node-mysql via npm 8/24/10, don't know how to get it's version) on CentOS.
Felixge suggested resetting the password using PASSWORD (see #2 below).
To rectify I tried the following:
- create new user w/new password => FAIL
- SET PASSWORD FOR 'your_user'@'your_host' = PASSWORD('your_password'); (and again with OLD_PASSWORD) => FAIL
- UPDATE mysql.user SET Password = PASSWORD('your_password') WHERE Host = 'your_host' AND User = 'your_user'; (and again with OLD_PASSWORD) => FAIL
from mysql.
Additionally, my issue is verified related as removal the user's password successfully connected.
from mysql.
It looks like all of the oldAuth code linked to above has been removed. If I wanted to implement this, where did you intend it to go?
from mysql.
iamcal: There is a branch called oldpw, see:
http://github.com/felixge/node-mysql/tree/oldpw
It's not rebased with master right now, but the code in question shouldn't cause any conflicts. It'd be really awesome if you could help me with this, let me know if I can provide any help for you.
from mysql.
I've gotten hashPassword(), initRandom(), myRnd() and scamble323() all working in this branch: http://github.com/iamcal/node-mysql/tree/oldpw
The implementation of hashPassword() is buggy on your oldpw branch, so that's been rewritten.
There are a bunch of tests for all the new functions that use the output from tests/fixture/libmysql_password.c as reference. They can be found in test/simple/test-auth-old.js
from mysql.
Wow, thank you so much for you help on this. There are a few things (tabs vs. spaces, test output, etc.) I like to do differently, but no worries - I'll take care of all that : ).
Right now I'm working on integrating your branch into master and testing it against a mysql install that uses the old password mechanism. Once I got this going I'll let you know if it works!
from mysql.
Alright, I got the branch rebased and _sendOldAuth all wired up. When testing against my test install I'm now getting:
Error: Access denied for user 'root'@'my-host-name' (using password: YES)
I've pushed my latest commits up, you can see them here:
http://github.com/felixge/node-mysql/commits/oldpw
If you have a suitable install around it'd be awesome if you could have a look and see if it works for you, or if you are hitting the same problem.
Thanks, --fg
from mysql.
Ok, nevermind my previous comment. Your code works fantastically! I just reformatted the styling a little to go along with the rest of the project and merged your commits into master and released v0.4.0 via npm!
Thank you so much for your help on this one. I wasted hours on my buggy version of hash_password alone, it would have probably taken me forever to finish the rest of stuff you ported.
Everybody else: I'm closing this issue now. Please test if you are now able to connect to your databases and let me know if you hit any issues.
from mysql.
Awesome!
from mysql.
Related Issues (20)
- 腾讯云系统centos7.2安装mysql失败,怎么办麽、 HOT 1
- Error connecting to Aurora DB using the "Amazon RDS" profile HOT 4
- mysql.createPool transaction with loop HOT 1
- Error: ER_NOT_SUPPORTED_AUTH_MODE: Client does not support authentication protocol requested by server; consider upgrading MySQL client HOT 1
- How to catch ER_BAD_FIELD_ERROR HOT 2
- Missing information in Documentation HOT 1
- Multiple insert using array notation HOT 1
- Uncaught exception for "Connection lost: The server closed the connection." HOT 3
- Node 17.4, MySQL Server 8.0, Mac OS Monterey, ECONNREFUSED with error code -61, ::1:3306 HOT 5
- breaks scope HOT 3
- Supported MySQL Versions HOT 2
- readable stream does not seem to support readableLength property HOT 14
- Question - Get query of row HOT 2
- Write cluster failover, pool stuck with read-only cluster HOT 1
- The correct table name when creating the table, with an error: ER_WRONG_TABLE_NAME. HOT 4
- Better type casting of BIT values HOT 3
- the connection string is parsed wrongly HOT 1
- Updating URL parsing to WHATWG URL HOT 2
- RangeError: The value of "offset" is out of range. It must be >= 0 and <= 5254. Received 5261
- getConnection always get timed out
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mysql.