| Oracle Application Server Portal PL/SQL API Reference - 904 | |||||||
| PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES | |||||||
| SUMMARY: EXCEPTION | TYPE | CONSTANT | VARIABLE | FUNCTION/PROCEDURE | DETAIL: EXCEPTION | TYPE | CONSTANT | VARIABLE | FUNCTION/PROCEDURE | |||||||
This package contains methods for administering Oracle Portal proxy settings.
Proxy settings are used for URL connections from the Portal middle tier and the database tier. For proxy settings to be used by the middle tier to contact the Portal database, they must be specified in the middle tier.
Note: Users must have the All Objects Manage privilege to use the add_proxy, delete_proxy and edit_proxy functions.
| Exception Summary | |
PROXY_DUPLICATE_EXCEPTION | |
PROXY_GENERAL_EXCEPTION | |
PROXY_NOT_FOUND_EXCEPTION | |
PROXY_VALD_EXCEPTION | |
| Type Summary | |
proxy_info | record |
proxy_info_tab | table |
proxy_record | record |
proxy_record_tab | table |
| Constant Summary | |
DEFAULT_PROXY_NO | number |
DEFAULT_PROXY_YES | number |
| Function/Procedure Summary | |
add_proxy | varchar2 |
delete_proxy | |
edit_proxy | |
get_default_proxy | proxy_info |
get_noproxy_domain | varchar2 |
get_proxy | proxy_info |
get_proxy_id | varchar2 |
get_proxy_list | proxy_info_tab |
is_proxy_used_by_providers | boolean |
set_default_proxy | |
set_noproxy_domain | |
| Exception Detail |
PROXY_DUPLICATE_EXCEPTION exception
PROXY_GENERAL_EXCEPTION exception
PROXY_NOT_FOUND_EXCEPTION exception
PROXY_VALD_EXCEPTION exception
| Type Detail |
type proxy_info is record (
id varchar2(32),
host_name varchar2(2000),
port_number number,
default_proxy boolean
)
This record is returned whenever information about proxies is requested, i.e. by the get_proxy, get_proxy_list and get_default_proxy functions.
Note: For security reasons, this record does not contain authorization information but it does contain default proxy information.
id - a unique identifier for the Proxy. This
identifier is allocated by Oracle Portal.host_name - a name for the proxy hostport_number - the port number of the proxy serverdefault_proxy - indicates whether the proxy is to be used as
the default proxy for all non-provider HTTP
connections made by Portaltype proxy_info_tab is table of proxy_info index by binary_integer
type proxy_record is record (
id varchar2(32),
host_name varchar2(2000),
port_number number,
username varchar2(200),
password varchar2(4000),
realm varchar2(4000)
)
This record is used when adding/editing proxy settings, i.e. when using the add_proxy, edit_proxy and delete_proxy methods.
id - a unique identifier for the Proxy. This identifier
is allocated by Oracle Portal.host_name - a name for the proxy host.
The format of the host name should be
'host.domain.com'. If 'http' or 'https' is included
before the host name, it is removed.port_number - the port number of the proxy serverusername - username for connecting to the proxy, if the proxy
is secure.
Note that this field is not currently used.password - password for connecting to the proxy, if the proxy
is secure.
Note that this field is not currently used.realm - specifies the authorization space for the proxy.
The value of this string is assigned by the proxy
server.
Note that this field is not currently used.type proxy_record_tab is table of proxy_record index by binary_integer
| Constant Detail |
DEFAULT_PROXY_NO constant number := 0
DEFAULT_PROXY_YES constant number := 1
| Function/Procedure Detail |
function add_proxy(
p_proxy in proxy_record
) return varchar2Call this function to add a proxy setting to Oracle Portal. If specified, the port number of the proxy must be a valid integer. If not specified, it defaults to a value of 80.
Note: Only Portal Administrators can use this function.
Example:
declare
l_proxy_record wwctx_api_proxy.proxy_record;
l_proxy_id varchar2(32);
begin
l_proxy_record.host_name := 'host.domain.com';
l_proxy_record.port_number := 4000;
l_proxy_id := wwctx_api_proxy.add_proxy
(
l_proxy_record
);
end;
p_proxy - the proxy record containing details about the proxywwsec_api.ACCESS_DENIED_EXCEPTION - if security privileges
are violatedPROXY_DUPLICATE_EXCEPTION - if a proxy with the same
host_name and port number existsPROXY_GENERAL_EXCEPTION - if an unknown error occurs
procedure delete_proxy(
p_proxy_id in varchar2
) Note: Only Portal Administrators can execute this function.
p_proxy_id - the id of the proxy to be deletedwwsec_api.ACCESS_DENIED_EXCEPTION - if security privileges
are violatedPROXY_NOT_FOUND_EXCEPTION - if the proxy is not foundPROXY_GENERAL_EXCEPTION - if an unknown error occurs
procedure edit_proxy(
p_proxy in proxy_record
) Call this procedure to edit properties of a proxy setting in Oracle Portal. If specified, the port number of the proxy must be a valid integer. If not specified, it defaults to a value of 80.
Note: Only Portal Administrators can execute this function.
Example:
l_proxy_record wwctx_api_proxy.proxy_record; l_proxy_record.id := '8834567897456aaaaa45678898989456'; l_proxy_record.host_name := 'host.domain.com'; l_proxy_record.port_number := 5000; wwctx_api_proxy.edit_proxy(l_proxy_record);
p_proxy - the proxy record containing details about the proxywwsec_api.ACCESS_DENIED_EXCEPTION - if security privileges are
violatedPROXY_DUPLICATE_EXCEPTION - if a proxy with the same
host_name and port number existsPROXY_GENERAL_EXCEPTION - if an unknown error occursfunction get_default_proxy return proxy_info
Example:
l_proxy_info wwctx_api_proxy.proxy_info; l_proxy_info := wwctx_api_proxy.get_default_proxy;
PROXY_NOT_FOUND_EXCEPTION - if the proxy is not foundPROXY_GENERAL_EXCEPTION - if an unknown error occursfunction get_noproxy_domain return varchar2
Example:
l_no_proxy varchar2; l_no_proxy := wwctx_api_proxy.get_noproxy_domain;
PROXY_GENERAL_EXCEPTION - if an unknown error occurs
function get_proxy(
p_proxy_id in varchar2
) return proxy_infoCall this function to return information about the proxy like the host name, port number and default proxy, given a proxy ID.
Example:
l_proxy_info wwctx_api_proxy.proxy_info;
l_proxy_info := wwctx_api_proxy.get_proxy
(
p_proxy_id => '8834567897456aaaaa45678898989456'
);
p_proxy_id - the ID of the proxy requiredPROXY_NOT_FOUND_EXCEPTION - if the proxy is not foundPROXY_GENERAL_EXCEPTION - if an unknown error occurs
function get_proxy_id(
p_proxy_hostname in varchar2,
p_proxy_portnumber in varchar2
) return varchar2Example:
l_proxy_id varchar2;
l_proxy_id := wwctx_api_proxy.get_proxy_id
(
p_proxy_hostname => 'host.domain.com',
p_proxy_portnumber => 4000
);
p_proxy_hostname - the host name of the proxy required.
The format of the host name should be
‘host.domain.com’. If ‘http’ or ‘https’
is included before the host name, it is
removed.p_proxy_portnumber - the port number of the proxy requiredPROXY_NOT_FOUND_EXCEPTION - if the proxy is not foundPROXY_GENERAL_EXCEPTION - if an unknown error occursfunction get_proxy_list return proxy_info_tab
Example:
l_proxy_tab wwctx_api_proxy.proxy_info_tab; l_proxy_tab := wwctx_api_proxy.get_proxy_list;
PROXY_GENERAL_EXCEPTION - if an unknown error occurs
function is_proxy_used_by_providers(
p_proxy_id in varchar2
) return booleanExample:
l_is_used Boolean;
l_is_used := wwctx_api_proxy.is_proxy_used_by_providers
(
p_proxy_id => '8834567897456aaaaa45678898989456'
);
p_proxy_id - the id of the proxy requiredPROXY_GENERAL_EXCEPTION - if an unknown error occurs
procedure set_default_proxy(
p_proxy_id in varchar2
) The default proxy is used for all non-provider HTTP connections made by Portal. Administrators can choose one proxy as the # default proxy.
Note: The existing default proxy is updated such that it is no longer the default proxy, i.e. the current default setting is overwritten.
Example:
wwctx_api_proxy.set_default_proxy
(
p_proxy_id => '83456ABCD09783465384'
);
p_proxy_id - the ID of the new, default proxywwsec_api.ACCESS_DENIED_EXCEPTION - if security privileges
are violatedPROXY_NOT_FOUND_EXCEPTION - if the proxy is not foundPROXY_GENERAL_EXCEPTION - if an unknown error occurs
procedure set_noproxy_domain(
p_noproxy_domain in varchar2
) Note: Proxy servers will not be used when connecting to these domains.
Example:
wwctx_api_proxy.set_noproxy_domain
(
p_noproxy_domain => '.domain1.company.com, .domain2.company.com'
);
PROXY_GENERAL_EXCEPTION - if an unknown error occurs
| Oracle Application Server Portal PL/SQL API Reference - 904 | |||||||
| PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES | |||||||
| SUMMARY: EXCEPTION | TYPE | CONSTANT | VARIABLE | FUNCTION/PROCEDURE | DETAIL: EXCEPTION | TYPE | CONSTANT | VARIABLE | FUNCTION/PROCEDURE | |||||||