Hi johan, As per the conversation I had with team/you, I will go ahead an implement REST services.
Thanks. On Wed, Jan 21, 2015 at 10:33 AM, Lasitha Wattaladeniya <lasit...@wso2.com> wrote: > Hi Johan, > > On Wed, Jan 21, 2015 at 1:18 AM, Johann Nallathamby <joh...@wso2.com> > wrote: > >> >> >> On Tue, Jan 20, 2015 at 10:02 PM, Lasitha Wattaladeniya < >> lasit...@wso2.com> wrote: >> >>> Hi All, >>> >>> I'm developing a TOTP authenticator as my training project. In that I >>> had a requirement to implement $Subject. The requirement is to access the >>> soap service through a AJAX call from a jsp. >>> >> >> What's the requirement to implement SOAP service ? why not REST ? Don't >> need to use SOAP services unnecessarily. >> > > I already have a SOAP service component to initiate the TOTP > authentication from jaggery layer. On the Dashboard/User_Profile UI, I have > put the option to enable TOTP authentication, that function needs a SOAP > service to Initiate TOTP. Since already there is a soap service component, > I put the GenerateTOTPToken service to that component as a soap service > too. > > >> >>> Currently what I'm doing is, Created a Stub component to access the soap >>> service and call that Stub from a Servlet inside >>> *authentication.endpoint* component. >>> >>> AJAX request is sent to an endpoint where it's mapped to a Servlet. >>> Servlet initiates the call to the Stub. >>> >> >> This means you are having your authenticator specific logic in >> authenticationendpoint which should not be the case. >> > > Noted, I have actually created a client class to call the stub. That > client class is in the authenticationendpoint. I'll discuss about this with > the team how to do it properly. > >> >>> Any comments about this approach ? Is there a better way of doing this ? >>> >> >> You should be able to just hit the regular /commonauth servlet using ajax >> and handle it in the authenticator like any other login response handling >> flow. It is no different I guess except the response from the authenticator >> will be a 200 OK instead of usual 302 Redirect. >> > > I'm using the ajax call only to generate the TOTP token. > > > > > The totp authentication process is handled through the commonauth servlet. > If you are suggesting I can do the token generation also through commonauth > servlet then i'm not clear about it. > > Thanks. > > > >>> >>> >>> -- >>> Lasitha Wattaladeniya >>> Software Engineer >>> WSO2, Inc. | http://wso2.com >>> lean. enterprise. middleware >>> >>> Mobile : +94719397528 >>> Blog : techreadme.blogspot.com >>> >> >> >> >> -- >> Thanks & Regards, >> >> *Johann Dilantha Nallathamby* >> Associate Technical Lead & Product Lead of WSO2 Identity Server >> Integration Technologies Team >> WSO2, Inc. >> lean.enterprise.middleware >> >> Mobile - *+94777776950* >> Blog - *http://nallaa.wordpress.com <http://nallaa.wordpress.com>* >> > > > > -- > Lasitha Wattaladeniya > Software Engineer > WSO2, Inc. | http://wso2.com > lean. enterprise. middleware > > Mobile : +94719397528 > Blog : techreadme.blogspot.com > -- Lasitha Wattaladeniya Software Engineer WSO2, Inc. | http://wso2.com lean. enterprise. middleware Mobile : +94719397528 Blog : techreadme.blogspot.com
_______________________________________________ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev