MobileFirst 8 UserAuthenticationSecurityCheck javascript class - ibm-mobilefirst

we have working MobileFirst 6.3 javascript adapters on our app and authentication is based on the setActiveUser and getActiveUser of the WL.Server APIs.
Which is the equivalent in MobileFirst 8? I see that there is the UserAuthenticationSecurityCheck, but available only on java Adapters..
Thank you

In MobileFirst Foundation 8.0 authentication flows are implemented using security checks, and security checks are only Java adapters. There is no equivalent for this in JavaScript adapters for v8.0.
I recommend that you will read through the following topics to learn more about migrating to v8.0:
Authentication and security: https://mobilefirstplatform.ibmcloud.com/tutorials/en/foundation/8.0/authentication-and-security/
Migrating applications: https://mobilefirstplatform.ibmcloud.com/tutorials/en/foundation/8.0/upgrading/

Related

Using IBM MobileFirst HTTP Adapters for web application

I have a hybrid mobile app, which is developed on IBM MobileFirst Platform. I have you HTTP adapters for rest api calls. Now i am planning to create a full scale web application in AngularJS 2.0 & BootStrap. Will it be possible to use those adapters in that web application? Please advice.
MobileFirst Foundation does not care for the technology used to create the application... be it native or web. Ionic-based, Angular, Cordova etc... it doesn't matter.
Adapters sit on the server and you make a call to the server to use them... so it doesn't matter what you use in the client.

Does Mobilefirst provide a provision to access web services directly?

I am developing a native android app on MobileFirst platform. Does MobileFirst provide any code to connect to a web service instead of going through adapters? This is basically only for Native Android development and not for Hybrid app.
The MobileFirst SDK only provides what is required to work with features provided by MobileFirst, such as connecting to various backends using Adapters with the added benefit of the MobileFirst security framework, and other features.
If you have a need to connect to backends not via MobileFirst, use other common client-side utilities to achieve that.
I used the following code and it worked.
WLResourceRequest request = new WLResourceRequest("Actual server path here", GET);
request.addHeader(new BasicHeader("IfAnyHeader", "here"));
request.send(new ResponseListener());
If you are using native Android, you could use volley (or similar) to call external web services or REST apis.
http://developer.android.com/training/volley/index.html
Nothing to do with MobileFirst though, all totally standard Android native coding.

IBM Security Access Manager Integration with MobileFirst 6.3

i am working on a MobileFirst application. It needs to be integrated with IBM security access manager. i have configured the login modules, realms and authentication configurations. On the code side, what should be done?.
Read the help for this product: http://www-01.ibm.com/support/docview.wss?uid=swg24034222
The integration package includes sample applications and adapter to
validate successful HTTP header or LTPA token integration, single
sign-on to backend data sources using Worklight Adapters, OAuth
authentication, context/risk-based access, Device Single Sign-On and
MobileFirst Platform Foundation generated Certificate Authentication.
The sample applications and challenge handlers are intended to be used
as references for developing your own IBM MobileFirst Platform
Foundation mobile application integration with IBM Security Access
Manager.

Usage of already deployed REST service in mobile application using IBM Mobile First

I've published a native android application which uses a services with response in JSON format. Now, I want to develop a Hybrid application using IBM Mobile first platform. I want to use the same service here in this case also. I'm not able to findout the mechanism to do so. Anyone please suggest me some solution.
I assume that you intend to build your hybrid app using HTML, CSS and JavaScript.
You could directly call the service using standard JavaScript
XMLHttpRequest(serviceUrl)
But you probably will use some framework such as AngularJS - such frameworks really do pay off in the long run - and in which case you have nice APIs
$http.get(serviceUrl).then(doSomeWork);
However this raw JavaScript approach does not exploit the MobileFirst programming model. We tend to find that using a Mobile Gateway architectural pattern, where MobileFirst adapters act as the gateway, pays off as your application becomes more complex. The adapters provide a security model and can implement aggregation and filtering so that precious mobile bandwidth is used more efficiently.
Hence we recommend that you build adapters, as described in the links given by Idan, and then you use the MobileFirst API to call the adapters:
WL.Client.invokeProcedure( ... );
Starting MobileFirst Platform Foundation 7.0, both the JS framework (for Hybrid apps) and the Native SDK (for iOS and Android) provide REST support. You can accomplish this using either JavaScript adapters or Java adapters.
Read the following tutorials explaining how to use MFP adapters:
Server-side development
If you're interested in Java adapters as well, take a look at these videos as well:
Getting familiar with IBM MobileFirst Platform Foundation Java Adapters [Part 1]
Getting familiar with IBM MobileFirst Platform Foundation Java Adapters [Part 2]

IBM Worklight - Which features a Native app cannot use?

I have a pure native application and wanted to integrate with the worklight (using the Worklight Native SDK).
Which of the below features the native application can not use?
Unified SMS/Push Notifications
Remote Disable
Remote Notify
Adapters
Authentication framework
Direct Update
JSON Store
A Native application that uses the Worklight SDK does not support:
Direct Update
This feature is meant for updating web resources; this feature is currently supported only in Hybrid apps.
JSONStore
This feature is currently supported up to Worklight 6.1.0.x only in Hybrid apps (for the Android and iOS envrionments)