Topic
2 replies Latest Post - ‏2012-12-04T12:29:10Z by SystemAdmin
SystemAdmin
SystemAdmin
2327 Posts
ACCEPTED ANSWER

Pinned topic Authentication on Startup

‏2012-12-04T08:09:22Z |
Hi

I have an requirement which requires to invoke the HTTP Adapter procedure for authentication.

Authentication type is onstartupWhenever i start the application.

I am unable to implement Adapter based authentication for my requirement.

Can anybody suggest me how i can solve this issue.
  • IdanAdar
    IdanAdar
    741 Posts
    ACCEPTED ANSWER

    Re: Authentication on Startup

    ‏2012-12-04T08:13:22Z  in response to SystemAdmin
    From the Development FAQ:
    http://www.ibm.com/developerworks/forums/thread.jspa?threadID=440423

    Question:
    I am trying to develop adapter-based authentication using requireAuthentication=onStartup, but this does not work!

    Answer:
    Adapter-based authentication will not function with the onStartup setting.
    onStartup authentication means that your application has to first authenticate to be able to gain access to adapters in the first place. So, you're in a loop - you need to authenticate to be able to invoke adapters, but you need to be able to invoke adapters in order to authenticate.

    Therefore currently the only option to use adapter-based authentication is by using the onDemand setting.
    You can use WL.Client.login("your-realm-name") in your JavaScript to invoke authentication sequence on application start-up.

    Idan Adar
    QA Engineer
    IBM Worklight Mobile Platform
    • SystemAdmin
      SystemAdmin
      2327 Posts
      ACCEPTED ANSWER

      Re: Authentication on Startup

      ‏2012-12-04T12:29:10Z  in response to IdanAdar
      Hi,

      I fixed the issue.

      Thanks