fix: seed-admin emits $2y$ bcrypt prefix so Laravel admin login works (was $2a$ -> 500 'does not use the Bcrypt algorithm')

This commit is contained in:
2026-08-10 12:00:03 +10:00
parent ae231c97f6
commit b5db858ef8
2 changed files with 4 additions and 0 deletions

View File

@@ -40,6 +40,10 @@ func main() {
fmt.Fprintln(os.Stderr, "hash:", err)
os.Exit(1)
}
// Go's bcrypt emits "$2a$"; PHP/Laravel login requires "$2y$" (same
// algorithm, different marker). Rewrite the prefix so the admin can log
// into the Filament panel. Both Go and PHP verify either prefix.
hash = "$2y$" + hash[4:]
ctx := context.Background()
pool, err := pgxpool.New(ctx, dsn)

BIN
frontend/seed-admin Executable file

Binary file not shown.