How to authenticated in an SAP hybrid app against SMP and a backend system with different users?

1k Views Asked by At

Following situation:

  • An SAP OnPremise system is connected over cloud connector to SAP HCP
  • In the cloud version of the SAP mobile plattform (SMP) I configured the system
  • I have a hybrid app (using SAP Kapsel SDK) and try to connect to
  • a) SMP itself (registring)
  • b) also to the real backend sytem with the data needed
  • User name of SMP and backend system is not the same

Does anyone have a good tutorial / documentation link how to setup this correct?

I found a very good tutorial about the Kapsel plugins: - https://blogs.sap.com/2016/10/20/getting-started-kapsel-part-1-sp13/

With a trial account and a trial backend account (same user name) it seems somehow working. But in my situation it is more complex.

Problem in other words (Edit)

I am searching for a way to use user & password from OnPremise system to authenticate against HCPms over a Hybrid app.

1

There are 1 best solutions below

4
On BEST ANSWER

May I ask why you require two different users at all? From a usability point of view, it is very awkward for a user to give two sets of credentials for an app. I'd typically recommend to either

  • configure SCIM in Mobile Services. This would allow you to register with Mobile Services using your back-end credentials
  • configure no-auth in Mobile Services. While users still need to give their credentials for back-end access, they can register with Mobile Services without credentials at all

The rest depends on your back-end configuration. For example, if it requires Basic auth, configure your back-end connection accordingly and leave the user/password fields empty. When you supply those with your client requests, they will be forwarded to your back-end.

Edit: I misread the question and thought you were using "SAP Cloud Platform Mobile Service", the cloud equivalent of the SAP Mobile Platform. The answer basically remains the same, only the terminology changes (italic):

  • configure HTTP(s)-based Basic Authentication SSO in Mobile Platform. This would allow you to register with Mobile Platform using your back-end credentials.
  • configure no-auth in Mobile Platform. While users still need to give their credentials for back-end access, they can register with Mobile Platform without credentials at all

Either way, SCIM for Mobile Service is described in the documentation, and so is Basic authentication for Mobile Platform.