A CXF-generated service proxy is the Java object making SOAP calls. A forward proxy is a network intermediary carrying those HTTP connections. They are different objects even when an error calls both a proxy.

The network choice is represented by the invoked client's HTTP transport policy:

Policy fieldRole
ProxyServerThe intermediary host.
ProxyServerPortIts listening port.
ProxyServerTypeThe proxy type expected by that transport.
NonProxyHostsDestinations exempted from that proxy policy.

For an HTTP JAX-WS client, the underlying CXF client exposes an HTTPConduit whose policy can be configured through its supported code or deployment path. Preserve the other policy values already applied by the application. For an HTTP policy allowed to use a public route, the HTTP proxy list supplies candidate host and port values.

CXF separates proxy authorization from destination authorization. A 407 from the intermediary does not ask for the service object's application login.

Identify the active CXF version and transport before adapting a conduit example. A field or XML element can affect the request only when it belongs to the configuration path that client actually consumes.

Related articles