Setup
What is LBFraud web SDK?
LBFraud web SDK is the piece that allow you to integrate Ironchip LBFraud in your web environment. Using it Ironchip can evaluate if the device and environment that uses the website is secure. To add the SDK to the website you just need to follow the next steps.
Min tested version
Browser | Minimum Tested Version |
---|---|
Chrome | 68.0.3440.91 |
Firefox | 60.0 |
Mobile Safari | 12.1.2 |
Brave | 119.0.0.0 |
Edge | 97.0.1072.62 |
Opera | 95.0.0.0 |
Chromium | 76.0.3809.100 |
Chrome WebView | 84.0.4147.89 |
GSA (Google Search App) | 130.0.337455237 |
DuckDuckGo | 5 |
Silk | 108.7.2 |
Samsung Browser | 17.0 |
PaleMoon | 32.2.0 |
Avast Secure Browser | 109.0.24252.121 |
Huawei Browser | 12.1.3.304 |
MIUI Browser | 10.9.8 |
Yandex | 24.9.1.56.00 |
Whale | 3.4.5.2 |
JavaScript integration
This setup can be done on a JavaScript file or directly over the HTML in script tags. We recommend using the SDK in JavaScript and always obfuscating it.
Add Node.js package:
npm i ironchip-fraud-detection-web-sdk
npm i https://github.com/Ironchip-Security/Ironchip-Fraud-Detection-Web-SDK/releases/download/{VERSION}/ironchip-fraud-detection-web-sdk-{VERSION}.tgz
Then you just have to import the package with:
//import the lbfraud_sdk library
import { LBFraudSDK,LBFraudSDKEnvironment } from 'ironchip-fraud-detection-web-sdk';
Then, with the SDK imported you need to initialize the client. Please ensure that you have the API- Key and the environment where you will work. By default the chosen environment is Production.
You will initialize the client (Choose just one environment):
const client = new LBFraudSDK({
apiKey: 'api-key',
environment: LBFraudSDKEnvironment.Development,
LBFraudSDKEnvironment.Testing,
LBFraudSDKEnvironment.Production,
});
Our advice is to obfuscate this code, due to it contains the API-Key.