How to implement OAUTH 2.0 in IBM Worklight 6.0

In my application, I implemented login module authentication, implementing security areas. But I’m thinking about implementing OAUTH2.0 authentication when the user is authenticated as soon as I receive the token and retry the verification than when I launch the application.

So, please, one of the instructors, which is a prerequisite for implementing this. Can I achieve this by creating my own authentication module? Any sample code in the manual will be really helpful.

+4
source share
2 answers

An article has been published that shows how to use OAuth using inappbrowser and Worklgiht using LinkedIn, found in the following location:

http://www.ibm.com/developerworks/library/mo-worklight-linkedin/

This article is a great example to get started with Worklight and OAuth. Let me know if you have any further questions.

+2
source

Take a look at this SO answer: fooobar.com/questions/1498911 / ...

Hybrid applications do not have a public URL that OAuth can redirect to, but there are some tricks you can do with a child browser plugin to “crack” them (see the first link). You can redirect the OAUTH provider to a dummy URL that the child browser can intercept and parse the token from the URL (there are even some security issues). OAuth2 becomes even more difficult when configuring not to put the token in the redirect URL and instead put it in the body or in the header. The child browser does not disclose this data, which means that capturing it requires another user-defined work of its own, if this is your only route.

+1
source

Source: https://habr.com/ru/post/1498909/


All Articles