
Research
Security News
Lazarus Strikes npm Again with New Wave of Malicious Packages
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
@allboatsrise/gigya-react-native-plugin-for-sap-customer-data-cloud
Advanced tools
A React Native plugin for interfacing SAP Customer Data Cloud
A React Native plugin for interfacing with SAP Customer Data Cloud. This plugin provides quick access to core elements & business API flows available within SAP Customer Data Cloud; designed for React Native mobile applications.
This plugin is currently in an early developers preview stage.
Android SDK support requires Android SDK 14 and above. iOS support requires iOS 10 and above.
Add the plugin in your package.json file.
Add the following to your MainApplication.java file:
@Override
public void onCreate() {
super.onCreate();
SoLoader.init(this, /* native exopackage */ false);
initializeFlipper(this, getReactNativeHost().getReactInstanceManager());
// Set and initialize the account schema for the Gigya core SDK.
GigyaSdkModule.setSchema(this, GigyaAccount.class);
}
Navigate to AppDelegate.m and add the following under the: **(BOOL)application:(UIApplication )application didFinishLaunchingWithOptions:(NSDictionary )launchOptions method.
GigyaExtension * gigya = [[GigyaExtension alloc] init];
[gigya setMySchema];
To apply your custom schema, you will need to create a 'swift bridge' file and register it as follows:
@objc public class GigyaExtension: NSObject {
@objc func setMySchema() {
GigyaSdk.setSchema(HostModel.self)
}
}
And then call the function from your AppDelegate.m file.
In your application code, you can initialize the Gigya SDK using the following call:
Gigya.initFor("Your API KEY", "API DOMAIN");
If you do not specify the "API DOMAIN" (as implemented in the sample application) the SDK will use the default us1.gigya.com domain.
To run the example application included in the repository:
** Android - If changing the API key, make sure to update the signingConfigs section as the example app includes a specific keystore path used for testing purposes ***
signingConfigs {
debug {
storeFile file('debug.keystore')
storePassword 'android'
keyAlias 'androiddebugkey'
keyPassword 'android'
}
}
Sending a request is available using the plugin's send method.
try {
const send = await Gigya.send("socialize.getSDKConfig");
console.log("send: " + JSON.stringify(senddd));
} catch (error) {
console.log("errorSend:" + error);
}
The plugin provides an interface to these core SDK business APIs: login, register, getAccount, setAccount, isLoggedIn ,logOut, addConnection, removeConnection Implement them using the same request structure as shown above. The example application includes various different implementations.
Use the "socialLogin" interface to perform social login using supported providers. The React Native plugin supports the same *providers supported by the Core Gigya SDK.
Supported social login providers: google, facebook, line, wechat, apple, amazon, linkedin, yahoo.
For example:
const send = await Gigya.socialLogin("facebook");
Specific social providers (Facebook, Google) require additional setup. This is due to their requirement for specific (embedded native) SDKs.
To register social providers you will need to create a 'swift bridge' file (same as with using a custom schema). Don't forget to add the relevant wrappers to the ios folder.
Follow the core SDK documentation and instructions for setting up Facebook login. Android documentation iOS documentation
Follow the core SDK documentation and instructions for setting up Google login. Android documentation iOS documentation
To provide support for LINE as a provider, please follow it's core SDK documentation. Android documentation iOS documentation
To provider support for WeChat as a provider, please follow the core SDK documentation. Android documentation iOS documentation
The plugin supports the use of Web screen-sets using the following:
Gigya.showScreenSet("Default-RegistrationLogin", (event, data) => {
console.log(`event: ${event}`);
if (event == "onLogin") {
updateIsLoggedIn(Gigya.isLoggedIn())
}
})
Optional {params} map is available.
As in the core SDKs, the plugin provides a streaming channel that will stream the Screen-Sets events (event, map).
event - actual event name. data - event data map.
Much like our core SDKs, resolving interruptions is available using the plugin.
Current supporting interruptions:
Example for resolving conflictingAccounts interruptions:
try {
const send = await Gigya.register(login, password, { 'sessionExpiration': 0 });
console.log("send: " + JSON.stringify(senddd));
updateIsLoggedIn(Gigya.isLoggedIn())
} catch (error) {
console.log("register error:" + error);
const e = error as GigyaError;
switch (e.getInterruption()) {
case GigyaInterruption.conflictingAccounts: {
const resolver = Gigya.resolverFactory.getResolver(e) as LinkAccountResolver;
console.log("link:")
console.log(resolver.regToken)
break
}
}
}
Once you reference your resolver, create your relevant UI to refelct if a site or social linking is required (see example app for details) and use the relevant method.
Example of resolving link to the site when trying to link a new social account to a site account.
const loginToSite = await resolver.linkToSite(userData.login, userData.password)
None
Via pull request to this repository. Please read the CONTRIBUTING file for guidelines.
None
Please see our LICENSE for copyright and license information.
FAQs
A React Native plugin for interfacing SAP Customer Data Cloud
The npm package @allboatsrise/gigya-react-native-plugin-for-sap-customer-data-cloud receives a total of 0 weekly downloads. As such, @allboatsrise/gigya-react-native-plugin-for-sap-customer-data-cloud popularity was classified as not popular.
We found that @allboatsrise/gigya-react-native-plugin-for-sap-customer-data-cloud demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
Security News
Socket CEO Feross Aboukhadijeh discusses the open web, open source security, and how Socket tackles software supply chain attacks on The Pair Program podcast.
Security News
Opengrep continues building momentum with the alpha release of its Playground tool, demonstrating the project's rapid evolution just two months after its initial launch.