This guide explains the integration steps for collecting device fingerprint information via the Cybersource Device Fingerprinting Mobile SDK.
Configuration
You can use Cybersource device fingerprinting information for enhanced security. The device fingerprint is sent together with the payment via the OPP parameter customer.browserFingerprint.id. This feature is available from mSDK version 8.0.1.
To enable this feature, complete the following steps:
Activate the feature in your back office portal. Please contact your account manager for more information.
Import the Cybersource Device Fingerprinting SDK into your project.
iOS
Android
Import the Cybersource Device Fingerprinting SDK into your project
To download the Cybersource Device Fingerprinting Mobile SDK for iOS, log in to the Cybersource developer portal with your credentials.
Download the Cybersource Device Fingerprinting SDK for iOS from the Cybersource developer portal.
After downloading the Cybersource Device Fingerprinting SDK, look for the following frameworks: RLTMXProfiling.xcframework RLTMXProfiling-companion.xcframework RLTMXProfilingConnections-companion.xcframework RLTMXProfilingConnections.xcframework.
Drag and drop the above-mentioned frameworks into the "Frameworks" folder of your project. Make sure "Copy items if needed" is checked.
Check the "Frameworks, Libraries, and Embedded Content" section under the General settings tab of your application's target. Ensure the Embed dropdown has Embed and Sign selected for the frameworks.
To download the Cybersource Device Fingerprinting Mobile SDK for Android, log in to the Cybersource developer portal with your credentials.
Download the Cybersource Device Fingerprinting SDK for Android from the Cybersource developer portal.
After downloading the Cybersource Device Fingerprinting SDK, look for the following frameworks: TMXProfiling-rl-8.0-99.aar TMXProfilingConnections-rl-8.0-99.aar.
Import both the above mentioned aar's into your project inside libs folder
Add below code to the build.gradle:
// this name must match the folder name in which the above aar files are placed.
implementation fileTree(include: ["*.aar"], dir: "libs")
Ready-to-Use UI
If you use our ready-to-use UI and the configuration has been completed successfully, the Cybersource device fingerprint information will be collected and sent automatically.
SDK & Your Own UI
If you use the core SDK with your own UI, you need to follow below given steps to implement the Cybersource device fingerprint collection.
In this guide we assume that you have already implemented all steps for performing standard mSDK transaction.
You need to call a setDeviceFingerprint method on instance of OPPCybersourceDeviceFingerprint. Once the device profile is set, you can submit the transaction using the OPPPaymentProvider instance.
let paymentProvider = OPPPaymentProvider(mode:providerMode)
let deviceFingerprint = OPPCybersourceDeviceFingerprint()
deviceFingerprint.setDeviceFingerprint(transaction,
provider: paymentProvider) {(transaction, error) in
// Handle error if needed
paymentProvider.submitTransaction(transaction) {(transaction, error) in
// Handle transaction result
}
}
You need to call setDeviceFingerPrint method on instance of CyberSourceDeviceFingerprint. Once the device profile is set, you can submit the transaction by passing the transaction object received in the onResult of FingerPrintListener instance.
if you already have CheckoutInfo object which you have already requested then you can pass it in the parameter of setDeviceFingerPrint else pass it null, internally sdk will request CheckoutInfo from server using the checkoutId present in transaction (transaction.getPaymentParams().getCheckoutId()).
new CyberSourceDeviceFingerprint(appContext).setDeviceFingerPrint(
transaction, paymentProvider, checkoutInfo),
(transactionResult, error) -> {
// use the transactionResult to submit transaction.
paymentProvider.submitTransaction(transactionResult, this);
});