UNPKG

gigya-node

Version:
45 lines 2.31 kB
"use strict"; var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { if (k2 === undefined) k2 = k; Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); }) : (function(o, m, k, k2) { if (k2 === undefined) k2 = k; o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); exports.TFATotp = void 0; __exportStar(require("./interfaces/gigya-response"), exports); __exportStar(require("./interfaces/base-params"), exports); __exportStar(require("./interfaces/tfa"), exports); var TFATotp = /** @class */ (function () { function TFATotp(gigya) { this.gigya = gigya; } /** * It creates a Gigya assertion that contains some information about the user, the site, and the mode (whether registration or verify). * It creates a secret that is expressed to the user as a QR code, used by the user for pairing their authenticating app, and a secret token, * that is part of the actual authentication * * @see https://help.sap.com/docs/SAP_CUSTOMER_DATA_CLOUD/8b8d6fffe113457094a17701f63e3d6a/413c65da70b21014bbc5a10ce4041860.html */ TFATotp.prototype.totpRegister = function (params, options) { return this.gigya.request('accounts.tfa.totp.register', params, options); }; /** * This method is part of a two-factor authentication (TFA) flow and is triggered after the user submits the code generated by the authenticating app * (after accounts.tfa.totp.register). It verifies the code against the secret saved to this user's account, * and is followed by accounts.tfa.finalizeTFA. Note that TFA is part of Risk Based Authentication (RBA). * * @see https://help.sap.com/docs/SAP_CUSTOMER_DATA_CLOUD/8b8d6fffe113457094a17701f63e3d6a/413cb1cd70b21014bbc5a10ce4041860.html */ TFATotp.prototype.totpVerify = function (params, options) { return this.gigya.request('accounts.tfa.totp.verify', params, options); }; return TFATotp; }()); exports.TFATotp = TFATotp; exports.default = TFATotp; //# sourceMappingURL=tfa.totp.js.map