3.7 Policy Management Commands

Note:

The policy management commands for Java EE Web Services (or clients) listed in Table 3-7 have been deprecated in this release for Oracle Infrastructure Web Services.

For Oracle Infrastructure web services, to manage OWSM directly attached policies in release 12c, it is recommended that you use the new WLST commands listed in Table 3-6. For a complete list of deprecated commands, see "Deprecated Commands for Oracle Infrastructure Web Services" in Release Notes for Oracle Fusion Middleware Infrastructure.

Use the WLST commands listed in Table 3-6 to manage Oracle Infrastructure and RESTful Web Services direct and global policy attachments.


Table 3-6 Oracle Infrastructure and RESTful Web Services and Clients - WLST Commands for Direct Policy Attachments

Use this command... To... Use with WLST...

attachWSMPolicy

Attach a policy to the selected policy subject or policy set document within a session.

Online

attachWSMPolicies

Attach multiple policies to the selected policy subject or policy set document within a session.

Online

detachWSMPolicy

Detach a policy from the selected policy subject or policy set document within a session.

Online

detachWSMPolicies

Detach multiple policies from the selected policy subject or policy set document within a session.

Online

enableWSMPolicies

Enable or disable multiple policies that are attached to the selected policy subject or policy set document within a session.

Online

enableWSMPolicy

Enable or disable a policy that is attached to the selected policy subject or policy set document within a session.

Online

listAvailableWebServicePolicies

Display a list of all the available OWSM policies by category or subject type.

Online

listWebServiceClientPolicies

List web service client port policies information for an application or SOA composite.

Online

listWebServicePolicies

List web service port policy information for a web service in an application or SOA composite.

Online

setWSMPolicyOverride

Configure override properties for a policy that is attached to the selected policy subject or policy set document within a session.

Online


Use the WLST commands listed in Table 3-7 to manage Java EE Web Services (or clients) directly attached policies.

Note:

The commands listed in Table 3-7 have an application argument.

In an multi-tenant environment, if you intend to target a specific application instance within a tenant's partition, then you must include the partition name as part of the application as follows:

/domain/server/application#version$partition

However, if you are targeting a domain-scoped application, then you do not have to include the partition name. You can use the application argument as follows:

/domain/server/application#version

Table 3-7 Java EE Web Services (or Clients) - WLST Commands for Direct Policy Attachments

Use this command... To... Use with WLST...

attachWebServiceClientPolicies

Attach multiple policies to a web service client port of an application or SOA composite.

Online

attachWebServiceClientPolicy

Attach an OWSM policy to a web service client port of an application or SOA composite.

Online

attachWebServicePolicies

Attach multiple policies to a web service port of an application or SOA composite.

Online

attachWebServicePolicy

Attach a policy to a web service port of an application or SOA composite.

Online

detachWebServiceClientPolicies

Detach multiple policies from a web service client port of an application or SOA composite.

Online

detachWebServiceClientPolicy

Detach a policy from a web service client port of an application or SOA composite.

Online

detachWebServicePolicies

Detach multiple OWSM policies from a web service port of an application or SOA composite

Online

detachWebServicePolicy

Detach an OWSM policy from a web service port of an application or SOA composite.

Online

enableWebServiceClientPolicies

Enable or disable multiple policies of a web service client port of an application or SOA composite.

Online

enableWebServiceClientPolicy

Enable or disable a policy of a web service client port of an application or SOA composite.

Online

enableWebServicePolicies

Enable or disable multiple policies attached to a port of a web service application or SOA composite.

Online

enableWebServicePolicy

Enable or disable a policy attached to a port of a web service application or SOA composite.

Online

listAvailableWebServicePolicies

Display a list of all the available OWSM policies by category or subject type.

Online

listWebServiceClientPolicies

List web service client port policies information for an application or SOA composite.

Online

listWebServicePolicies

List web service port policy information for a web service in an application or SOA composite.

Online


3.7.1 attachWebServiceClientPolicies

Note:

Use this command for Java EE Web Services (or clients) only. It has been deprecated for Oracle Infrastructure web services.

For Oracle Infrastructure Web Services, this command has been deprecated. It is recommended that you use the attachWSMPolicies command, as described in "attachWSMPolicies". The following examples show how to migrate to use the attachWSMPolicies command.

11g Release:

wls:/wls-domain/serverConfig>attachWebServiceClientPolicies
('/base_domain/server1/jwsclient_1#1.1.0','WssUsernameClient','wsconn',
'WssUsernameClient','JRFWssUsernamePort',["oracle/wss_username_token_client_policy","oracle/log_policy"])

12c Release:

wls:/wls-domain/serverConfig>attachWSMPolicies(["oracle/wss_username_token_client_policy","oracle/log_policy"])

Command Category: Policy Management

Use with WLST: Online

Description

Attaches multiple policies to a web service client port of an application or SOA composite.

The policyURIs are validated through the OWSM Policy Manager APIs if the wsm-pm application is installed on WebLogic Server and is available.

For Java EE (wls) module types only: If the policies that you specify in this command are already attached or exist, then this command enables the policies that are already attached (if they are disabled), and attaches the others.

If the wsm-pm application is not installed or is not available, this command is not executed.

Note:

Policy changes made using this WLST command are only effective after you restart your application.

Syntax

attachWebServiceClientPolicies(application,moduleOrCompName,moduleType, 
serviceRefName,portInfoName,policyURIs,[subjectType=None] )

Argument Definition

application

Name and path of the application for which you want to attach OWSM client policies to the web service client port. For example, /domain/server/application#version_number

To attach policies to a client port of a web service application, this argument is required.

moduleOrCompName

Name of the Web module or SOA composite (for example, HelloWorld[1.0]) for which you want to attach the policies to the client port.

To attach policies to a client port of a SOA composite, the composite name is required (for example, default/HelloWorld[1.0]), and the moduleType argument must be set to soa.

moduleType

Module type. Valid options are:

  • soa—SOA composite.

  • web—Oracle Infrastructure web services packaged as a Web module (including an EJB).

  • wls—Java EE web services.

  • wsconn—Use with a connection-based web service client such as an ADF DC web service client, ADF JAX-WS Indirection Proxy, or WebCenter client.

Note: The web and wsconn module types are deprecated for this release.

serviceRefName

The service reference name of the application or composite.

portInfoName

The client port to which you want to attach the OWSM client policy.

policyURI

The OWSM policy name URIs, for example, ["oracle/log_policy","oracle/wss_username_token_client_policy"]

If the policies that you specify in this command are already attached or exist, then this command enables the policies that are already attached (if they are disabled), and attaches the others.

subjectType

Optional. Policy subject type. Valid options are:

  • P—Port. The default is P.

  • O—Not supported in this release.


Examples

The following example attaches the policy oracle/log_policy to the client port HelloWorld_pt in the SOA composite default/HelloWorld[1.0].

wls:/wls-domain/serverConfig>attachWebServiceClientPolicies
(None, 'default/HelloWorld[1.0]','soa','client','HelloWorld_pt',["oracle/wss_username_token_client_policy","oracle/log_policy"]) 

The following example attaches the policies oracle/wss10_saml20_token_client_policy and oracle/wss11_message_protection_client_policy to the client port UpperCaseImplPort in the Java EE Web module owsm_mbean.resouce_pattern.web.ClientJWS/sei2.

wls:/wls-domain/serverConfig>attachWebServiceClientPolicies
('/wls-domain/AdminServer/ClientJWS','owsm_mbean.resouce_pattern.web.ClientJWS/sei2','wls','owsm_mbean.resouce_pattern.web.ClientJWS/sei2','UpperCaseImplPort',["oracle/wss10_saml20_token_client_policy","oracle/wss11_message_protection_client_policy"])

3.7.2 attachWebServiceClientPolicy

Note:

Use this command for Java EE Web Services (or clients) only. It has been deprecated for Oracle Infrastructure Web Services.

For Oracle Infrastructure Web Services, it is recommended that you use the attachWSMPolicy command, as described in "attachWSMPolicy". The following examples show how to migrate to use the attachWSMPolicy command.

11g Release:

wls:/wls-domain/serverConfig>attachWebServiceClientPolicy
('/base_domain/server1/jwsclient_1#1.1.0','WssUsernameClient','wsconn',
'WssUsernameClient','JRFWssUsernamePort',"oracle/wss_username_token_client_policy")

12c:

wls:/wls-domain/serverConfig>attachWSMPolicy("oracle/wss_username_token_client_policy")

Command Category: Policy Management

Use with WLST: Online

Description

Attaches an OWSM policy to a web service client port of an application or SOA composite.

The policyURI is validated through the OWSM Policy Manager APIs if the wsm-pm application is installed on WebLogic Server and is available.

For Java EE (wls) module types only: If the PolicyURI that you specify in this command already is attached or exists, then this command enables the policy if it is disabled.

If the wsm-pm application is not installed or is not available, this command is not executed.

Note:

Policy changes made using this WLST command are only effective after you restart your application.

Syntax

attachWebServiceClientPolicy(application,moduleOrCompName,moduleType, 
serviceRefName, portInfoName, policyURI, [subjectType=None] )

Argument Definition

application

Name and path of the application for which you want to attach a policy to the web service client port. For example, /domain/server/application#version_number.

To attach a policy to a client port of a web service application, this argument is required.

moduleOrCompName

Name of the Web module or SOA composite (for example, HelloWorld[1.0]) for which you want to attach the policy to the client port.

To attach a policy to a client port of a SOA composite, the composite name is required (for example, default/HelloWorld[1.0]), and the moduleType argument must be set to soa.

moduleType

Module type. Valid options are:

  • soa—SOA composite.

  • web—Oracle Infrastructure web services packaged as a Web module (including an EJB).

  • wls—Java EE web services.

  • wsconn—Use with a connection-based web service client such as an ADF DC web service client, ADF JAX-WS Indirection Proxy, or WebCenter client.

Note: The web and wsconn module types are deprecated for this release.

serviceRefName

The service reference name of the application or composite.

portInfoName

The client port to which you want to attach the OWSM client policy.

policyURI

The OWSM policy name URI, for example, oracle/wss_username_token_client_policy"

If the policy that you specify is already attached or exists, then this command enables the policy if it is disabled.

subjectType

Optional. Policy subject type. Valid options are:

  • P—Port. The default is P.

  • O—Not supported in this release.


Examples

The following example attaches the client policy oracle/log_policy to the client port HelloWorld_pt in the SOA composite default/HelloWorld[1.0].

wls:/wls-domain/serverConfig>attachWebServiceClientPolicy
(None, 'default/HelloWorld[1.0]','soa','client','HelloWorld_pt','oracle/log_policy') 

The following example attaches the oracle/wss_username_token_client_policy client policy to the Java EE web service client port UpperCaseImplPort of the Web module owsm_mbean.resouce_pattern.web.ClientJWS/sei2. The web service is part of the application ClientJWS.

wls:/wls-domain/serverConfig> attachWebServiceClientPolicy ('/wls-domain/AdminServer/ClientJWS','owsm_mbean.resouce_pattern.web.ClientJWS/sei2', 'wls','owsm_mbean.resouce_pattern.web.ClientJWS/sei2', 'UpperCaseImplPort', "oracle/wss_username_token_client_policy")

3.7.3 attachWebServicePolicies

Note:

Use this command for Java EE Web Services (or clients) only. It has been deprecated for Oracle Infrastructure Web Services.

For Oracle Infrastructure Web Services, it is recommended that you use the attachWSMPolicies command, as described in "attachWSMPolicies". The following examples show how to migrate to use the attachWSMPolicies command.

11g Release:

wls:/wls-domain/serverConfig> attachWebServicePolicies
('/base_domain/server1/HelloWorld#1_0','j2wbasicPolicy','web',
'{http://namespace/}WssUsernameService','JRFWssUsernamePort',
["oracle/log_policy", "oracle/wss_username_token_service_policy"])

12c Release:

wls:/wls-domain/serverConfig> attachWSMPolicies["oracle/log_policy", "oracle/wss_username_token_service_policy"])

Command Category: Policy Management

Use with WLST: Online

Description

Attaches multiple policies to a web service port of an application or SOA composite.

The policyURIs are validated through the OWSM Policy Manager APIs if the wsm-pm application is installed on WebLogic Server and is available.

For Java EE (wls) module types only: if any of the policies that you specify in this command are already attached or exist, then this command enables the policies that are already attached (if they are disabled), and attaches the others.

If the wsm-pm application is not installed or is not available, this command is not executed.

Note:

Policy changes made using this WLST command are only effective after you restart your application.

Syntax

attachWebServicePolicies(application, moduleOrCompName, moduleType, serviceName, 
subjectName,policyURIs,[subjectType=None])

Argument Definition

application

Name and path of the application to which you want to attach the web service policies. For example, /domain/server/application#version_number

To attach the policies to a port of a web service application, this argument is required.

moduleOrCompName

Name of the Web module or SOA composite (for example, HelloWorld[1.0]) to which you want to attach web service policies.

To attach the policies to a port of a SOA composite, the composite name is required (for example, default/HelloWorld[1.0]), and the moduleType argument must be set to soa.

moduleType

Module type. Valid options are:

  • soa—SOA composite.

  • web—Oracle Infrastructure web services packaged as a Web module (including an EJB).

  • wls—Java EE web services.

Note: The web module type is deprecated for this release.

serviceName

Name of the web service in the application or SOA composite. For example, {http://namespace/}serviceName. Note that the namespace ({http://namespace/}) should not be included for a SOA composite.

subjectName

Name of the policy subject, port, or operation.

policyURIs

List of OWSM policy name URIs, for example, ["oracle/log_policy","oracle/wss_username_token_service_policy"]

If any of the policies that you specify are already attached or exist, then this command enables the policies that are already attached (if they are disabled), and attaches the others.

subjectType

Optional. Policy subject type. Valid options are:

  • P—Port. The default is P.

  • O—Not supported in this release.


Example

The following example attaches the policies 'oracle/binding_authorization_denyall_policy', 'oracle/wss_username_token_service_policy' to the port helloWorldJaxwsSoapHttpPort of the Web module helloWorldJaxws. The Java EE web service is part of the application helloWorldJaxws for the server AdminServer in the domain wls-domain.

 wls:wls-domain/ServerConfig>attachWebServicePolicies ('/wls-domain/AdminServer/helloWorldJaxws','helloWorldJaxws#1!helloWorldJaxws', 'wls','helloWorldJaxws', 'helloWorldJaxwsSoapHttpPort, ['oracle/binding_authorization_denyall_policy', 'oracle/wss_username_token_service_policy'])

3.7.4 attachWebServicePolicy

Note:

Use this command for Java EE Web Services (or clients) only. It has been deprecated for Oracle Infrastructure Web Services.

For Oracle Infrastructure Web Services, it is recommended that you use the attachWSMPolicy command, as described in "attachWSMPolicy". The following examples show how to migrate to use the attachWSMPolicy command.

11g Release:

wls:/wls-domain/serverConfig> attachWebServicePolicy
('/base_domain/server1/HelloWorld#1_0','j2wbasicPolicy','web',
'{http://namespace/}WssUsernameService','JRFWssUsernamePort','oracle/wss_username_token_service_policy')

12c Release:

wls:/wls-domain/serverConfig> attachWSMPolicy('oracle/wss_username_token_service_policy')

Command Category: Policy Management

Use with WLST: Online

Description

Attaches a policy to a web service port of an application or SOA composite.

The policyURI is validated through the OWSM Policy Manager APIs if the wsm-pm application is installed on WebLogic Server and is available.

For Java EE (wls) module types only: If the PolicyURI that you specify in this command already is attached or exists, then this command enables the policy if it is disabled.

If the wsm-pm application is not installed or is not available, this command is not executed.

Note:

Policy changes made using this WLST command are only effective after you restart your application.

Syntax

attachWebServicePolicy(application, moduleOrCompName, moduleType, serviceName, 
subjectName, policyURI, [subjectType=None])

Argument Definition

application

Name and path of the application to which you want to attach a web service policy. For example, /domain/server/application#version_number

To attach a policy to a port of a web service application, this argument is required.

moduleOrCompName

Name of the Web module or SOA composite (for example, HelloWorld[1.0]) to which you want to attach a web service policy.

To attach a policy to a port of a SOA composite, the composite name is required (for example, default/HelloWorld[1.0]), and the moduleType argument must be set to soa.

moduleType

Module type. Valid options are:

  • soa—SOA composite.

  • web—Oracle Infrastructure web services packaged as a Web module (including an EJB).

  • wls—Java EE web services.

Note: The web module type is deprecated for this release.

serviceName

Name of the web service in the application or SOA composite. For example, {http://namespace/}serviceName. Note that the namespace ({http://namespace/}) should not be included for a SOA composite.

subjectName

Name of the policy subject, port, or operation.

policyURI

OWSM policy name URI, for example, 'oracle/log_policy'

subjectType

Optional. Policy subject type. Valid options are:

  • P—Port. The default is P.

  • O—Not supported in this release.


Examples

The following example attaches the policy oracle/log_policy to the port HelloWorld_pt of the service HelloService in the SOA composite default/HelloWorld[1.0]. Note that the namespace ({http://namespace/}) should not be included for a SOA composite.

wls:/wls-domain/serverConfig>attachWebServicePolicy(None, 'default/HelloWorld[1.0]','soa','HelloService','HelloWorld_pt','oracle/log_policy')

The following example attaches the policy oracle/wss_username_token_service_policy to the port helloWorldJaxwsSoapHttpPort of the Java EE web service helloWorldJaxws.

wls:wls-domain/serverConfig> attachWebServicePolicy ('/wls-domain/AdminServer/helloWorldJaxws','helloWorldJaxws#1!helloWorldJaxws', 'wls','helloWorldJaxws', 'helloWorldJaxwsSoapHttpPort', 'oracle/wss_username_token_service_policy')

A web service cannot contain both a WebLogic web service policy and an Oracle web service policy. If you have a web service with a WebLogic web service policy, you must first detach it before attaching the Oracle web service policy. The following example detaches the WebLogic web service policy Wssp1.2-2007-Saml2.0-SenderVouches-Wss1.1.xml from the port SimplePort in the Java EE web service SimpleEjbService and then attaches the Oracle web service policy oracle/wss_username_token_service_policy.

wls:wls-domain/serverConfig>detachWebServicePolicy('/wls-domain/AdminServer/SimpleJAXWS','SimpleJAXWS#1!SimpleEjbService', 'wls','SimpleEjbService', 'SimplePort','policy:Wssp1.2-2007-Saml2.0-SenderVouches-Wss1.1.xml')
 
wls:wls-domain/serverConfig>attachWebServicePolicy('/wls-domain/AdminServer/SimpleJAXWS','SimpleJAXWS#1!SimpleEjbService', 'wls','SimpleEjbService', 'SimplePort', 'oracle/wss_username_token_service_policy')

Note:

The detachWebServicePolicy WLST command allows you to detach WebLogic web service policies from a web service. However, you cannot use the attachWebServicePolicy WLST command to attach WebLogic web service policies. To attach WebLogic web service policies to a web service, you must use the WebLogic Administration Console.

3.7.5 attachWSMPolicies

Note:

This command applies to Oracle Infrastructure and RESTful web services. It does not apply to Java EE web services in this release.

Command Category: Policy Management

Use with WLST: Online

Description

Within a session, attaches multiple policies, identified by specified the URIs, to the selected policy subject.

You must start a session and select the policy set (selectWSMPolicySet) or policy subject (selectWSMPolicySubject) before initiating the command. However, if attachWSMPolicies is issued when creating or cloning a policy set, there is no need to select the policy set because it is already selected. If there is no current session and no policy subject selected, an error is displayed.

Syntax

attachWSMPolicies(uris)

Element Description

uris

List of OWSM policy name URIs, for example, ["oracle/log_policy","oracle/wss_username_token_service_policy"]


Examples

The following example attaches the policies oracle/log_policy and oracle/wss_username_token_service_policy. It assumes that you have already selected a policy subject.

wls:/wls-domain/serverConfig>attachWSMPolicies(["oracle/log_policy", "oracle/wss_username_token_service_policy"])

3.7.6 attachWSMPolicy

Note:

This command applies to Oracle Infrastructure and RESTful web services. It does not apply to Java EE web services in this release.

Command Category: Policy Management

Use with WLST: Online

Description

Within a session, attaches a policy, identified by the specified URI, to the selected policy subject or policy set.

You must start a session and select the policy set (selectWSMPolicySet) or policy subject (selectWSMPolicySubject) before initiating the command. However, if attachWSMPolicy is issued when creating or cloning a policy set, there is no need to select the policy set because it is already selected. If there is no current session and no policy subject is selected, an error is displayed.

Syntax

attachWSMPolicy(uri)

Argument Definition

uri

OWSM policy name URI, for example, 'oracle/log_policy'


Examples

The following example attaches the policy oracle/wss_username_token_service_policy. It assumes that you have already selected a web service port, a web service client port, or a current policy set.

wls:/wls-domain/serverConfig>attachWSMPolicy('oracle/wss_username_token_service_policy')

3.7.7 detachWebServiceClientPolicies

Note:

Use this command for Java EE Web Services (or clients) only. It has been deprecated for Oracle Infrastructure Web Services.

For Oracle Infrastructure Web Services, it is recommended that you use the detachWSMPolicies command, as described in "detachWSMPolicies". The following examples show how to migrate to use the detachWSMPolicies command.

11g Release:

wls:/wls-domain/serverConfig>detachWebServiceClientPolicies
('/base_domain/server1/jwsclient_1#1.1.0','WssUsernameClient','wsconn',
'WssUsernameClient','JRFWssUsernamePort',
["oracle/log_policy","oracle/wss_username_token_client_policy"])

12c Release:

wls:/wls-domain/serverConfig>detachWSMPolicies(["oracle/log_policy","oracle/wss_username_token_client_policy"])

Command Category: Policy Management

Use with WLST: Online

Description

Detaches multiple policies from a web service client port of an application or SOA composite.

Note:

Policy changes made using this WLST command are only effective after you restart your application.

Syntax

detachWebServiceClientPolicies(application,moduleOrCompName,moduleType, 
serviceRefName,portInfoName,policyURIs,[subjectType=None] )

Argument Definition

application

Name and path of the application for which you want to detach multiple policies from a web service client port. For example, /domain/server/application#version_number

To detach multiple policies from a client port of a web service application, this argument is required.

moduleOrCompName

Name of the Web module or SOA composite (for example, HelloWorld[1.0]) for which you want to detach multiple policies from a client port.

To detach multiple policies from a client port for a SOA composite, the composite name is required (for example, default/HelloWorld[1.0]), and the moduleType argument must be set to soa.

moduleType

Module type. Valid options are:

  • soa—SOA composite.

  • web—Oracle Infrastructure web services packaged as a Web module (including an EJB).

  • wls—Java EE web services.

  • wsconn—Use with a connection-based web service client such as an ADF DC web service client, ADF JAX-WS Indirection Proxy, or WebCenter client.

Note: The web and wsconn module types are deprecated for this release.

serviceRefName

The service reference name of the application or composite.

portInfoName

The client port from which you want to detach the OWSM client policy.

policyURI

The OWSM policy name URI, for example, oracle/wss_username_token_client_policy"

If the policy specified is not attached, an error message is displayed and/or an exception is thrown.

subjectType

Optional. Policy subject type. Valid options are:

  • P—Port. The default is P.

  • O—Not supported in this release.


Example

The following example detaches the client policies oracle/wss10_saml20_token_client_policy and oracle/wss11_message_protection_client_policy of the port UpperCaseImplPort of the Java EE web service module owsm_mbean.resouce_pattern.web.ClientJWS/sei2.

wls:/wls-domain/serverConfig>detachWebServiceClientPolicies('/wls-domain/AdminServer/ClientJWS','owsm_mbean.resouce_pattern.web.ClientJWS/sei2','wls','owsm_mbean.resouce_pattern.web.ClientJWS/sei2','UpperCaseImplPort',["oracle/wss10_saml20_token_client_policy","oracle/wss11_message_protection_client_policy"])

3.7.8 detachWebServiceClientPolicy

Note:

Use this command for Java EE Web Services (or clients) only. It has been deprecated for Oracle Infrastructure Web Services.

For Oracle Infrastructure Web Services, it is recommended that you use the detachWSMPolicy command, as described in "detachWSMPolicy". The following examples show how to migrate to use the detachWSMPolicy command.

11g Release:

wls:/wls-domain/serverConfig>detachWebServiceClientPolicy
('/base_domain/server1/jwsclient_1#1.1.0','WssUsernameClient','wsconn',
'WssUsernameClient','JRFWssUsernamePort','oracle/wss_username_token_client_policy')

12c Release:

wls:/wls-domain/serverConfig>detachWSMPolicy('oracle/wss_username_token_client_policy')

Command Category: Policy Management

Use with WLST: Online

Description

Detaches a policy from a web service client port of an application or SOA composite.

Note:

Policy changes made using this WLST command are only effective after you restart your application.

Syntax

detachWebServiceClientPolicy(application,moduleOrCompName,moduleType, 
serviceRefName, portInfoName, policyURI, [subjectType=None] )

Argument Definition

application

Name and path of the application for which you want to detach a policy from a web service client port. For example, /domain/server/application#version_number

To detach a policy from a client port of a web service application, this argument is required.

moduleOrCompName

Name of the Web module or SOA composite (for example, HelloWorld[1.0]) for which you want to detach the policy from a client port.

To detach a policy from a client port of a SOA composite, the composite name is required (for example, default/HelloWorld[1.0]), and the moduleType argument must be set to soa.

moduleType

Module type. Valid options are:

  • soa—SOA composite.

  • web—Oracle Infrastructure web services packaged as a Web module (including an EJB).

  • wls—Java EE web services.

  • wsconn—Use with a connection-based web service client such as an ADF DC web service client, ADF JAX-WS Indirection Proxy, or WebCenter client.

Note: The web and wsconn module types are deprecated for this release.

serviceRefName

The service reference name of the application or composite.

portInfoName

The client port from which you want to detach the OWSM client policy.

policyURI

The OWSM policy name URI, for example, oracle/wss_username_token_client_policy"

If the policy specified is not attached, an error message is displayed and/or an exception is thrown.

subjectType

Optional. Policy subject type. Valid options are:

  • P—Port. The default is P.

  • O—Not supported in this release.


Examples

The following example detaches the client policy oracle/log_policy from the client port HelloWorld_pt in the SOA composite default/HelloWorld[1.0].

wls:/wls-domain/serverConfig>detachWebServiceClientPolicy(None, 
'default/HelloWorld[1.0]','soa','client','HelloWorld_pt','oracle/log_policy' ) 

The following command detaches the client policy oracle/wss_username_token_client_policy from the client port UpperCaseImplPort in the Java EE client module wsm_mbean.resouce_pattern.web.ClientJWS/sei2.

wls:/wls-domain/serverConfig>  detachWebServiceClientPolicy('/wls-domain/AdminServer/ClientJWS', 'owsm_mbean.resouce_pattern.web.ClientJWS/sei2', 'wls', 'owsm_mbean.resouce_pattern.web.ClientJWS/sei2', 'UpperCaseImplPort', "oracle/wss_username_token_client_policy")

3.7.9 detachWebServicePolicies

Note:

Use this command for Java EE Web Services (or clients) only. It has been deprecated for Oracle Infrastructure Web Services.

For Oracle Infrastructure Web Services, it is recommended that you use the detachWSMPolicies command, as described in "detachWSMPolicies". The following examples show how to migrate to use the detachWSMPolicies command.

11g Release:

wls:/wls-domain/serverConfig>detachWebServicePolicies
('/base_domain/server1/HelloWorld#1_0','j2wbasicPolicy','web',
'{http://namespace/}WssUsernameService','JRFWssUsernamePort',
["oracle/log_policy","oracle/wss_username_token_service_policy"])

12c Release:

wls:/wls-domain/serverConfig>detachWSMPolicies(["oracle/log_policy","oracle/wss_username_token_service_policy"])

Command Category: Policy Management

Use with WLST: Online

Description

Detaches multiple OWSM policies from a web service port of an application or SOA composite.

If the wsm-pm application is not installed or is not available, this command is not executed.

Note:

Policy changes made using this WLST command are only effective after you restart your application.

Syntax

detachWebServicePolicies(application, moduleOrCompName, moduleType, serviceName, 
subjectName, policyURIs,[subjectType=None])

Argument Definition

application

Name and path of the application from which you want to detach the web service policies. For example, /domain/server/application#version_number

To detach policies from a port of a web service application, this argument is required.

moduleOrCompName

Name of the Web module or SOA composite (for example, HelloWorld[1.0]) from which you want to detach the web service policies.

To detach policies from a port of a SOA composite, the composite name is required (for example, default/HelloWorld[1.0]), and the moduleType argument must be set to soa.

moduleType

Module type. Valid options are:

  • soa—SOA composite.

  • web—Oracle Infrastructure web services packaged as a Web module (including an EJB).

  • wls—Java EE web services.

Note: The web module type is deprecated for this release.

serviceName

Name of the web service in the application or SOA composite. For example, {http://namespace/}serviceName. Note that the namespace ({http://namespace/}) should not be included for a SOA composite.

subjectName

Name of the policy subject, port, or operation.

policyURIs

List of OWSM policy name URIs, for example, ["oracle/log_policy","oracle/wss_username_token_service_policy"]

If a policyURI specified is not attached, an error message is displayed and/or an exception is thrown.

subjectType

Optional. Policy subject type. Valid options are:

  • P—Port. The default is P.

  • O—Not supported in this release.


Example

The following example detaches the policies "oracle/binding_authorization_denyall_policy", "oracle/wss_username_token_service_policy" from the port helloWorldJaxwsSoapHttpPort of the Java EE Web module helloWorldJaxws. The web service is part of the application helloWorldJaxws for the server AdminServer in the domain wls-domain.

wls:/wls-domain/serverConfig>detachWebServicePolicies ('/wls-domain/AdminServer/helloWorldJaxws','helloWorldJaxws#1!helloWorldJaxws', 'wls','helloWorldJaxws', 'helloWorldJaxwsSoapHttpPort', ["oracle/binding_authorization_denyall_policy", "oracle/wss_username_token_service_policy"])

3.7.10 detachWebServicePolicy

Note:

Use this command for Java EE Web Services (or clients) only. It has been deprecated for Oracle Infrastructure Web Services.

For Oracle Infrastructure Web Services, it is recommended that you use the detachWSMPolicy command, as described in "detachWSMPolicy". The following examples show how to migrate to use the detachWSMPolicy command.

11g Release:

wls:/wls-domain/serverConfig>detachWebServicePolicy('/base_domain/server1/HelloWorld#1_0','j2wbasicPolicy','web','{http://namespace/}WssUsernameService','JRFWssUsernamePort','oracle/wss_username_token_service_policy')

12c Release:

wls:/wls-domain/serverConfig>detachWSMPolicy('oracle/wss_username_token_service_policy')

Command Category: Policy Management

Use with WLST: Online

Description

Detaches an OWSM policy from a web service port of an application or SOA composite.

Note:

Policy changes made using this WLST command are only effective after you restart your application.

Syntax

detachWebServicePolicy(application, moduleOrCompName, moduleType, serviceName, 
subjectName, policyURI, [subjectType=None])

Argument Definition

application

Name and path of the application from which you want to detach a web service policy. For example, /domain/server/application#version_number

To detach a policy from a port of a web service application, this argument is required.

moduleOrCompName

Name of the Web module or SOA composite (for example, HelloWorld[1.0]) from which you want to detach a web service policy.

To detach a policy from a port of a SOA composite, the composite name is required (for example, default/HelloWorld[1.0]), and the moduleType argument must be set to soa.

moduleType

Module type. Valid options are:

  • soa—SOA composite.

  • web—Oracle Infrastructure web services packaged as a Web module (including an EJB).

  • wls—Java EE web services.

Note: The web module type is deprecated for this release.

serviceName

Name of the web service in the application or SOA composite. For example, {http://namespace/}serviceName. Note that the namespace ({http://namespace/}) should not be included for a SOA composite.

subjectName

Name of the policy subject, port, or operation.

policyURI

OWSM policy name URI, for example, 'oracle/log_policy'

If the policy specified is not attached, an error message is displayed and/or an exception is thrown.

subjectType

Optional. Policy subject type. Valid options are:

  • P—Port. The default is P.

  • O—Not supported in this release.


Examples

The following example detaches the policy oracle/log_policy from the port HelloWorld_pt of the service HelloService in the SOA composite default/HelloWorld[1.0]. Note that the namespace ({http://namespace/}) should not be included for a SOA composite.

wls:/wls-domain/serverConfig>detachWebServicePolicy(None, 'default/HelloWorld[1.0]', 'soa','HelloService','HelloWorld_pt','oracle/log_policy')

The following example detaches the policy oracle/wss_username_token_service_policy from the port helloWorldJaxwsSoapHttpPort of the service helloWorldJaxws in the Java EE web service wls-domain/AdminServer/helloWorldJaxws.

wls:/wls-domain/serverConfig>detachWebServicePolicy
('/wls-domain/AdminServer/helloWorldJaxws','helloWorldJaxws#1!helloWorldJaxws', 'wls','helloWorldJaxws', 'helloWorldJaxwsSoapHttpPort', 'oracle/wss_username_token_service_policy')

3.7.11 detachWSMPolicies

Note:

This command applies to Oracle Infrastructure and RESTful web services. It does not apply to Java EE web services in this release.

Command Category: Policy Management

Use with WLST: Online

Description

Within a session, detaches multiple policies, identified by an array of URIs or index values, from the selected policy subject.

You must start a session and select the policy set (selectWSMPolicySet) or policy subject (selectWSMPolicySubject) before initiating the command. If there is no current session and no policy subject selected, an error is displayed.

Syntax

detachWSMPolicies(uris)

Argument Definition

uris

Array of URIs or index values specifying the policies to detach from a policy subject. For example, ["oracle/log_policy","oracle/wss_username_token_service_policy"]

If the specified policy URIs are not attached, an error message is displayed and/or an exception is thrown.


Examples

The following example detaches the OWSM logging policy and username token service policy from the current policy subject:

wls:/wls-domain/serverConfig>detachWSMPolicies(["oracle/log_policy","oracle/wss_username_token_service_policy"])

The following example uses the index values of the OWSM logging policy and username token service URIs to detach them from the current policy subject

wls:/wls-domain/serverConfig>detachWSMPolicies('1','3')

3.7.12 detachWSMPolicy

Note:

This command applies to Oracle Infrastructure and RESTful web services. It does not apply to Java EE web services in this release.

Command Category: Policy Management

Use with WLST: Online

Description

Within a session, detaches a policy, identified by the specified URI or index value, from the selected policy subject.

You must start a session and select the policy set (selectWSMPolicySet) or policy subject (selectWSMPolicySubject) before initiating the command. If there is no current session and no policy subject selected, an error is displayed

Issuing this command outside of a session containing a policy subject that is being created or modified will result in an error.

Syntax

detachWSMPolicy(uri)

Argument Definition

uri

URI or index value specifying the policy to detach from a policy subject. For example, 'oracle/log_policy'.

If the specified policy URI is not attached, an error message is displayed and/or an exception is thrown.


Examples

The following example detaches the OWSM logging policy from the current policy subject.

wls:/wls-domain/serverConfig>detachWSMPolicy('oracle/log_policy')

The following example uses the index value of the OWSM logging policy's URI to detach it from the current policy subject.

wls:/wls-domain/serverConfig>detachWSMPolicy('1')

3.7.13 enableWebServiceClientPolicies

Note:

Use this command for Java EE Web Services (or clients) only. It has been deprecated for Oracle Infrastructure Web Services.

For Oracle Infrastructure Web Services, it is recommended that you use the enableWSMPolicies command, as described in "enableWSMPolicies". The following examples show how to migrate to use the enableWSMPolicies command.

11g Release:

wls:/wls-domain/serverConfig>enableWebServiceClientPolicies
('/base_domain/server1/jwsclient_1#1.1.0','WssUsernameClient','wsconn',
'WssUsernameClient','JRFWssUsernamePort',
["oracle/log_policy", "oracle/wss_username_token_client_policy"], true ) 

12c Release:

wls:/wls-domain/serverConfig>enableWSMPolicies(["oracle/log_policy", "oracle/wss_username_token_client_policy"], true ) 

Command Category: Policy Management

Use with WLST: Online

Description

Enables or disables multiple policies of a web service client port of an application or SOA composite.

Note:

Policy changes made using this WLST command are only effective after you restart your application

Syntax

enableWebServiceClientPolicies(application,moduleOrCompName,moduleType, 
serviceRefName,portInfoName,policyURIs,[enable],[subjectType=None] )

Argument Definition

application

Name and path of the application for which you want to enable or disable multiple policies of a web service client port. For example, /domain/server/application#version_number

To enable or disable multiple policies of a client port of a web service application, this argument is required.

moduleOrCompName

Name of the Web module or SOA composite (for example, HelloWorld[1.0]) for which you want to enable or disable multiple policies of a client port.

To enable or disable multiple policies of a client port for a SOA composite, the composite name is required (for example, default/HelloWorld[1.0]), and the moduleType argument must be set to soa.

moduleType

Module type. Valid options are:

  • soa—SOA composite.

  • web—Oracle Infrastructure web services packaged as a Web module (including an EJB).

  • wls—Java EE web services.

  • wsconn—Use with a connection-based web service client such as an ADF DC web service client, ADF JAX-WS Indirection Proxy, or WebCenter client.

Note: The web and wsconn module types are deprecated for this release.

serviceRefName

The service reference name of the application or composite.

portInfoName

The name of the client port to which you want to attach the OWSM client policies.

policyURIs

The list of OWSM policy name URIs, for example, ["oracle/log_policy","oracle/wss_username_token_client_policy"].

enable

Optional. Specifies whether to enable or disable the policies. Valid options are:

  • true—Enables the policy. The default is true.

  • false—Disables the policy.

If you omit this argument, the policies are enabled.

subjectType

Optional. Policy subject type. Valid options are:

  • P—Port. The default is P.

  • O—Not supported in this release.


Example

The following example enables the client policies oracle/wss10_saml20_token_client_policy and oracle/wss11_message_protection_client_policy of the port UpperCaseImplPort of the Java EE web service module owsm_mbean.resouce_pattern.web.ClientJWS/sei2.

wls:/wls-domain/serverConfig>enableWebServiceClientPolicies('/wls-domain/AdminServer/ClientJWS','owsm_mbean.resouce_pattern.web.ClientJWS/sei2','wls','owsm_mbean.resouce_pattern.web.ClientJWS/sei2','UpperCaseImplPort',["oracle/wss10_saml20_token_client_policy","oracle/wss11_message_protection_client_policy"], true)

3.7.14 enableWebServiceClientPolicy

Note:

Use this command for Java EE Web Services (or clients) only. It has been deprecated for Oracle Infrastructure Web Services.

For Oracle Infrastructure Web Services, it is recommended that you use the enableWSMPolicy command, as described in "enableWSMPolicy". The following examples show how to migrate to use the enableWSMPolicy command.

11g Release:

wls:/wls-domain/serverConfig>enableWebServiceClientPolicy
('/base_domain/server1/jwsclient_1#1.1.0','WssUsernameClient','wsconn',
'WssUsernameClient','JRFWssUsernamePort', "oracle/wss_username_token_client_policy",true)

12c Release:

wls:/wls-domain/serverConfig>enableWSMPolicy("oracle/wss_username_token_client_policy",true)

Command Category: Policy Management

Use with WLST: Online

Description

Enables or disables a policy of a web service client port of an application or SOA composite.

Note:

Policy changes made using this WLST command are only effective after you restart your application.

Syntax

enableWebServiceClientPolicy(application,moduleOrCompName,moduleType, 
serviceRefName,portInfoName,policyURI,[enable],[subjectType=None] )

Argument Definition

application

Name and path of the application for which you want to enable or disable a policy of a web service client port. For example, /domain/server/application#version_number

To enable or disable a policy of a client port of a web service application, this argument is required.

moduleOrCompName

Name of the Web module or SOA composite (for example, HelloWorld[1.0]) for which you want to enable or disable a policy of a client port.

To enable or disable a policy of a client port for a SOA composite, the composite name is required (for example, default/HelloWorld[1.0]), and the moduleType argument must be set to soa.

moduleType

Module type. Valid options are:

  • soa—SOA composite.

  • web—Oracle Infrastructure web services packaged as a Web module (including an EJB).

  • wls—Java EE web services.

  • wsconn—Use with a connection-based web service client such as an ADF DC web service client, ADF JAX-WS Indirection Proxy, or WebCenter client.

Note: The web and wsconn module types are deprecated for this release.

serviceRefName

The service reference name of the application or composite.

portInfoName

The name of the client port to which you want to attach the OWSM client policy.

policyURI

The OWSM policy name URI, for example, oracle/wss_username_token_client_policy"

enable

Optional. Specifies whether to enable or disable the policy. Valid options are:

  • true—Enables the policy. The default is true.

  • false—Disables the policy.

If you omit this argument, the policy is enabled.

subjectType

Optional. Policy subject type. Valid options are:

  • P—Port. The default is P.

  • O—Not supported in this release.


Examples

The following example enables the client policy oracle/log_policy of the client port HelloWorld_pt in the SOA composite default/HelloWorld[1.0].

wls:/wls-domain/serverConfig>enableWebServiceClientPolicy(None,
'default/HelloWorld[1.0]','soa','client','HelloWorld_pt','oracle/log_policy')

The following example disables the client policy oracle/log_policy of the client port HelloWorld_pt in the SOA composite default/HelloWorld[1.0].

wls:/wls-domain/serverConfig>enableWebServiceClientPolicy(None,
'default/HelloWorld[1.0]','soa','client','HelloWorld_pt','oracle/log_policy', false )

The following example disables the client policy oracle/wss_username_token_client_policy on the client port UpperCaseImplPort in the Java EE Web module owsm_mbean.resouce_pattern.web.ClientJWS/sei2.

wls:/wls-domain/serverConfig>enableWebServiceClientPolicy('/wls-domain/AdminServer/ClientJWS', 'owsm_mbean.resouce_pattern.web.ClientJWS/sei2', 'wls', 'owsm_mbean.resouce_pattern.web.ClientJWS/sei2', 'UpperCaseImplPort', "oracle/wss_username_token_client_policy", false)

3.7.15 enableWebServicePolicies

Note:

Use this command for Java EE Web Services (or clients) only. It has been deprecated for Oracle Infrastructure Web Services.

For Oracle Infrastructure Web Services, it is recommended that you use the enableWSMPolicies command, as described in "enableWSMPolicies". The following examples show how to migrate to use the enableWSMPolicies command.

11g Release:

wls:/wls-domain/serverConfig> enableWebServicePolicies
('/base_domain/server1/HelloWorld#1_0','j2wbasicPolicy','web',
'{http://namespace/}WssUsernameService','JRFWssUsernamePort',["oracle/log_policy", "oracle/wss_username_token_service_policy"],true)

12c Release:

wls:/wls-domain/serverConfig> enableWSMPolicies(["oracle/log_policy","oracle/wss_username_token_service_policy"],true)

Command Category: Policy Management

Use with WLST: Online

Description

Enables or disables multiple policies attached to a port of a web service application or SOA composite.

If the policyURIs that you specify in this command are not attached to the port, an error message is displayed and/or an exception is thrown.

Note:

Policy changes made using this WLST command are only effective after you restart your application.

Syntax

enableWebServicePolicies(application, moduleOrCompName, moduleType, serviceName, 
subjectName, policyURIs,[enable],[subjectType=None] ))

Argument Definition

application

Name and path of the application for which you want to enable the web service policies. For example, /domain/server/application#version_number

To enable policies that are attached to a port of a web service application, this argument is required.

moduleOrCompName

Name of the Web module or SOA composite (for example, HelloWorld[1.0]) for which you want to enable web service policies.

To enable policies that are attached to a port of a SOA composite, the composite name is required (for example, default/HelloWorld[1.0]), and the moduleType argument must be set to soa.

moduleType

Module type. Valid options are:

  • soa—SOA composite.

  • web—Oracle Infrastructure web services packaged as a Web module (including an EJB).

  • wls—Java EE web services.

Note: The web module type is deprecated for this release.

serviceName

Name of the web service in the application or SOA composite.For example, {http://namespace/}serviceName. Note that the namespace ({http://namespace/}) should not be included for a SOA composite.

subjectName

Name of the policy subject, port, or operation.

policyURIs

List of OWSM policy name URIs, for example, ["oracle/log_policy","oracle/wss_username_token_service_policy"]

If the policyURIs that you specify are not attached, an error message is displayed and/or an exception is thrown.

enable

Optional. Specifies whether to enable or disable the policies. Valid options are:

  • true—Enables the policies. The default is true.

  • false—Disables the policies.

If you omit this argument, the policies are enabled.

subjectType

Optional. Policy subject type. Valid options are:

  • P—Port. The default is P.

  • O—Not supported in this release.


Example

The following example disables the policies ["oracle/binding_authorization_denyall_policy","oracle/wss_username_token_service_policy"] attached to the port helloWorldJaxwsSoapHttpPort of the Web module helloWorldJaxws#1!helloWorldJaxws. The web service is part of the application helloWorldJaxws for the server AdminServer in the domain wls-domain.

wls:/wls-domain/serverConfig>enableWebServicePolicies ('/wls-domain/AdminServer/helloWorldJaxws','helloWorldJaxws#1!helloWorldJaxws', 'wls','helloWorldJaxws', 'helloWorldJaxwsSoapHttpPort', ["oracle/binding_authorization_denyall_policy", "oracle/wss_username_token_service_policy"], false)

3.7.16 enableWebServicePolicy

Note:

Use this command for Java EE Web Services (or clients) only. It has been deprecated for Oracle Infrastructure Web Services.

For Oracle Infrastructure Web Services, it is recommended that you use the enableWSMPolicy command, as described in "enableWSMPolicy". The following examples show how to migrate to use the enableWSMPolicy command.

11g Release:

wls:/wls-domain/serverConfig>enableWebServicePolicy
('/base_domain/server1/HelloWorld#1_0','j2wbasicPolicy','web',
'{http://namespace/}WssUsernameService','JRFWssUsernamePort',"oracle/wss_username_token_service_policy",true)

12c Release:

wls:/wls-domain/serverConfig>enableWSMPolicy("oracle/wss_username_token_service_policy",true)

Command Category: Policy Management

Use with WLST: Online

Description

Enables or disables a policy attached to a port of a web service application or SOA composite.

If the policy that you specify in this command is not attached to the port, an error message is displayed and/or an exception is thrown.

Note:

Policy changes made using this WLST command are only effective after you restart your application.

Syntax

enableWebServicePolicy(application, moduleOrCompName, moduleType, serviceName, 
subjectName, policyURI, [enable], [subjectType=None] ))

Argument Definition

application

Name and path of the application for which you want to enable a web service policy. For example, /domain/server/application#version_number

To enable a policy that is attached to a port of a web service application, this argument is required.

moduleOrCompName

Name of the Web module or SOA composite (for example, HelloWorld[1.0]) for which you want to enable a web service policy.

To enable a policy that is attached to a port of a SOA composite, the composite name is required (for example, default/HelloWorld[1.0]), and the moduleType argument must be set to soa.

moduleType

Module type. Valid options are:

  • soa—SOA composite.

  • web—Oracle Infrastructure web services packaged as a Web module (including an EJB).

  • wls—Java EE web services.

Note: The web module type is deprecated for this release.

serviceName

Name of the web service in the application or SOA composite. For example, {http://namespace/}serviceName. Note that the namespace ({http://namespace/}) should not be included for a SOA composite.

subjectName

Name of the policy subject, port, or operation.

policyURI

OWSM policy name URI, for example, 'oracle/log_policy'

If the policy that you specify is not attached, an error message is displayed and/or an exception is thrown.

enable

Optional. Specifies whether to enable or disable the policy. Valid options are:

  • true—Enables the policy. The default is true.

  • false—Disables the policy.

If you omit this argument, the policy is enabled.

subjectType

Optional. Policy subject type. Valid options are:

  • P—Port. The default is P.

  • O—Not supported in this release.


Examples

The following example enables the policy oracle/log_policy attached to the port HelloWorld_pt for the service HelloService in the SOA composite default/HelloWorld[1.0]. Note that the namespace ({http://namespace/}) should not be included for a SOA composite.

wls:/wls-domain/serverConfig>enableWebServicePolicy(None, 'default/HelloWorld[1.0]', 'soa','HelloService','HelloWorld_pt','oracle/log_policy')

The following example disables the policy oracle/log_policy attached to the port HelloWorld_pt for the service HelloService in the SOA composite default/HelloWorld[1.0]. Note that the namespace ({http://namespace/}) should not be included for a SOA composite.

wls:/wls-domain/serverConfig>enableWebServicePolicy(None, 'default/HelloWorld[1.0]', 'soa','HelloService','HelloWorld_pt','oracle/log_policy',false)

The following example disables the policy oracle/wss_username_token_service_policy attached to the port helloWorldJaxwsSoapHttpPort for the service helloWorldJaxws in the Java EE web service wls-domain/AdminServer/helloWorldJaxws

wls:/wls-domain/domainRuntime> enableWebServicePolicy ('/wls-domain/AdminServer/helloWorldJaxws','helloWorldJaxws#1!helloWorldJaxws', 'wls','helloWorldJaxws', 'helloWorldJaxwsSoapHttpPort', 'oracle/wss_username_token_service_policy', false)

3.7.17 enableWSMPolicies

Note:

This command applies to Oracle Infrastructure and RESTful web services. It does not apply to Java EE web services in this release.

Command Category: Policy Management

Use with WLST: Online

Description

Within a session, enables or disables multiple policy attachments, identified by the specified URIs, that are attached to a policy subject.

You must start a session and select the policy set (selectWSMPolicySet) or policy subject (selectWSMPolicySubject) before initiating the command. However, if enableWSMPolicies is issued when creating or cloning a policy set, there is no need to select the policy set because it is already selected.

If the optional enable argument is not specified, this command enables the policy attachment by default. If the policy URIs that you specify in this command are not attached to the port, an error message is displayed and/or an exception is thrown.

Syntax

enableWSMPolicies(uris,[enable=true]))

Argument Definition

uris

List of OWSM policy name URIs, for example, ["oracle/log_policy","oracle/wss_username_token_service_policy"]

If the policyURIs that you specify are not attached, an error message is displayed and/or an exception is thrown.

enable

Optional. Specifies whether to enable or disable the policy attachments. Valid options are:

  • true—Enables the specified policy attachments. The default is true.

  • false—Disables the specified policy attachments.

If you omit this argument, the policies are enabled.


Examples

The following example enables the policies ["oracle/log_policy","oracle/wss_username_token_service_policy"] attached to the port JRFWssUsernamePort of the Web module WssUsernameService. The web service is part of the application HelloWorld#1_0 for the server server1 in the domain base_domain.

wls:/wls-domain/serverConfig>enableWSMPolicies(["oracle/log_policy","oracle/wss_username_token_service_policy"],true)

3.7.18 enableWSMPolicy

Note:

This command applies to Oracle Infrastructure and RESTful web services. It does not apply to Java EE web services in this release.

Command Category: Policy Management

Use with WLST: Online

Description

Within a session, enables or disables a policy attachment, identified by a specified URI, that is attached to a policy subject.

You must start a session and select the policy set (selectWSMPolicySet) or policy subject (selectWSMPolicySubject) before initiating the command. However, if enableWSMPolicy is issued when creating or cloning a policy set, there is no need to select the policy set because it is already selected.

If the optional enable argument is not specified, this command enables the policy attachment by default. If the policyURIs that you specify in this command are not attached to the port, an error message is displayed and/or an exception is thrown.

Syntax

enableWSMPolicy(uri,[enable=true])

Argument Definition

uri

URI specifying the policy attachment within the policy set.

enable

Optional. Specifies whether to enable or disable the policy attachment specified by the URI in the policy set. Valid options are:

  • true—Enables the specified policy attachment in the policy set. The default is true.

  • false—Disables specified policy attachment in the policy set.

If you omit this argument, the policy set attachment is enabled.


Examples

The following example enables the policy oracle/wss_username_token_service_policy attached to the port JRFWssUsernamePort of the Web module WssUsernameService. The web service is part of the application HelloWorld#1_0 for the server server1 in the domain base_domain.

wls:/wls-domain/serverConfig>enableWSMPolicy("oracle/wss_username_token_service_policy",true)

The following example enables the policy oracle/log_policy attached to the port HelloWorld_pt for the service HelloService in the SOA composite default/HelloWorld[1.0].

wls:/wls-domain/serverConfig>enableWSMPolicy('oracle/log_policy')

The following example disables the policy oracle/log_policy attached to the port HelloWorld_pt for the service HelloService in the SOA composite default/HelloWorld[1.0].

wls:/wls-domain/serverConfig>enableWSMPolicy('oracle/log_policy',false)

3.7.19 listAvailableWebServicePolicies

Command Category: Policy Management

Use with WLST: Online

Description

Displays a list of all the available OWSM policies by category or subject type.

Syntax

listAvailableWebServicePolicies([category],[subject])

Argument Definition

category

Optional. The policy category, for example,: 'security', 'management'.

subject

Optional. The policy subject type, for example,: 'server' or 'client'.


Example

The following example lists all the available OWSM server security policies in the domain.

wls:/wls-domain/serverConfig>listAvailableWebServicePolicies('security','server')

3.7.20 listWebServiceClientPolicies

Command Category: Policy Management

Use with WLST: Online

Description

Lists web service client port policies information for an application or SOA composite.

The output will display the web service client/reference port name, the OWSM policies it has attached to it and details about each attachment such as the policy category, status, the source of the policy attachment, any policy override properties (if applicable), and if the policy is in effect for the subject. It also displays if the policy subject is secure. For example:

test-port:
URI=oracle/wss_username_token_client_policy, category=security, policy-status=enabled
 source=local policy set; reference-status=enabled; effective=true
 The policy subject is secure in this context.

Syntax

listWebServiceClientPolicies(application, moduleOrCompName, moduleType, 
serviceRefName,portInfoName)

Argument Definition

application

Name and path of the application for which you want to list the web service client port policy information. For example, /domain/server/application#version_number

To list the client port policy information for a web services application, this argument is required.

moduleOrCompName

Name of the Web module or SOA composite (for example, HelloWorld[1.0]) for which you want to list the web services port policy information.

To list the client port policy information for a SOA composite, the composite name is required (for example, default/HelloWorld[1.0]), and the moduleType argument must be set to soa.

moduleType

Module type. Valid options are:

  • soa—SOA composite.

  • web—Oracle Infrastructure web services packaged as a Web module (including an EJB).

  • wls—Java EE web services.

  • wsconn—Use with a connection-based web service client such as an ADF DC web service client, ADF JAX-WS Indirection Proxy, or WebCenter client.

serviceRefName

The service reference name of the application or composite.

portInfoName

The client port name.


Example

The following example lists the web service client port policy information for the application jwsclient_1#1.1.0 for the server server1 in the domain base_domain. In this example, the Web module name is WssUsernameClient, the module type is wsconn, the service reference name is WssUsernameClient, and the client port name is JRFWssUsernamePort.

wls:/wls-domain/serverConfig>listWebServiceClientPolicies
('/base_domain/server1/jwsclient_1#1.1.0','WssUsernameClient','wsconn',
'WssUsernameClient','JRFWssUsernamePort') 

3.7.21 listWebServicePolicies

Command Category: Policy Management

Use with WLST: Online

Description

Lists web service policy information for a web service port in an application or SOA composite.

The output will display the web service port name, the OWSM policies it has attached to it and details about each attachment such as the policy category, status, the source of the policy attachment, any policy override properties (if applicable), and if the policy is in effect for the subject. It also displays if the policy subject is secure. For example:

CalculatorPort:
URI="oracle/wss_username_token_service_policy", category=security, policy-status=enabled;
 source=local policy set; reference-status=enabled; effective=true
 The policy subject is secure in this context.

Syntax

listWebServicePolicies(application,moduleOrCompName,moduleType,serviceName,subjectName)

Argument Definition

application

Name and path of the application for which you want to list the web services port policy information. For example, /domain/server/application#version_number

To list the port policy information for a web service application, this argument is required.

moduleOrCompName

Name of the Web module or SOA composite (for example, HelloWorld[1.0]) for which you want to list the web services port policy information.

To list the port policy information for a SOA composite, the composite name is required (for example, default/HelloWorld[1.0]), and the moduleType argument must be set to soa.

moduleType

Module type. Valid options are:

  • soa—SOA composite.

  • web—Oracle Infrastructure web services packaged as a Web module (including an EJB).

  • wls—Java EE web services.

serviceName

Name of the web service in the application or SOA composite for which you want to list the port policy information. For example, {http://namespace/}serviceName. Note that the namespace ({http://namespace/}) should not be included for a SOA composite.

subjectName

Policy subject, port, or operation name.


Examples

The following example lists the web service policy information for the port CalculatorPort in the application jaxwsejb30ws. In this example, the Web module name is jaxwsejb, and the service name is CalculatorService.

wls:/wls-domain/serverConfig>listWebServicePolicies ('/base_domain/AdminServer/jaxwsejb30ws','jaxwsejb','web', '{http://namespace/}CalculatorService', 'CalculatorPort')

The following example lists the port policy information for the SOA composite default/HelloWorld[1.0]. Note that the moduleType is set to SOA, the service name is HelloService, and the subject is a port named HelloWorld_pt. Note that the namespace ({http://namespace/}) should not be included for a SOA composite.

wls:/wls-domain/serverConfig>listWebServicePolicies (None, 'default/HelloWorld[1.0]', 'soa', 'HelloService', 'HelloWorld_pt')

3.7.22 setWebServicePolicyOverride

Note:

This command has been deprecated for Oracle Infrastructure Web Services. It is recommended that you use the setWSMPolicyOverride command, as described in "setWSMPolicyOverride".

This command does not apply to Java EE web services.

The following examples show how to migrate to use the setWSMPolicyOverride command.

11g Release:

wls:/jrfServer_domain/serverConfig> setWebServicePolicyOverride ('/base_domain/server1/HelloWorld#1_0','j2wbasicPolicy', 'web', '{http://namespace/}WssUsernameService','JRFWssUsernamePort', 'oracle/wss_username_token_service_policy', 'reference.priority', '10')
 

12c Release (for repository and policy subject operations):

wls:/jrfServer_domain/serverConfig> setWSMPolicyOverride ('oracle/wss_username_token_service_policy', 'reference.priority', '10')
 

Command Category: Policy Management

Use with WLST: Online

Description

Configures the web service port policy override properties of an application or SOA composite.

Syntax

setWebServicePolicyOverride(application,moduleOrCompName,moduleType, serviceName, 
portName,policyURI,properties)

Argument Definition

application

Name and path of the application for which you want to override the web service port policy. For example, /domain/server/application#version_number

To override properties on a policy attached to a port of a web service application, this argument is required.

moduleOrCompName

Name of the Web module or SOA composite (for example, HelloWorld[1.0]) for which you want to override a web service port policy.

To override properties on a policy attached to a SOA composite, the composite name is required (for example, default/HelloWorld[1.0]), and the moduleType argument must be set to soa.

moduleType

Module type. The valid option is web—Oracle Infrastructure web services packaged as a Web module (including an EJB).

Note: The module type wls is not supported.

serviceName

Name of the web service in the application or SOA composite. For example, {http://namespace/}serviceName. Note that the namespace ({http://namespace/}) should not be included for a SOA composite.

subjectName

Name of the policy subject, port, or operation.

policyURI

OWSM policy name URI, for example, 'oracle/log_policy' to which the override properties will be applied.

If the policy specified is not attached, an error message is displayed and/or an exception is thrown.

properties

Policy override properties. Properties must be specified using the following format:

[("name","value")]

For example: [("myprop","myval")]

If this argument is set to None, then all policy overrides are removed.


Examples

The following example configures the override properties for the policy oracle/wss10_message_protection_service_policy for the port JRFWssUsernamePort of the Web module WssUsernameService. The web service is part of the application HelloWorld#1_0 for the server server1 in the domain base_domain.

wls:/wls-domain/serverConfig>setWebServicePolicyOverride ('/base_domain/server1/HelloWorld#1_0','j2wbasicPolicy', 'web', '{http://namespace/}WssUsernameService','JRFWssUsernamePort', "oracle/wss10_message_protection_service_policy", [("keystore.sig.csf.key","sigkey")])

3.7.23 setWSMPolicyOverride

Note:

For direct policy attachments, this command applies to Oracle Infrastructure and RESTful web services only. For configuration overrides on policy references within a policy set, this command also applies to Java EE web services. For more information about configuration overrides in policy sets, see "Overriding Configuration Properties for Globally Attached Policies Using WLST" in Securing Web Services and Managing Policies with Oracle Web Services Manager.

The local.policy.reference.source property is for informational purposes only, to identify the source of the direct policy attachment, and should not be overridden. For more information, see "Determining the Source of Policy Attachments" in Securing Web Services and Managing Policies with Oracle Web Services Manager.

Command Category: Policy Management

Use with WLST: Online

Description

Within a session, adds a configuration override, described by a name-value pair, to a policy identified by the specified URI and attached to the policy set document or policy subject. The value argument is optional. If the value argument is omitted, the property specified by the name argument is removed from the policy subject. If the property specified by the name argument already exists and a value argument is provided, the current value is overwritten by the new value.

You must start a session and select the policy set (selectWSMPolicySet) or policy subject (selectWSMPolicySubject) before initiating the command. If there is no current session and no policy subject selected, an error is displayed.

Syntax

setWSMPolicyOverride(uri, name, value)

Argument Description

uri

String representing the policy URI. For example, 'oracle/wss10_saml_token_service_policy', to which the override properties will be applied.

name

String representing the name of the override property. For example: ['reference.priority']

value

Optional. String representing the value of the property. If this argument is not specified, the property specified by the name argument, if it exists, is removed.


Examples

The following example specifies a configuration override for the reference.priority property for the oracle/wss10_saml_token_service_policy to a value of 1.

wls:/wls-domain/serverConfig> setWSMPolicyOverride('oracle/wss10_saml_token_service_policy', 'reference.priority','1')

The following example removes the property reference.priority from the oracle/wss10_saml_token_service_policy in the policy set.

wls:/wls-domain/serverConfig> setWSMPolicyOverride('oracle/wss10_saml_token_service_policy', 'reference.priority')