Problem in getting Portal Mapped user and password in Web Dynpro iView

I am developing a webdynpro iview.My app need to read mapped user and password form a system in Portal runtime.
I used the following codes in my Web Dynpro java program:
     IWDClientUser user = WDClientUser.getCurrentUser();
     IUser iuser = user.getSAPUser();
     IUserMappingService iums = (IUserMappingService)WDPortalUtils.getServiceReference(IUserMappingService.KEY );
//     IUserMappingService iums = (IUserMappingService)
//     PortalRuntime.getRuntimeResources().getService(IUserMappingService.KEY);
     IUserMappingData iumd = iums.getMappingData (systemalias, iuser);
     Map map = new HashMap ();
     iumd.enrich(map);
     String userid = (String)map.get( "user" );
     String pwd = (String)map.get ("mappedpassword");
I've add a sharing references in project properties,the value is "PORTAL:sap.com/com.sapportals.portal.prt.service.usermapping.IUserMappingService"
But when I run the iview on my Portal, it goes wrong, the message is:
com.sap.engine.services.deploy.container.DeploymentException: Clusterwide exception: Failed to prepare application ''local/HomePage'' for startup. Reason= Clusterwide exception: Failed to start dependent library ''com.sapportals.portal.prt.service.usermapping.IUserMappingService'' of application ''local/HomePage''. Status of dependent component: STATUS_MISSING. Hint: Is the component deployed correctly on the engine?
    at com.sap.engine.services.webdynpro.WebDynproContainer.prepareStart(WebDynproContainer.java:1490)
    at com.sap.engine.services.deploy.server.application.StartTransaction.prepareCommon(StartTransaction.java:231)
    at com.sap.engine.services.deploy.server.application.StartTransaction.prepareLocal(StartTransaction.java:184)
    at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhasesLocal(ApplicationTransaction.java:365)
    at com.sap.engine.services.deploy.server.application.ParallelAdapter.runInTheSameThread(ParallelAdapter.java:117)
Anybody can help me?And are there anyother methods can get mapped user and password of Portal systems in Web Dynpro JAVA.

Hi Wayne,
      Did you added com.sap.security.api.jar to your webdynpro project. if not follow this steps.
1. Right-click the project in Eclipse or SAP NetWeaver Developer Studio.
2. Select Properties.
3. Choose Java build path -> Libraries -> Add Variable -> Select variable WD_RUNTIME -> Extend -> com.sap.security -> lib -> com.sap.security.api.jar.
I hope this should solve your problem.
Regards, Suresh KB

Similar Messages

  • How to get the portal user id into the web dynpro iview at runtime?

    Hi,
    Can any one let me know, How to display portal id and as well as backend SAP user id into Web Dynpro iview at runtime. I am using Adaptive RFC model in my web dynpro application.
    Raj.

    Raj:  check this thread. I think that will help you.
    Can i get Portal User's details in webdynpro??
    I had the same requirement and its works whit this solution.
    regards.

  • Portal theme not picked for SAP Web Dynpro Iview

    Hi,
    We have used light framework page for our portal and all the iviews display the content within the iviews in the same set of colors (blue for buttons). However, for a WD java content, I have created an SAP Web Dynpro iView and the contents displayed here appear in the SAP colors without picking those set for the portal.
    The same application parameters display the portal colors when we use the Web Dynpro Proxy iview.
    Any idea how I can make the SAP Web Dynpro iView appear like the other portal iviews?
    Note: The stylesheet property for the iview is already entered (ur), and I have also set the 'Supply Portal stylesheet' property to 'Yes'.
    Please provide your inputs.
    Thanks,
    Vinay

    Hi ,
    In ABAP Webdynpro for similar problem we used WDFORCEEXTERNAL Sheet property of WDA.
    The Web Dynpro framework automatically compares the versions of the portal and Web Dynpro
    for ABAP style sheets. If the Web Dynpro for ABAP has a newer version, the WDA style sheet is used. This avoids unattractive rendering and JavaScript errors.You can deactivate this behavior again using the WDFORCEEXTERNALSTYLESHEET application parameter of WDA.See also SAP Notes 1033496 .
    If you use the stylesheet of the portal to display the application, the rendering may not appear correctly and Javascript errors can occur(If portal style sheet is lower than WD).
    Though Iam not familiar with WD java , the property force portal style sheet in WD java application should be enough to make WD accept portal theme.
    Regards
    Karthiheyan M

  • How to get Portal Login User and Its Related BP in CRM?

    Hi,
    An ABAP Webdynpro program is called in CRM from Portal user by a portal link. How to get the user ID and its related BP in CRM? Thanks!
    The portal is integrated with ECC, and all users and BPs are maintained in ECC then replicated to CRM.
    Best regards,
    Hao

    Hi,
    Try the below code
    IUserFactory userfact=UMFactory.getUserFactory();
    IUser user=userfact.getUserByUniqueName(request.getUser().getUserId());
    String usrid=user.getUniqueName();
    And also you can get the groups assigned to user by using the below code
    Iterator groups = user.getParentGroups(true);
    while (groups.hasNext()) {
         String groupstr = (String) groups.next();
         IGroup g = UMFactory.getGroupFactory().getGroup(groupstr);
         response.write("Group name "g.getUniqueName()"<br>");
    Regards
    Suresh

  • Problem in getting parameter value from selection screen in web dynpro abap

    Hi,
    I am facing problem in getting parameter value from selection screen.
    Please find my code below:
    DATA LT_PAR_ITEM TYPE IF_WD_SELECT_OPTIONS=>TT_SELECTION_SCREEN_ITEM.
    FIELD-SYMBOLS:<FS_PAR_ITEM> LIKE LINE OF LT_PAR_ITEM,
                                 <FS_OBJ_USAGE>    TYPE REF TO data.
      WD_THIS->M_HANDLER->GET_PARAMETER_FIELDS( IMPORTING ET_FIELDS = LT_PAR_ITEM ).
      LOOP AT LT_PAR_ITEM ASSIGNING <FS_PAR_ITEM>.
        CASE <FS_PAR_ITEM>-M_ID.
          WHEN `OBJ_USAGE`.
             ASSIGN <FS_PAR_ITEM>-M_VALUE->* TO <FS_OBJ_USAGE>.      
    [ Here, sy-subrc is 4,  <FS_OBJ_USAGE> is not assigning.]
        ENDCASE.
      ENDLOOP. 
    So, can any one solve this problem.
    Thanks in advance,
    Radhika

    Hi Radhika,
    Try using GET_RANGE_TABLE_OF_SEL_FIELD...
    Please Refer below code..
       DATA: NODE_FLIGHTS TYPE REF TO IF_WD_CONTEXT_NODE.
      DATA: RT_CARRID TYPE REF TO DATA.
      DATA: ISFLIGHT TYPE TABLE OF SFLIGHT.
      DATA: WSFLIGHT TYPE SFLIGHT.
      FIELD-SYMBOLS: <FS_CARRID> TYPE TABLE.
    Retrieve the data from the select option
      RT_CARRID = WD_THIS->M_HANDLER->GET_RANGE_TABLE_OF_SEL_FIELD( I_ID = 'S_CARR_ID' ).
    Assign it to a field symbol
      ASSIGN RT_CARRID->* TO <FS_CARRID>.
      CLEAR ISFLIGHT. REFRESH ISFLIGHT.
      SELECT * INTO CORRESPONDING FIELDS OF TABLE ISFLIGHT FROM SFLIGHT
                           WHERE CARRID IN <FS_CARRID>.
      NODE_FLIGHTS = WD_CONTEXT->GET_CHILD_NODE( NAME = `FLIGHTS` ).
      NODE_FLIGHTS->BIND_ELEMENTS( ISFLIGHT ).
    Thanks,
    Regards,
    Kiran

  • HT1600 I have an Apple TV 2nd Gen, iPad 2 and can't get the icon to appear when i swipe from left to right. What am I missing? I am able to get the 'Home sharing' 'user and password on my Mac.

    I have an Apple TV 2nd Gen, iPad 2 and can't get the icon to appear when i swipe from left to right. What am I missing?
    I am able to get the 'Home sharing' 'user and password on my Mac.
    Also using IPad 2 I am able to get the ITunes to accept the user name and same password as the Mac.
    However, the only way I can see the 'Home sharing; icon is in Music on the Ipad. When I tap on the Icon it asks for a password.
    When I give the same password, it is rejected.
    Help!!!!
    Jaxxdiggs

    Personally I think the iOS devices are poor at reconnecting  - Airplay establishes that a link is available but when the iPhone/iPad has been away from the house and rejoins the network i think AppleTV already thinks it's connected with a different IP address and fails to recognise it has joined the network again with new credentials.
    Something along those lines anyway.
    I find that a combination of restarting AppleTV, router and iOS device tends to fix it, but not for everyone.
    AC

  • Downloaded music apps o.k.  Says login failed when I put in user and password. No trouble when getting any other apps.

    Downloaded music apps o.k.  Says login failed when I put in user and password. No trouble when getting any other apps.

    Sounds like you may have deleted something you shouldn't have. Boot to an OS X DVD or a bootable backup, and using Disk Utility, do a repair disk, and while there repair permissions. Disconnect any peripherals, and reboot. If you get the same startup behavior, do a safe boot, by holding the shift key down when booting. If that works, try a normal boot. If neither step helps, you may need to relaod your operating system.

  • Linking to an OBIEE report without showing the user and password

    Hi!
    we are trying to access to an obiee report from an external portal (coded with php).
    The idea is that the user clicks on a link an gets the report in pdf format. For that purpose we are using this url:
    http://ttivobiee01:7001/analytics/saw.dll?Go&Path=/shared/Prueba/ogp_obi&Action=Print&P0=1&P1=eq&P2="Criteria"."Key"&P3=1402&NQuser=user&NQPassword=pass&format=pdf
    But this url is expossing OBIEE's user and password.
    In order to avoid this security issue we tried to do an wget of the url but it doesn't return the report. Instead we get an html, which seams to download the report chunk by chunk (using javaScript).
    The question is, is there any way that we could let our portal ussers access to an obbie report without expossing the user and password?
    I have been looking into oracle forums and have found this: OBIEE Go URL with password protected
    but we couldn't use this aproach due to security issues.
    Thanks!
    Nuria

    Hi!
    We have finally done this (and it works!)
    <?php
    $urlInforme='http://obi:7001/analytics/saw.dll?Go&Path=/shared/Prueba/ogp_obi&Action=Print&P0=1&P1=eq&P2="Criterios"."Clave oficial"&P3=1402&NQuser=user&NQPassword=pass&format=pdf';
    $ch = curl_init($urlInforme);
    $ckfile = tempnam ("./", "CURLCOOKIE");
    $ch = curl_init ($urlInforme);
    curl_setopt ($ch, CURLOPT_COOKIEJAR, $ckfile);
    curl_setopt ($ch, CURLOPT_RETURNTRANSFER, true);
    $output = curl_exec ($ch);
    $ch = curl_init ($urlInforme);
    curl_setopt ($ch, CURLOPT_COOKIEFILE, $ckfile);
    curl_setopt ($ch, CURLOPT_RETURNTRANSFER, true);
    $fp = fopen("salida.pdf", "w");
    curl_setopt($ch, CURLOPT_FILE, $fp);
    $output = curl_exec ($ch);
    curl_close($ch);
    fclose($fp);

  • External Web Service - User and password in HTTP header

    Hi!
    How is it possible to add user and password in the HTTP header in a external web service call? 
    I have created a "Portal Service from WSDL file - Client side" with the wizard in SAP Developer Studio.  I following the Java Development Guide - Web Service Security, and use the <i>secured service connection</i>.  I have also created a new <i>System Landscape</i>, but should the new system be based on HTTP, my own PAR or what?
    How can I check that the user and password is added to the HTTP header or the SOAP envelope? Do I have to scan http traffic with a proxy as Paros or can I find the request sent from SAP EP in the logs?
    Cheers
    Asle

    Hello All,
    I have been struggling a bit while putting a reasonable security framework on a jax-rpc style web service. I'm using JWSDP1.2 to set up the webservice. I've tried to outline my problem below. Please correct me where I'm wrong.
    I've been through the Sun's WS tutorials, but they are not really clear on security. However, from them I surmised that there are two decent authentication techniques. HTTP Basic and mutual authentication (MA) . Both have their drawbacks though. HTTP Basic suffers from poor encryption while MA is a bit difficult to set up on both client and server sides. Another problem with MA is that there is no central repository for users/passwords.
    OK, what I would really like to do is use my own user database to verify users/passwords i.e. use a HTTP Basic like authentication (but at application level) but run it over SSL for encryption. It seems simple, but is it possible?
    Also, I have noted that when I use HTTP Basic on the service side, and use a java client, then setting username/password has no effect. In other words, I can always access the web-service, even with wrong username/password.
    Sorry for the long post. Hope someone can help. Thanks.

  • I can not login into the Folio Builder, I introduce my user and password and keeps logging in...

    I've introduced my user and password, the Folio Builder tries to login but gets stuck logging in with the wheel spinning.
    I've tried to uninstall and install Indesign CS6 again several times but nothing different happened...
    Could you help me please?
    Thanks.

    Clear the cache and the cookies from sites that cause problems.
    "Clear the Cache":
    *Tools > Options > Advanced > Network > Cached Web Content: "Clear Now"
    "Remove Cookies" from sites causing problems:
    *Tools > Options > Privacy > Cookies: "Show Cookies"
    You can check if there are entries in the password manager with an empty user name.
    Make sure that you haven't saved multiple (uppercase, lowercase) versions of that name and password.
    Remove saved Password(s):
    * Tools > Options > Security: Passwords: "Saved Passwords" > "Show Passwords"
    If you click "Never" then you create an exception that needs to be removed.

  • Facebook login does not add user and password to the account

    Hi
    PROBLEM
    Facebook login button does not create user and password for login.
    We wish we could ONLY use facebook login button to allow users the account creation on our campus.
    So we disabled the user creation webform.
    And only out facebook login buttons that students can only login to our campus using their fb account in the hope that they dont share it (hopefuly)
    AND
    This is a problem BECAUSE if I publish events and capture leads ALL those users have problems creating their user account latter.
    CASE IS
    1.- A person comes to my website and leaves a comment. This creates a register with their email and name.
    2.- Days later this same user comes back and clicks a facebook user login/ account creatio.
    2.1 The page now shows that user name as it comes from Facebook. BUT NO USER AND PASSWORD information added to that person's register in the CRM.
    So
    If some one leaves a comment, register to our mailing list FIRST
    and SECOND tries to create his account afterward. IT DOESNT WORK
    Any ideas?
    Thank you so much in advance.
    P.S.
    This is the web page. If you 1) Leave first a comment and 2) click on fb login/create account button the profile renders unusable. I have to delete it so you can create your user
    http://www.zuiliuniversity.com/nivel-2-curso-especializado-proyecto-de-marketing-digital

    if you are only using 2 snmp commands  to let the switch pull the config from your tftp server, than there are some commands missing ...
    have a look here to get a documentation about this process:
    https://supportforums.cisco.com/docs/DOC-1860
    http://www.cisco.com/en/US/tech/tk648/tk362/technologies_configuration_example09186a0080094aa6.shtml

  • I tried to upgrade the ios on the phone and I was asked for my icloud user and password. I don't remember these exactly and I tried several times with different options but unsuccessfully. I also forget my email used to configurate the phone.

    How i said on the question. I tried to upgrade the ios on the phone and I was asked for my icloud user and password. I don’t remember these exactly and I tried several times with different options but unsuccessfully. I also forget my email used to configurate the phone. I have the phone box and the bill. I sent you an email with my problem and attachments with the box informations, the bill and the reset request. What to do? You said to me:
    Your request comes from an unrecognized email domain. Apple accepts email requests only from email domains for Apple-authorized carriers.
    Please re-submit your request using your official carrier domain.
    but this email is authorized, what to do??
                                                                                                              respectfully, Beba

    If you have forgotten then these links are the only way to resolve
    http://www.apple.com/support/appleid/
    As long as you have owned the iPhone from new and your Apple id is the one used to activate when new
    OR have you recently purchased the iPhone secondhand ?

  • Link to folder with user and password

    Hi all!
    From my action I want to redirect to a file in order to download it but the problem is that this file is in a web folder with user/password
    How can I redirect to it to downlad it directly without introducing user and password manually by the customer?
    Thanks!
    T

    Do you understand where this user/password restriction comes from? It look like just a HTTP based authentication. A Servlet can access the local file system directly without issueing a new HTTP request for that. Or is that file located at another server?

  • URL in sender SOAP channel with user and password

    Hi Expert,
    I have developed SOAP to proxy scenario.The serder WSDL is generated by using sender agreement. In the WSDL we are using default below URL.
    http://host:port/XISOAPAdapter/MessageServlet?channel=party:service:channel
    But the client requirement is that he want SAP user and password also in above url.
    Is this possible in sender SOAP channel?
    Any body can please help me for above issue?
    Thanks.
    Edited by: darshana-PI on Feb 1, 2012 5:26 PM

    Thanks prateek,
    we have used HTTP plain adapter for this and used below link to call that interface in PI. And its working.
    http://server:port/sap/xi/adapter_plain?service=<xxx>&namespace=<xxx>&interface=<xxx>&sap-user=<xxx>&sap-password=<xxx>&qos=BE
    I can understand the security related problem, but that was the requirement for end application.
    Thanks,
    Darshana.

  • I have forgotten my itunes user and password details how to do I find them again?

    I have forgotten my itunes user and password details, how do I find them again?

    Have you got any of its downloads in your computer's iTunes library : http://support.apple.com/kb/HT1920
    You can also try this page and see if you can get the id from it and/or reset its password : http://iforgot.apple.com

Maybe you are looking for