Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.
TypeScript acmeagentsai-agentscertificate-managementdevsecopsenvironment-variableskubernetesopen-sourcepampkipostgresprivate-caprivileged-access-managementsecret-managementsecret-managersecretssecrets-managementsecuritysecurity-toolsvault
Update 1-user.ts
Daniel5965d17f72ef
diff --git a/backend/src/db/seeds/1-user.ts b/backend/src/db/seeds/1-user.tsindex 4493200a3e..60f67ad7cf 100644--- a/backend/src/db/seeds/1-user.ts+++ b/backend/src/db/seeds/1-user.ts@@ -1,9 +1,9 @@-import bcrypt from "bcrypt";import { Knex } from "knex";import { initializeHsmModule } from "@app/ee/services/hsm/hsm-fns";import { hsmServiceFactory } from "@app/ee/services/hsm/hsm-service";import { getHsmConfig, initEnvConfig } from "@app/lib/config/env";+import { crypto } from "@app/lib/crypto/cryptography";import { initLogger, logger } from "@app/lib/logger";import { kmsRootConfigDALFactory } from "@app/services/kms/kms-root-config-dal";import { superAdminDALFactory } from "@app/services/super-admin/super-admin-dal";@@ -71,7 +71,8 @@ export async function seed(knex: Knex): Promise<void> {.returning("*");// Hash password for modern login support (POST /api/v3/auth/login)- const hashedPassword = await bcrypt.hash(seedData1.password, 10);+ // Uses FIPS-aware hashing: PBKDF2-SHA256 in FIPS mode, bcrypt otherwise+ const hashedPassword = await crypto.hashing().hash(seedData1.password, 10);await knex(TableName.Users).where({ id: user.id }).update({ hashedPassword });const encKeys = await generateUserSrpKeys(seedData1.password);