CVE-2018-8039
Apache CXF TLS hostname verification does not work correctly with com.sun.net.ssl.*
Description
It is possible to configure Apache CXF to use the com.sun.net.ssl implementation via 'System.setProperty("java.protocol.handler.pkgs", "com.sun.net.ssl.internal.www.protocol");'. When this system property is set, CXF uses some reflection to try to make the HostnameVerifier work with the old com.sun.net.ssl.HostnameVerifier interface. However, the default HostnameVerifier implementation in CXF does not implement the method in this interface, and an exception is thrown. However, in Apache CXF prior to 3.2.5 and 3.1.16 the exception is caught in the reflection code and not properly propagated. What this means is that if you are using the com.sun.net.ssl stack with CXF, an error with TLS hostname verification will not be thrown, leaving a CXF client subject to man-in-the-middle attacks.
Affected Maven artifacts (2)
| Artifact | Affected versions | Fixed in |
|---|---|---|
| org.apache.cxf » apache-cxf | < 3.1.16>= 3.2.0, < 3.2.5 | 3.1.16, 3.2.5 |
| org.apache.cxf » cxf-rt-transports-http | < 3.1.16>= 3.2.0, < 3.2.5 | 3.1.16, 3.2.5 |
Blast radius
57% of the dependent artifacts (3,879) still pull an affected version in their latest release.
| Depth | Dependent versions |
|---|---|
| Direct | 34,928 |
| 2 hops | 69,682 |
| 3 hops | 49,796 |
| 4 hops | 29,409 |
| 5 hops | 23,222 |
| 6 hops | 12,498 |
Most used dependents
- org.apache.cxf » cxf-rt-frontend-jaxws1,379 usages
- org.apache.cxf » cxf-rt-frontend-jaxrs1,257 usages
- io.fabric8 » fabric8-maven-plugin676 usages
- org.apache.camel.springboot » camel-core-starter558 usages
- org.apache.cxf » cxf-rt-rs-client515 usages
- org.apache.cxf » cxf-rt-transports-http-jetty513 usages
- org.apache.tika » tika-parsers480 usages
- org.apache.camel.springboot » camel-spring-boot-starter478 usages
- org.xwiki.platform » xwiki-platform-oldcore449 usages
- org.wildfly » wildfly-feature-pack372 usages
- com.alibaba » dubbo337 usages
- org.apache.camel.quarkus » camel-quarkus-maven-plugin302 usages
- org.apache.cxf » cxf-rt-rs-service-description281 usages
- org.apache.camel » camel-cxf259 usages
- org.apache.maven.plugins » maven-changes-plugin216 usages
Computed from the dependency graph of build 20261124.0621 (compile and runtime scopes, nearest version wins). Exclusions and dependency management in consuming projects are not applied, so dependents are potentially affected. When several artifacts are affected, a dependent version that pulls more than one of them is counted once per artifact.
