wolfboys opened a new pull request, #4352:
URL: https://github.com/apache/streampark/pull/4352
### What changed
- Replace new password storage from salted SHA-256 to PBKDF2-HMAC-SHA256.
- Use 600,000 PBKDF2 iterations, 16-byte random salt, and a
self-describing password hash format.
- Keep legacy SHA-256 verification only for successful-login migration.
- Rehash legacy or lower-work-factor password hashes after successful
authentication.
- Update user create/update/reset flows to store PBKDF2 hashes.
- Expand `t_user.password` from `varchar(64)` to `varchar(255)` for PBKDF2
hash strings.
- Update seed user password hashes.
- Remove `ShaHashUtils` and keep legacy SHA-256 compatibility inside
`PasswordHashUtils`.
### Why
The previous password storage used fast SHA-256 hashing, which is not
appropriate for password storage and is vulnerable to offline brute-force
attacks if the password
database is leaked.
PBKDF2-HMAC-SHA256 is available from the JDK, avoids adding new
dependencies, and directly addresses the vulnerable password hashing behavior
with minimal code and
dependency changes.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]