Skip to content

Postgres password hashing issue #4548

Open
@XaFFaX

Description

@XaFFaX

Checklist

  • Have you pulled and found the error with jc21/nginx-proxy-manager:latest docker image?
    • Yes
  • Are you sure you're not using someone else's docker image?
    • Yes
  • Have you searched for similar issues (both open and closed)?
    • Yes

Describe the bug
When setting new password for user in UI console the password is being saved but it cannot be used. When entering to log in it always fails. Seems to be an issue with hashing of the password in the database. When I manually enter the password hash into the auth table of the database, the password works fine (using: update auth set secret='[hashed_secret]' where id='[id]';).

What I believe is important is that I am using ARM device as host for NPM running under Docker with Postgres 17 database. According to the documentation there were no requirements concerning version of Postgres database and this platform (ARM64) is supported. The CPU used for the deployment is Rockchip RK3566 with 8GB of RAM.

Nginx Proxy Manager Version
2.12.3

To Reproduce
Steps to reproduce the behavior:

  1. Run new instance of NPM.
  2. Login using default credentials (works fine).
  3. Create new user and password.
  4. Logout.
  5. Login does not work with new password.

Workaround

  1. Generate the same (or any other) password using bcrypt hash generator.
  2. Insert into auth table generated password as indicated above.
  3. Login with new password works fine.

Summary
Pre-generated hashes work fine, hashes generated and saved in the database by the application do not work and do not match with password when checked with hash validation tools.

Expected behavior
Able to login with changed password.

Screenshots
Not applicable.

Operating System
Linux DietPi 5.10.160-legacy-rk35xx #1 SMP Wed Jul 10 09:57:26 UTC 2024 aarch64 GNU/Linux

Additional context
Not needed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions