Man-in-the-Middle (MitM) Affecting org.apache.cxf:cxf-rt-transports-http package, versions [,3.1.16)[3.2.0,3.2.6)


Severity

Recommended
0.0
high
0
10

CVSS assessment made by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
1.1% (85th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-JAVA-ORGAPACHECXF-31691
  • published4 Jul 2018
  • disclosed2 Jul 2018
  • creditUnknown

Introduced: 2 Jul 2018

CVE-2018-8039  (opens in a new tab)
CWE-300  (opens in a new tab)

How to fix?

Upgrade org.apache.cxf:cxf-rt-transports-http to version 3.1.16, 3.2.6 or higher.

Overview

org.apache.cxf:cxf-rt-transports-http is an open source services framework.

Affected versions of this package are vulnerable to Man-in-the-Middle (MitM). When configuring CXF to use the com.sun.net.ssl implementation via:

System.setProperty("java.protocol.handler.pkgs", "com.sun.net.ssl.internal.www.protocol");

It attempts to make the HostnameVerifier work with the old com.sun.net.ssl.HostnameVerifier interface, but the default HostnameVerifier implementation in CXF does not implement the method in this interface which caused an exception is thrown. This exception caught in the reflection code and not properly propagated. Thus the TLS hostname verification error will not be thrown, leaving a CXF client subject to man-in-the-middle attacks.

CVSS Scores

version 3.1