summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2021-05-09 20:32:04 -0300
committerJesusaves <cpntb1@ymail.com>2021-05-09 20:32:04 -0300
commit126cd33af0fca8051eb9ecc357adcd2f11b7eed8 (patch)
tree778b8fe6b7e15d424d4b04455d706a6b97a2d1a1
parent0149fde4874ea7d05ad970099fb0c91515bd9927 (diff)
downloadapi-126cd33af0fca8051eb9ecc357adcd2f11b7eed8.tar.gz
api-126cd33af0fca8051eb9ecc357adcd2f11b7eed8.tar.bz2
api-126cd33af0fca8051eb9ecc357adcd2f11b7eed8.tar.xz
api-126cd33af0fca8051eb9ecc357adcd2f11b7eed8.zip
Add an (unused) password field to store PBKDF2 hashes to go along TOTP
-rw-r--r--src/routers/vault/models/vault/identity.js4
-rw-r--r--src/routers/vault/types/Identity.js7
2 files changed, 10 insertions, 1 deletions
diff --git a/src/routers/vault/models/vault/identity.js b/src/routers/vault/models/vault/identity.js
index 5162b14..aeac081 100644
--- a/src/routers/vault/models/vault/identity.js
+++ b/src/routers/vault/models/vault/identity.js
@@ -20,6 +20,10 @@ module.exports = {
type: Sequelize.STRING(16),
allowNull: true,
},
+ pass: {
+ type: Sequelize.STRING(128),
+ allowNull: true,
+ },
addedDate: {
type: Sequelize.DATE,
allowNull: false,
diff --git a/src/routers/vault/types/Identity.js b/src/routers/vault/types/Identity.js
index 9a83ffe..2a836b2 100644
--- a/src/routers/vault/types/Identity.js
+++ b/src/routers/vault/types/Identity.js
@@ -24,7 +24,12 @@ class Identity extends Model {
*/
//totp;
/**
- * TOTP 16-chars base64 secret
+ * TOTP 16-chars base64 secret (optional)
+ * @type {string}
+ */
+ //pass;
+ /**
+ * Optional PBKDF2 cryptographic secret to use with 2FA.
* @type {string}
*/
//userId;