fix(security): remove salt from database (#5412)

This commit is contained in:
Meier Lukas authored and GitHub committed 2026-04-10 20:48:20 +02:00
1 parent 41a03ef4e0
commit 2454cac7be
24 files changed
+6198 -81

No files matched your search

@@ -29,7 +29,7 @@ export const usersUpdatePassword = command({
where: options.id ? eq(users.id, options.id) : eq(users.name, options.username!),
});
if (!user?.salt) {
if (!user?.password) {
console.error("User not found or has no credentials record");
return;
}
@@ -37,7 +37,7 @@ export const usersUpdatePassword = command({
await db
.update(users)
.set({
password: await hashPasswordAsync(options.password, user.salt),
password: await hashPasswordAsync(options.password),
})
.where(eq(users.id, user.id));