cancel
Showing results for 
Search instead for 
Did you mean: 

How to use the username & passwd entered to login to d MI client in applns

Former Member
0 Kudos
57

Hello Everyone,

We enter the username and synchronization password to logon to the MI client.

In any application say a generic sync appln, if we require these login details of the user, then is there any way in which we can extract them without asking the user to re-enter it in the application.

Any form of help is most welcome.

Thanks & Regards,

Saurabh.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Saurabh

Please add the parameter <i><b>MobileEngine.Security.SynchronizationPasswordHandlingOption=local</b></i> in the MobileEngine.config file present in the settings folder of MI Client. Once this paramerter is added, restart the client. Please make sure that the local logon password for MI and also the sync password are the same. This will ensure that the sync password can be made use by the application as well even without having to enter it again. You can refer to http://help.sap.com/saphelp_nw04/helpdata/en/61/3a8f4040d1ce62e10000000a155106/frameset.htm for more details about this parameter. Hope this helps

Best Regards

Sivakumar

Former Member
0 Kudos

Hi Sivakumar,

Thank you for your reply.

Presently this parameter is set as <b>once</b> in my MobileEngine.config file.

In my generic sync appln right now i write the statement :-

<i>sm.setSyncPasswordOfCurrentUser(syncPassword);</i>

where sm is an instance of SyncManager.

That is i explicitly make the user enter the synchronisation password on the first screen of my application and then set this password in the SyncManager instance before synchronizing with the backend.

<i> sm.synchronizeWithBackend();</i>

So is it that if i set

<b>MobileEngine.Security.SynchronizationPasswordHandlingOption=local</b>

i will not have to explicity set the Sync password in the SyncManager instance and directly synchronise with the backend.

Thanks & Regards,

Saurabh.

Former Member
0 Kudos

Hi Saurabh

Yes you are right in your understanding. This should work even without asking the user to enter his password. The MI Client framework will take care of this. Do let me know if face any issues.

Best Regards

Sivakumar

Former Member
0 Kudos

Hi Sivakumar,

Thanks a lot. I did that. Atleast it does not ask me to re-enter the sync passwd.

However to see its use in an appln it will still take me some time as i am still in the middle of preparing one appln.

I will surely let u know wat happens then.

Btw is there any other way to do this. I just have the feeling that in a real time scenario we might not always have a control over the fact that all the users of the appln set these both passwds same. They might assign different strings to the two passwords.

So could there be any way by which we could extract the Sync passswd that has been entered during login and make use of it in the appln?

Thanks & Regards,

Saurabh.

Former Member
0 Kudos

hi saurabh,

>So could there be any way by which we could extract the Sync passswd that

>has been entered during login and make use of it in the appln?

the only persisted password is the local password - the one used to logon into the

MI client. the sync password on the other hand is not persisted. if the local option

is used (as suggested by Sivakumar), the framework will make use of the local

password. so your question implies a little misunderstanding. <i>sync password is

NOT entered during logon</i>.

there's no API to retrieve the sync password. it's lifetime is only during the sync.

(to be more specific - when the connection to the MI server is still valid). there's

no API as well to retrieve the local password and never will it be made available

for security reasons. can you be more specific when you say <i>"make use of it in

the appln?"</i>? what will you do with the password if you have it?

regards

jo

Former Member
0 Kudos

Hi Jo,

Thanks for the reply. The settings (MobileEngine.Security.SyncPasswordFieldAtLogon=true) in my Mobile client is such that when i open it i am asked the User, Logon Password and the Synchronization password(which is not mandatory). So if I dont even enter it during logon i am asked to enter it when i hit the sync button on the client.

But if i have entered it during logon and then hit the sync button on the client, that time i am not asked to re-enter my sync passwd and the client syncs with the b/e. Which means that the sync passwd i had entered during logon is definitely stored somewhere.

What i mean by using the sync passwd in applications is this :-

-> In a generic sync appln before synchronising with the b/e we need to give the sync passwd to the SyncManager. How do we get this sync password from the user of the appln?

-> We can either ask him to enter it as in input to a jsp OR else since he has already entered it during logon we need not ask him to enter it again and retrieve it via some API.

Is this possible.

Thanks & Regards,

Saurabh.

Message was edited by:

Saurabh Agarwal

Answers (0)