use-x-forwarded-headers in Camel cxfEndpoint in Fuse
Issue
- We use a cxfEndpoint behind an Apache reverse proxy. We want to use the
X-Forwarded-ForandX-Forwarded-ProtoHTTP-Headers to let cxf generate the the WSDL using the original server name (or IP) and the Protocol. For example the wsdl should look like this:
<wsdl>
...
<xs:include schemaLocation="https://myrealserver.com/ws/mywebservice?xsd=myDefinition.xsd"></xs:include>
...
</wsdl>
instead of
<wsdl>
...
<xs:include schemaLocation="http://localhost:8181/ws/mywebservice?xsd=myDefinition.xsd"></xs:include>
...
</wsdl>
- There is a flag
use-x-forwarded-headersavailable for the CXFServlet which should fulfil the requirement but we don't know how to pass this flag to the cxfEndpoint ?
Environment
- Red Hat JBoss Fuse
- 6.x
- Apache Camel
- camel-cxf component
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.