(mfaData)
| 116 | this.algorithm = opts.algorithm || 'SHA1'; |
| 117 | } |
| 118 | validateSetUp(mfaData) { |
| 119 | if (mfaData.mobile && this.sms) { |
| 120 | return this.setupMobileOTP(mfaData.mobile); |
| 121 | } |
| 122 | if (this.totp) { |
| 123 | return this.setupTOTP(mfaData); |
| 124 | } |
| 125 | throw 'Invalid MFA data'; |
| 126 | } |
| 127 | async validateLogin(loginData, _, req) { |
| 128 | const saveResponse = { |
| 129 | doNotSave: true, |
no test coverage detected