fix: disable api key hashing
This commit is contained in:
@@ -42,7 +42,8 @@ export const initAuth = (db: dbClient) => {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
plugins: [
|
plugins: [
|
||||||
apiKey(),
|
// @todo: hasing is disabled due to a bug in the api key plugin
|
||||||
|
apiKey({ disableKeyHashing: true }),
|
||||||
magicLink({
|
magicLink({
|
||||||
expiresIn: 60 * 60 * 24 * 7, // 7 days
|
expiresIn: 60 * 60 * 24 * 7, // 7 days
|
||||||
sendMagicLink: async ({ email, url }) => {
|
sendMagicLink: async ({ email, url }) => {
|
||||||
|
|||||||
@@ -51,7 +51,7 @@ export const verification = pgTable("verification", {
|
|||||||
updatedAt: timestamp("updatedAt"),
|
updatedAt: timestamp("updatedAt"),
|
||||||
}).enableRLS();
|
}).enableRLS();
|
||||||
|
|
||||||
export const apiKey = pgTable("apikey", {
|
export const apiKey = pgTable("apiKey", {
|
||||||
id: bigserial("id", { mode: "number" }).primaryKey(),
|
id: bigserial("id", { mode: "number" }).primaryKey(),
|
||||||
name: text("name"),
|
name: text("name"),
|
||||||
start: text("start"),
|
start: text("start"),
|
||||||
|
|||||||
Reference in New Issue
Block a user