Creating Custom Login Portlet

Hi,

I’ve my portal authentication method in a java library.

Please take a look at the following article:

https://advantage.webMethods.com/advantage?w=0&targChanId=-536884334&oid=1614272879

Thanks Alex,

My webMethods Administrator Guide 7.0

Even i m facing problem while creating a customised login page.

I have followed this procedure

First, I added a login page rule ,in that i have added the login portlet,which is already present by default at the location Folder>Start in the MyWebmethods Server. This login page rule will be invoked on the url provided in the condition which is “http://ibmcc-srv1:18565/genzyme.basic.login

Then I created a shell, which has customized logo in the header. This shell should be rendered when specific URL is invoked , which again is “http://ibmcc-srv1:18565/genzyme.basic.login

The Login page is gettting rendered , but the SHELL is not getting triggered.

I would like to know whether this is the right way to customise the login page

You are probably getting the same “Guest” shell which is triggered for any anonymous user. The “Guest” shell sits high in the order list of shell rules and likely executes prior to your rule.

You can try to move your shell rule before “Guest” shell rule.

Alex

ya I am getting the Guest shell. But placing the Shell rule before the Guest Shell rule is also not helping.

It worked for me like this. Can you enable debug logging for Rules category in MWS (this is done in the Administration → Analysis → Logging Configuration).

This should output results of all rules evaluation and firing, so you can check what rule is being matched

I’m trying to accomplish something similar, and while I think I understand all the points that have been made previously what I don’t know is…

if there is a way to modify or make my own version of the “login portlet” (wm_login)??

Basically, all I need to do is add a field to go along with un/pw, let’s call it DOMAIN.

It needs to be a drop down populated by a WS call.

And, of course, it needs to be wired to the follow-on portlet.

I can, sort of, accomplish this by submitting a form with two control parameters (children of a command button) called username and password, but then what I have is not a real “login portlet” in the eyes of WMS.

For instance it does not have the “Login Target” property the real “login portlet” has.

Any help is greatly appreciated,

Lucas.

There is nothing fancy in the wm_login portlet. All it barely does is submits username=‘username’ and password=‘password’ as part of the HTML . The action of the form is the target of the login. If you specify a valid portal resource like /meta/default/folder/000002345 this is the page where user would land.

Now wm_login portlet as you can see is just like a UI, but it does not handle the actual authentication. Authentication is handled by so called auth schemes. In order to process your domain you need to create a new custom auth scheme (attached as sample) as a portlet. You can explore its source code to see handler implementation which accepts and validates username and password

One more item to be aware of, you need to ensure that when using your login portlet with domain it invokes your auth scheme. THe problem is that all auth schemes available in the MWS are invoked in the unspecified order and default ‘forms’ auth scheme will likely be invoked before yours and if you use same ‘username’ and ‘password’ fields it will be handled by default ‘forms’ scheme without giving a chance to your implementation. To avoid this you can simply use some different field names to pass username and password so default ‘forms’ won’t be able to handle them and it will be delegated to your custom auth scheme
CustomLogin.zip (15 KB)
wp_custauth.zip (56.1 KB)

Thanks a million, Alex. This was helpful.

To be clear, my “DOMAIN” doesn’t need to be authenticated so that makes thing simpler.

My remaining issues is this: I need to have an IS populated drop down within the login form. I tried to add this drop down to the CAF form you provided after the HTML include, but the value (bound to a preference) would not get assigned, I guess because it lived outside the form that was being submitted. Not sure. Any ideas?

Alternatively, is there a way to recreate the login form in CAF, as opposed to in an HTML include?

Endless thanks,

Lucas.

Hi,

I have conceptually similar requirements.
I want to add the Language selection drop down at the default webMethods Login page and the I want to get selected language value and pass it to different portlet applications inside webMethods. Can you please help me on this.

I want to know:

  1. How to change in default login page and how to deply those changes on webMethods server.
  2. How to access login page selected language to the portlet pages.

Please provide any solution on this.

Thanks,
Rupesh chakole

We are trying to authenticate a user using third party webservice instead of directory service. I am trying to compile wm_custauth portlet. I have add wm-directory and wm-directory-components jar also in build path. Still having a issue of compile. it is looking for com.webMethods.sc.LocalizedException class which I didn’t find in the above given jar. can anyone please let me know where we can find that jar.

I was able to compile wm_custauth project.