mirror of
https://github.com/kmc7468/arkvault.git
synced 2026-02-04 08:06:56 +00:00
MEK 관련 DB 스키마 생성
This commit is contained in:
@@ -18,7 +18,6 @@ export const userClient = sqliteTable(
|
||||
state: text("state", { enum: ["challenging", "pending", "active"] })
|
||||
.notNull()
|
||||
.default("challenging"),
|
||||
encKey: text("encrypted_key"),
|
||||
},
|
||||
(t) => ({
|
||||
pk: primaryKey({ columns: [t.userId, t.clientId] }),
|
||||
@@ -33,7 +32,7 @@ export const userClientChallenge = sqliteTable("user_client_challenge", {
|
||||
clientId: integer("client_id")
|
||||
.notNull()
|
||||
.references(() => client.id),
|
||||
challenge: text("challenge").notNull().unique(), // Base64
|
||||
answer: text("challenge").notNull().unique(), // Base64
|
||||
allowedIp: text("allowed_ip").notNull(),
|
||||
expiresAt: integer("expires_at", { mode: "timestamp_ms" }).notNull(),
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user