Oracle9iAS Portal Developer Kit
Installing the Basic Authentication Portlets Using Oracle Metalink


Using the Basic Authentication feature in PDK-URL Services, you can portletize the contents of any 3rd party application which is authenticated using the BASIC Authentication method. It is very similar to creating a standard External  Application portlet with less details and fewer steps to follow.  This article describes how to quickly and easily setup the Basic Authentication Portlets using Oracle Metalink.

REQUIREMENTS

  1. Oracle Metalink Account.  Register for/Login to Metalink.

  2. Oracle 9iAS Portal 3.0.9.8.0 or later.  Beginning with version 3.0.9.8.0, Oracle9iAS Portal support Basic Authentication.

  3. PDK-URL Services 3.0.9.0.8 or later. 

ASSUMPTIONS

  1. You have already successfully installed the PDK-URL Services Framework and Samples.

  2. You have also reviewed PDK-URL Services Basic Authentication Readme.


SETUP

Note: This section will update zone.properties.  We recommend that you backup this file before making the following changes. 

Configuring zone.properties

  1. Stop the Oracle9iAS Portal Http Server.

  2. Open the zone.properties file.

  3. Under the Servlet Aliases section, add the alias that points to the Provider Adapter:

         servlet.basicauth.code=oracle.portal.provider.v1.http.HttpProvider

    Under the Aliased Servlet Init Parameters section, add the initial arguments needed by the URL Services samples.  Make sure to modify the directory to point to the correct location of the provider.xml file.

         servlet.basicauth.initArgs=provider_root=D:\urlservices\providers\basic,sessiontimeout=1800000, debuglevel=1

    Note:  the sessiontimeout must match the session timeout setting located in the zone.properties of your Apache listener.  Both settings are specified in milliseconds.  Please review the release notes of the JPDK download for more information on these arguments.

  1. Save and close the zone.properties file.

Updating the provider.xml

  1. Go to the location of the provider.xml for URL Services.  It is located in the D:\urlservices\providers\basic directory.  The provider.xml file is setup to use a proxy server.  Note:  You will either need to alter these tags or remove them.  The portlets access URLs over the internet, so if you may or may not need a proxy server to access external URLs.
    1. If you do not need to use a proxy server, remove the following tags.

      <proxyInfo class="oracle.portal.provider.v1.http.ProxyInformation">

      <httpProxyHost>www-proxy.us.oracle.com</httpProxyHost>

      <httpProxyPort>80</httpProxyPort>

      </proxyInfo>

       

      <httpsProxyInfo class="oracle.portal.provider.v1.http.ProxyInformation">

      <httpsProxyHost>www-proxy.us.oracle.com</httpsProxyHost>

      <httpsProxyPort>80</httpsProxyPort>

      </httpsProxyInfo>

    2. If you need to use your own proxy server, alter the <httpProxyHost>, <httpProxyPort>, <httpsProxyHost>, and <httpsProxyPort> tags and specify your proxy server and port.  

  2. Save and Close the file.

Testing the sample

You can test that you have properly setup the sample by using 9iAS.

  1. Start your Oracle9iAS Portal Http Server.

  2. Execute the sample from the Oracle9iAS Portal Http Server.  This refers to the Oracle9iAS Portal Http Server where you configured your sample.

         For example:  http://myserver.mydomain.com:port/servlets/basicauth

  3. You should receive a test page informing you that the sample worked.  If you do not receive the test page, verify that you can execute standard servlets using Oracle 9iAS.  Then, verify all the steps within the SETUP section.

Creating the External Application

You will need to quickly create an external application for PDK-URL Services to map to.

  1. Under the Administer tab, click on Administer External Applications in the Login Server Administration portlet.

  2. Click on Create External Application

  3. Fill out the following information:
    1. Application Name:  Basic Auth Metalink App

    2. Login URL:  http://metalink.oracle.com/metalink/plsql/kno_main.preDoAdvancedQuery

    3. User Name/ID Field Name:  <leave blank>

    4. Password Field Name:  <leave blank>

    5. Type of Authentication Used:  Basic Authentication

  4. Under the Additional Fields section, fill out the following information:

    Field Name Field Value Display to User
    p_text (checked)
    p_forums TRUE (unchecked)
  5. Click OK.

  6. Click on the Basic Auth Metalink App link and supply your username, password and a search value for Metalink.  Leave the box checked to save credentials.

Registering the Provider

After setting up the Provider with the Oracle HTTP Server, you must now register the provider with Oracle9iAS Portal before adding the sample portlet(s) to your page.

  1. Under the Administer tab in the Oracle 9iAS Portal homepage, click on Add a Portlet Provider within the portlet called Provider.

  2.  Enter Provider information for the Sample.
    1. Name: MetalinkBasicAuthProvider

    2. Display Name: Metalink Basic Authentication Provider

    3. Timeout: 100

    4. Timeout Message: Basic Auth Provider Timed Out

    5. Implementation Style: Web

    6. Provider Login Frequency: Always

    7. Check the following box:  Require session specific information such as session id, user, and login time.  This field is relevant only for Web providers. 

    8. Register on Remote Nodes: No

    9. URL: http://myserver.mydomain.com:port/servlets/basicauth (replace this with your URL)

    10. Check the following radio button: The user's identity needs to be mapped to a different name in the Web provider's application, and/or the Web provider requires an external application login for establishment of a browser session.  If selecting this option, specify the external application ID below.

      1. External Application ID:  Basic Auth Metalink App

    11. Proxy:  No (As long as no proxy is required to contact the Provider Adapter).

  3. Click OK.

Adding the Portlet to a Page

  1. You can now add the Metalink Portlet and Metalink Technical Library Portlet to your page.  It should display the Metalink pages directly in your page.  If you do not see the Metalink pages, check your registration page and external application for errors.

Revision History: