Skip to content

Fix demo login seeded admin password#4367

Open
thefatcode wants to merge 3 commits intoopensourcepos:masterfrom
thefatcode:fix-demo-login-4365
Open

Fix demo login seeded admin password#4367
thefatcode wants to merge 3 commits intoopensourcepos:masterfrom
thefatcode:fix-demo-login-4365

Conversation

@thefatcode
Copy link

@thefatcode thefatcode commented Jan 16, 2026

Fixes #4365.

The seeded admin user in the DB init SQL had a bcrypt hash that no longer matched the documented demo credentials (admin / pointofsale). This caused the public demo login to fail.

Changes:

  • Update the seeded admin password hash in app/Database/tables.sql so admin / pointofsale works again.
  • Add a PHPUnit guard test that validates the embedded seed hash still verifies pointofsale.

Files:

  • app/Database/tables.sql
  • tests/Database/AdminCredentialsSeedTest.php
  • tests/phpunit.xml

Test:

  • php vendor/bin/phpunit --configuration tests/phpunit.xml

- Update ospos_employees seed hash so admin/pointofsale works

- Add PHPUnit guard test to prevent future regressions (issue opensourcepos#4365)
@thefatcode thefatcode changed the title Fix demo login 4365 Fix demo login seeded admin password Jan 16, 2026
@jekkos
Copy link
Member

jekkos commented Jan 18, 2026

hi @thefatcode thanks for the PR and nice find. The fact that the password in tables.sql does not match the hashed version might be expected. There is a migration script that should update it to the correct bcrypt hash.

The issue is that currently demo server does not run latest master yet, a fix was done that prevents the password change and once 3.4.2 is officially out, the lockout issue should stop occuring.

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

Successfully merging this pull request may close these issues.

[Bug]: Demo login credentials not working.

2 participants