Authentication factors
Introduction
Mangopay is delivering SCA via a unique session on a hosted webpage. The URL for the session is returned on relevant API calls, and your platform needs to redirect the user to complete the session – see SCA session for details on how to do this.
For the user, Mangopay’s SCA session provides a user-friendly experience that guides them efficiently through all the necessary steps relating to all required factors.
Mangopay’s hosted SCA session handles both enrollment and authentication.
Note – Session lifetime 10 minutes
The unique SCA session is valid for 10 minutes once the PendingUserAction.RedirectUrl is returned by the API.
During this time, the individual must complete all necessary steps for all factors for the session to be considered successful.
The session is identified by the unique token in the RedirectUrl. So if the user refreshes the screen, or closes and re-opens the same link, then they can continue using the same session within 10 minutes.
Customization
By default, the SCA hosted experience is tailored to your platform by using:
-
Your platform’s trading name, shown by TradingName in the screenshots below.
To modify the trading name text, contact Mangopay via the Dashboard.
-
Your platform’s logo, if provided
To add or update the logo, send a new file on the PUT Update a Client Logo endpoint (for example, using Postman) or contact Mangopay. To remove the logo entirely, contact Mangopay.
Branding colors
You can also customize two accent colors of the hosted experience to match your branding. To do so, you need to do two things:
- Define the
PrimaryThemeColourandPrimaryButtonColourhex values by calling the PUT Update a Client endpoint (for example, using Postman). Note that you need to wait about an hour for the API colors to appear in the SCA session. - Add the query parameters to the SCA
RedirectUrlvalue to use the colors in the session when you redirect the user:- Add
&primary=trueto use thePrimaryThemeColour - Add
&cta=trueto use thePrimaryButtonColour
- Add
If you set only primary=true, then the PrimaryThemeColour is used for the CTA button as well as the icon accent elements.
If you set only cta=true, then the PrimaryButtonColour is used for the CTA button and the T&Cs checkbox, but not the icon accents.
Example
In the screenshot below:
- The Mangopay logo is a purple PNG file uploaded via the PUT Update a Client Logo
- Both query parameters (
&primary=true&cta=true) have been added to theRedirectUrlvalue before redirection (after the encodedreturnUrl) - The
PrimaryThemeColouris the purple (#867EFF) of the icon accent elements (except the Mangopay logo) - The
PrimaryButtonColouris the green (#89E481) of the CTA button
Theme
You can also force dark mode or light mode for the user, but note that if the user changes it in the session then their preference is stored as a local cookie and takes precedence for 30 days:
- Add
&theme=darkfor dark mode - Add
&theme=lightfor light mode
Localization
The hosted SCA page is automatically set to the language of the user’s browser if it is one of the following supported languages: Bulgarian, Dutch, English, French, German, Greek, Italian, Polish, Portuguese, Spanish, Swedish.
Regional variants for the same language resolve to the single translation supported by Mangopay: e.g. es-419 (Latin American Spanish) resolves to es, en-US (American English) resolves to en.
If the browser is in a language not listed above, the session is in English by default.
You can override this and manually set the language for the session before you redirect the user – read more.
If the SMS OTP factor is used, then it is also localized based on the browser language or your override.
iframe integration
If your integration is opening the SCA session in an iframe, whether on mobile or desktop, then you need to follow the guidance below to allow the passkey factor to function correctly. Otherwise, your users won’t be able to benefit from this highly secure and low-friction authentication factor.
Allow Mangopay’s SCA domains
If the SCA session is opened in an <iframe>, then to offer the passkey you need to give permission to Mangopay’s SCA domains to generate and retrieve passkeys on the device.
This applies to both desktop and mobile flows that use an <iframe> to render the SCA session. On mobile, note that you can also integrate the passkey natively as described below.
In your <iframe> element, add the allow property to give the following permissions to Mangopay’s SCA domains.
Mangopay’s hosted SCA domains:
https://sca.sandbox.mangopay.com– Sandbox for testing and integrationhttps://sca.mangopay.com– Production
The permissions required by the SCA session:
publickey-credentials-create– To create a passkey on the devicepublickey-credentials-get– To retrieve a passkey from the deviceotp-credentials(optionally, for OTP factor) – To enable the auto-filling of an OTP code received on the device
Add Mangopay’s domain origins for each permission in the allow property as shown below. If you’re using a single environment with both the Sandbox and Production versions of Mangopay’s SCA hosted experience, then you can list both domain origins separated by a space for each permission directive.
Sandbox SCA
Production SCA
Both
Share and verify your domains with Mangopay
By default, the SCA session detects the <iframe> and skips the passkey for security reasons, which means your users can’t benefit from this highly secure and seamless authentication factor.
To offer the passkey in an iframe in full security, Mangopay needs to add your domains to an allowlist. This ensures that the <iframe> can only be rendered in your specified domains, which prevents an unauthorized third-party from embedding the SCA session somewhere else.
To share and verify your domains with Mangopay:
- Ensure you have integrated the iframe’s
allowproperty as described above to give permission for the SCA session to load the passkey. - Contact Mangopay via the Dashboard to share the domain origin (e.g.,
https://www.example.com) of your testing integration where the<iframe>is loaded. - Mangopay will add your testing domain to an allowlist so you can test the passkey in your testing environment using the Sandbox SCA session. Mangopay will also ensure your Sandbox integration is working as expected.
- Once both your platform and Mangopay validate the testing integration, you can share your production domain for Mangopay to allow and verify in the same way.
Mobile breakpoint
The breakpoint between mobile and desktop is 600px, so to ensure the desktop version is rendered you should set that as the minimum width. The height is variable depending on the content in both the options implemented, the screens for each factor, and the localization.
Welcome screen
On the RedirectUrl, the user first sees a Mangopay-branded welcome screen explaining the steps that are required from them.
Welcome screen on enrollment
Below is an example of the SCA welcome screen for an Owner user enrolling at user creation:
Welcome screen on authentication
Below is an example of the SCA welcome screen for a on Owner authenticating a transfer request above 30 EUR:
The wording is adapted for both enrollment and authentication depending on the scenario. The platform trading name is always shown, along with:
- For a transfer request, the transfer currency and amount
- For recipient bank account registration, the IBAN or local account number
- For wallet access, a mention of access to personal account information
See what conditions trigger SCA in Sandbox for more support with testing each scenario: users, recipients, transfers, and wallet access.
Email confirmation behavioral biometrics
Thanks to its expertise in AI-powered fraud prevention, Mangopay is developing a model to use behavioral biometrics to analyze the way the user types their email address.
In it’s current form, the step is not a factor. Rather, it allows Mangopay to collect anonymized behavioral data on the user’s keyboard or touchscreen movements. This is made possible thanks to Mangopay’s fraud prevention profiler integrated in the hosted SCA session.
In the coming months, Mangopay plans to validate the email confirmation step as an SCA inherence factor. Once validated, it will enable the user to authenticate using only email confirmation and PIN (and not OTP SMS). The OTP SMS factor would be used in case the model returns an uncertain or failed assessment.
Note – Email address requested to build behavioral profile
Mangopay’s hosted SCA session asks the user to enter their email address during both enrollment and authentication.
This enables Mangopay’s profiler to build a behavioral biometrics model that in future will make it possible to use the email entry as a valid SCA factor.
For Legal Soletrader users, the address used is the LegalRepresentative.Email (and not the Email). For Natural users, the address used is the Email.
Mangopay processes behavioral biometric data captured during SCA sessions solely to fulfill its authentication obligations as a regulated financial institution.
Factors
Mangopay provides the following authentication factors.
Logic governing trusted devices
Defining a trusted device using a WebAuthn passkey is attempted if the user’s device supports the technology.
If the user enrolls a trusted device, then only the PIN is enrolled as the second factor.
If the user authenticates using a trusted device, then the passkey alone satisfies SCA because it is a combination of two factors.
If at either point the passkey factor is not successful, then the PIN and OTP are both used. Skipping the passkey is possible during authentication even if a device is already enrolled because the user may not be using their trusted device.
Passkey
The passkey factor relies on the Web Authentication, or WebAuthn, standard to create a set of two passkeys (or credentials):
- A public key that is not secret and is stored on the Mangopay server
- A private key that is secret and is stored on the user’s device
The private key is accessed using the device’s authentication features: for example, a password or fingerprint on a laptop; or a passcode, fingerprint, or face on a smartphone.
Because WebAuthn doesn’t rely on a new password, it is more resistant to phishing and data breaches. It has wide adoption on web browsers and mobile devices.
If you are opening the SCA session in an <iframe>, see the iframe integration section above to ensure the passkey can operate correctly and securely.
Passkey on mobile
For mobile app integrations, passkeys are not supported if the RedirectUrl is opened in a webview (and the factor enrollment or authentication will fail). The factor must be integrated natively. If it is not, then the passkey remains optional but will fail if the user attempts to use it.
See the dedicated guides for details native integration of the passkey:
Passkey device enrollment
To enroll, the user:
- Selects where to store the passkey from the options proposed by their device
- Authenticates using their device authentication feature (biometrics, password, passcode)
Below is an example of the enrollment process using Chrome on MacOS, a passkey stored in a Google Chrome profile, and the laptop password.
Passkey device authentication
During authentication:
- Indicates that they are using their trusted device
- Selects the passkey to use
- Authenticates using their device authentication feature (biometrics, password, passcode)
Below is an example of the authentication process using Chrome on MacOS, a passkey stored in a Google Chrome profile, and the laptop password.
PIN
The PIN factor relies on a 6-digit code defined and memorized by the individual, which they enter during the session.
PIN enrollment
To enroll, the individual:
- Defines and confirms a 6-digit PIN
- Enters their PIN defined previously
PIN authentication
To authenticate, the individual:
- Enters their PIN defined previously
OTP
The OTP factor relies on a temporary 6-digit code sent to the individual’s phone, which they can enter during the session.
If your integration is opening the SCA in an <iframe>, you may wish to give the device permission to auto-fill the OTP code – see the iframe integration section above for details.
Note – OTP lifetime 5 minutes
While the SCA session is valid for 10 minutes, once the user clicks the button to send the SMS, the code is valid for 5 minutes.
The user can request a new code after 30 seconds, even if the first one hasn’t expired.
OTP enrollment
To enroll, the individual:
- Enters their mobile phone number (or confirms the pre-populated number, if
PhoneNumberwas present in the API call to create or update the user) - Enters the 6-digit code received by SMS
OTP authentication
To authenticate, the individual:
- Enters the 6-digit code received by SMS
SMS wording
The text of the SMS is adapted to the action being performed:
Use
123456to confirmActionNameonPlatformTradingName.
The possible ActionName wordings are:
your registrationthe registration of a bank accountthe transferthe access to your wallet details
The SMS is localized depending on the browser language or the value you define when you redirect the user – read more.
Test data
In Sandbox, you can use the phone number 0611111111 and FR (+33611111111) with the passcode 702100 to simulate a successful flow. You can also send this data in the PhoneNumber (or LegalRepresentative.PhoneNumber) to pre-populate the field.
You can also test by using a real phone number to receive the SMS OTP.
Handling phone number data
Mangopay’s SCA session allows the individual to provide their phone number directly to Mangopay. This data is not shared with your platform for privacy reasons. The same phone number can be used with more than one user account.
Your platform can send the user’s phone number to Mangopay via the API – in the PhoneNumber parameter of the Natural User or the LegalRepresentative.PhoneNumber of the Legal User.
If the phone number data is present in the user object, then the field is pre-populated for the user to confirm or modify.
Note – SCA session phone number doesn’t update API
The phone number provided or confirmed by the user during the SCA session is not subsequently updated in the User API object.
Changing the PhoneNumber or LegalRepresentative.PhoneNumber data in the API object triggers SCA re-enrollment (read more).
Factor orchestration
The SCA session is orchestrated to optimize the enrollment and authentication experience for users.
The session meets SCA requirements and is highly secure, including if the user chooses to re-enroll a factor during the session.
The diagrams below describe the different possible flows and all options available to the user.
Note – Email confirmation
Email confirmation is required in all flows, with the exception of authentication via passkey (email is still required during passkey enrollment).
Once the email confirmation is validated as a factor, the enrollment and authentication flows will modify to adopt it.
The email address used is the Email for Natural users and the LegalRepresentative.Email for legal users. The address cannot be changed by the user during the session; it can only be changed via API, which triggers the re-enrollment flow below.
Initial enrollment
When the user is redirect to a Mangopay SCA session for the first time:
- Mangopay analyzes their device to see if it supports WebAuthn passkey. If it does, then the factor enrollment is attempted.
- If the passkey is enrolled successfully (no error occurs), then the PIN and email are used as a backup (and not SMS).
Mangopay has integrated the passkey to be a combined possession (of the device) and inherence or knowledge type (depending on the device’s authentication). Furthermore, the email confirmation step is not required on authentication (it is still required for enrollment or re-enrollment).
The WebAuthn passkey represents one of the most secure web-based authentication methods available, being resistant to fraudulent attacks (such as phishing) as well as technical issues (like SMS deliverability). The technology also provides an excellent user experience.
Authentication
When the user is prompted to authenticate:
- The passkey is the only factor that can be skipped (even if it is enrolled, as the user may not be on their enrolled device). If it is enrolled and then skipped, then the PIN is used.
- The user can opt to change re-enroll either the PIN or the OTP SMS during an authentication session. The other is used to authenticate the one that is changed.
- The user cannot modify their email address (only possible via API, see below).
Re-enrollment via API
The email cannot be changed by the user during the SCA session; it can only be changed via the API. The phone number can be changed by the user during the SCA session and if it is, then the data is not updated in the API User object.
The diagram below shows the re-enrollment flow in the case of phone number or email change via API (the authentication flow above shows phone number change in the session).
Webhooks
To assist with your SCA integration, your platform can set up webhooks for:
- Overall SCA enrollment
- The verification of the email and/or phone number data when it is added or changed and then an SCA session is completed successfully