Added public/private keypairs for user (and hid from logging)
This commit is contained in:
parent
dc7f902182
commit
9f33c8b21d
|
@ -32,7 +32,7 @@ module.exports = class Log {
|
|||
};
|
||||
|
||||
// try to remove sensitive info by default, e.g. 'password' fields
|
||||
['formData', 'formValue'].forEach(keyName => {
|
||||
['formData', 'formValue', 'user'].forEach(keyName => {
|
||||
serializers[keyName] = fd => Log.hideSensitive(fd);
|
||||
});
|
||||
|
||||
|
@ -65,7 +65,7 @@ module.exports = class Log {
|
|||
//
|
||||
return JSON.parse(
|
||||
JSON.stringify(obj).replace(
|
||||
/"(password|passwordConfirm|key|authCode)"\s?:\s?"([^"]+)"/,
|
||||
/"(password|passwordConfirm|key|authCode|private_key_main)"\s?:\s?"([^"]+)"/,
|
||||
(match, valueName) => {
|
||||
return `"${valueName}":"********"`;
|
||||
}
|
||||
|
|
1871
core/user.js
1871
core/user.js
File diff suppressed because it is too large
Load Diff
|
@ -66,4 +66,6 @@ module.exports = {
|
|||
AuthFactor2OTP: 'auth_factor2_otp', // If present, OTP type for 2FA. See OTPTypes
|
||||
AuthFactor2OTPSecret: 'auth_factor2_otp_secret', // Secret used in conjunction with OTP 2FA
|
||||
AuthFactor2OTPBackupCodes: 'auth_factor2_otp_backup', // JSON array of backup codes
|
||||
PublicKeyMain: 'public_key_main', // RSA public key for user
|
||||
PrivateKeyMain: 'private_key_main', // RSA private key (corresponding to PublicKeyMain)
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue