mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-12-20 02:10:15 +01:00
🔏 fix: Enhance Two-Factor Authentication (#6247)
* 🌟 feat: Implement Two-Factor Authentication (2FA) functionality * fix: Two-Factor Authentication Logic and State Management * 🌟 feat: Add LICENSE file and update package version to 0.0.2 with MIT license
This commit is contained in:
parent
cc661c95ee
commit
3e3dfe5bad
15 changed files with 179 additions and 29 deletions
|
|
@ -18,6 +18,7 @@ export interface IUser extends Document {
|
|||
discordId?: string;
|
||||
appleId?: string;
|
||||
plugins?: unknown[];
|
||||
twoFactorEnabled?: boolean;
|
||||
totpSecret?: string;
|
||||
backupCodes?: Array<{
|
||||
codeHash: string;
|
||||
|
|
@ -134,6 +135,10 @@ const User = new Schema<IUser>(
|
|||
plugins: {
|
||||
type: Array,
|
||||
},
|
||||
twoFactorEnabled: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
totpSecret: {
|
||||
type: String,
|
||||
},
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue