cancel
Showing results for 
Search instead for 
Did you mean: 

Authentication at iview level??

former_member1191927
Participant
0 Kudos

Hi all,

In one of my application which sends out mails,I am passing the link of a web dynpro applicaiton along with it. When the user clicks on that link, it directly opens the web dynpro app, but it is not asking for authentication (user id and password).

Requirement is that when the user clicks on the link, it should show the portal initial page, user gives user id and password and then application should open.

Any info on how to do this would be of great help.

Thanks,

Narahari

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

WebDynpro application has applciation property called sap.authentication .Setting this parameter to true wil yield the required behaviour.

Double Click on the application ,it will open up in the right side.. click on the application properties.. her you will find sap.authentication in a pre-defined property.

Regards

Bharathwaj

former_member1191927
Participant
0 Kudos

Hi Bhardwaj,

That solved my problem. Thanks.

Regards,

Narahari

former_member1191927
Participant
0 Kudos

Hi Bharadwaj,

Thank you for your earlier reply.

When I use the option that you have suggested, it asks for the authentication of the WAS server. But the actual requirment is that the authentication should be done at the portal level and the iview should open with the menus, mast head and the detail level navigation bar etc. in place.

For example, when we click on the link that we have in the update mails that we recieve when some one updates the post that we are watching on SDN, it takes us to that post along with the Mast head and the detail level navigation etc. open. Simillar functionality is needed.

Please help me in doing this.

Regards,

Narahari

Former Member
0 Kudos

I am not sure, I understand your query correctly or not. Let me try.

To include any web dynpro application in portal, You have to create iview in portal by specifying Web Application Server and web dynpro application. (your portal and Web Dynpro application may run on different Web Application Servers.)

When you receive a e-mail notification, probably you are getting the direct URL to Web Dynpro application. That's why you don't see any masthead etc. like what you see in portal. Because its not a portal! If u want to see portal masthead etc with your web dynpro program, give the link to web dynpro iview in the portal.

former_member1191927
Participant
0 Kudos

Hi Kranti,

I tried your suggetion and it helped me.

I used the following link and it takes me to the application:-

http://<server>:57100/irj/portal?NavigationTarget=ROLES://portal_content/NGL_TEST/com.xyz.iViews/iv_...

But, I also need to pass some application parameters dynamically with this link to the web dynpro application. I tried the following way to pass parameters, but it did not work :-

http://<server>:57100/irj/portal?NavigationTarget=ROLES://portal_content/NGL_TEST/com.xyz.iViews/iv_...

http://bp1tulap209:57100/irj/portal?NavigationTarget=ROLES://portal_content/NGL_TEST/com.xyz.iViews/...

But if I pass the same parameters in the Application Parameters attribute of the corresponding iview in the portal, it opens the iview like I want (with the mast head etc., and also asks for portal authorization).

Please let me know how I can pass parameters if I call the web dynpro iview directly using the NavigationTarget as mentioned above.

Regards,

Narahari<b></b><b></b>

Former Member
0 Kudos

I think you need to pass the parameters to Web Dynpro Application.

Pls look at to get an idea on passing the parameters to Web Dynpro application.

1. Add parameters to startup plug: goto

Web Dynpro Components-> <Your component name> -> Interface views -> <Your interface view name> Double click this.

Select the tab "Plugs". There you would see one plug with "Startup" Checked.

Select that plug and add parameters below.

2. Select the tab "properties" and "add" Required controllers. Add your Component(Custom) Controller.

(To access the component context to store the data)

3. Select "implementation" tab, goto the default plug event handler and save the passed values in the component context.

You may want to add something like this in event handler

wdThis.wdGet<ComponentName>Controller().wdGetContext().currentContextElement().setParam1(<argument_recieved>);

As you saved the the received parameters in the component context, It is available to all the views.

Now you can do what ever u want!

Pls update the result here. Thanks.

former_member1191927
Participant
0 Kudos

Hi Kranthi,

I have used the following method in my application to read the paramters :-

WDWebContextAdapter.getWebContextAdapter().getRequestParameter(<param name>);

This works perfectly fine when I pass parameters in the following way to the link :-

http://bp1tulap209:57100/webdynpro/dispatcher/sap.com/<project_name>/<AppName>?mail=true&contract=46...

But the only issue is that it asks for authentication at WAS level. And when I try to use the way you suggested, I am not sure how to pass the parameters (rather what is the exact delimter to sepeate differnt parameters and the string "NavigationTarget=<pcd path>".

I did not understand what exactly is the differnce between the way I am currently reading and passing parameters and the way that you are suggesting.

Could you please clarify.

Regards,

Narahari

Former Member
0 Kudos

<a href="https://www.sdn.sap.comhttp://www.sdn.sap.comhttp://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/javadocs/nw04/sp12/web%20dynpro%">WDWebContextAdapter</a> seems to be Web Dynpro version of IPortalComponentRequest object.

What is the result when u try this:

http://<server>:57100/irj/portal?NavigationTarget=ROLES://portal_content/NGL_TEST/com.xyz.iViews/iv_...

former_member1191927
Participant
0 Kudos

It asks for user name and password, but wont take me to the desired iview. (i.e., takes me to the initial page - looks as if we have logged in normally to the portal).

One more thing which I have noticed is, if I hard code these parameters in the application parameters attribute of the iview and just call the application using NavigationTarget, it opens the iview perfectly

Regards,

NARahari

Message was edited by: Narahari Vedula

Former Member
0 Kudos

Hi,

I guess when you use the portal navigation for accessing the iview, the parameters you are manually adding that will be available in the portal request object.. But i dont think wdWebContextAdapter will be able to do get those values.

Can you share with us the reasons for..

Why do you want to manually add the values in link ?

Why you are giving the webdynpro iview link instead of asking them to log in to the portal directly..

Regards

Bharathwaj

Message was edited by: Bharathwaj R

former_member1191927
Participant
0 Kudos

Hi Bharadwaj,

The reason for creating such link is that, I will be sending this link as part of E-mails which will be sent by another application (which is in R/3). This link, along with the parameters, will be dynamically generated in R/3 and is included as part of the mail.

And when the user clicks on the link in the e-mail, it should take him to a specific application(after authenticating at portal level) which should also include the Mast head and detail level navigation bar etc.

So I need to know how to generate this link with parameters.

Hope I have made it clear.

Regards,

Narahari

Former Member
0 Kudos

Hi ,

The only workaround i can think of now is..

1.Create aAbstract portal component..

2.Create a iview out of the par file

3.IN R/3 generate link for this APC iview and add parameters

4.IN side the APC, access teh parameters using the request object.

5.Append them to the webdynpro applciation lik as url parameters..

after constructing ths url redirect to this url..

Sounds like a bad idea..Give the user the portal link,let him log on and see the page..which holds the webdynpro iview...

If i find any better solutions will definitely post it..

Regards

Bharathwaj

former_member1191927
Participant
0 Kudos

Hi Bharadwaj,

Sorry for a late reply.

Could you please elaborate on point "5" of your suggetion? Also please tell me how to redirect. I want to try this.

Regards,

Narahari

Former Member
0 Kudos

HI ,

Inside the APC..


public void doContent(IPortalComponentRequest request, IPortalComponentResponse response)
    {
    	
        String _val1 = request.getParameter("val1");
	String _val2 = request.getParameter("val2");
		
	request.redirect("WebDYnpro application URL?val1="+_val1+"&val2="+_val2);
}
    	

Try this..

Regards

Bharathwaj

Former Member
0 Kudos

Hi Narahari,

in the url

http://bp1tulap209:57100/irj/portal?NavigationTarget=ROLES://portal_content/NGL_TEST/com.xyz.iViews/...

try replace ApplicationParameters with ApplicationParameter

it should work.

Regards,

Paulo Ruivo

former_member1191927
Participant
0 Kudos

Hi Paulo,

I tried the option that you have suggested.

When I give this link, it asks for authentication of the portal and takes me to the initial page of the portal and not to the specific iview that I want to show.

But, after logging in, if I give the same link in the portal, it works perfectly fine (it opens the iview with the application running perfectly fine - along with reading the parameters).

Is there any way to take it directly to the iview??

I found one property in the iview property called "Authentication Scheme". Will this help me??

Regards,

Narahari

Former Member
0 Kudos

Hi,

I'm doing the same (but with a bsp iview), and its working. I'm force to do the login, but after the logon it opens the iview.

In my iview the "Authentication Scheme" is "default".

The iview should be in a role assigned to the user, but that should be ok, if not you would have an error.

Maybe is some configuration in portal logon, to allow the portal to save the initial request before the login.

I can check in my portal.

Regards,

Paulo Ruivo

Former Member
0 Kudos

One more thing, this host: http://bp1tulap209

is realy your host or is it a dns alias?

former_member1191927
Participant
0 Kudos

Hi Paulo,

It is my host name.

Regards,

Narahari