VRT 391,810 CVEs tracked · 15,472 in RASP scope · data as of 23 minutes ago

CVE-2016-6812

6.1 Medium Protected by RASP

Description

The HTTP transport module in Apache CXF prior to 3.0.12 and 3.1.x prior to 3.1.9 uses FormattedServiceListWriter to provide an HTML page which lists the names and absolute URL addresses of the available service endpoints. The module calculates the base URL using the current HttpServletRequest. The calculated base URL is used by FormattedServiceListWriter to build the service endpoint absolute URLs. If the unexpected matrix parameters have been injected into the request URL then these matrix parameters will find their way back to the client in the services list page which represents an XSS risk to the client.

CWE-79 · Cross-site scripting

Exploitation Status

No public exploit

Nothing published shows this CVE being exploited, which is not the same as ruling it out. nothing published in 9 years.

CVSS E:U

  • CISA KEV not listed
  • CISA Vulnrichment no assessment published
  • Indexed PoC none indexed
  • EPSS 7.6% chance in 30 days

Waratek Defense Posture

Protected by RASP

A Waratek agent blocks this today.

Applicable rule: CVE has an ARMR patch rule that provides mitigation

  • Protection full a patch rule written for this CVE
  • Action available patch rule
  • Review human armr-file
  • Record active
Decided by armr-patch-file : An ARMR patch file on disk for this CVE
Finding CVE has an ARMR patch rule that provides mitigation

ARMR rule files

1 file

Shipped files covering this CVE. A CVE genuinely takes more than one: separate Maven artifacts hooking different parser classes, the same patch built for two ARMR versions, or a fix at both the framework and the container.

rules/frameworks/apache/cxf/CVE-2016-6812/patch/2.6/CVE-2016-6812.armr patch rule added 2020-06-25 updated 2026-03-04
app("APACHE CXF"):
    requires(version: "ARMR/2.6")

    /***************************************************************************
        CVE-2016-6812 (APACHE CXF)

        CVSS 3.0 Summary:
            Base Score              | 6.1
            Attack Vector           | Network
            Attack Complexity       | Low
            Privileges Required     | None
            User Interaction        | Required
            Scope                   | Changed
            Confidentiality Impact  | Low
            Integrity Impact        | Low
            Availability Impact     | None

        Description:
            Apache CXF HTTP transport module uses FormattedServiceListWriter to
            provide a HTML page which lists the names and absolute URL addresses
            of the available service endpoints. The module calculates the base
            URL using the current HttpServletRequest. The calculated base URL is
            used by FormattedServiceListWriter to build the service endpoint
            absolute URLs. If the unexpected matrix parameters have been
            injected into the request URL then these matrix parameters will find
            their way back to the client in the services list page which
            represents an XSS risk to the client.

        Resources:
            https://github.com/apache/cxf/search?q=CXF-6216&type=Commits
            Two diffs, 'a23c615' is newer than '45b1b5b'

        Affected Operating Systems:
            Any

        Affected Versions:
            Apache CXF: 3.0.11, 3.1.8

        Tested Versions:
            2.7.18, 3.1.8

        Protection Provided:
            Functional

        Patch Version:
            1.1
    ***************************************************************************/

    patch("CVE-2016-6812 :01"):
        function("org/apache/cxf/transport/servlet/BaseUrlHelper.getBaseURL(Ljavax/servlet/http/HttpServletRequest;)Ljava/lang/String;",
            checksums: ["d06abf0b53",  // cxf-rt-transports-http-2.7.18
                        "6ca34af396"]) // cxf-rt-transports-http-3.1.8
        entry()

        code(language: java,   import: ["javax.servlet.ServletRequest",
                                        "javax.servlet.http.HttpServletRequest",
                                        "java.net.URI"]):
            public void patch(JavaFrame frame) {
                HttpServletRequest request = (HttpServletRequest) frame.loadObjectVariable(0);
                String reqPrefix = request.getRequestURL().toString();
                String pathInfo = request.getPathInfo();
                if (!"/".equals(pathInfo) || reqPrefix.contains(";")) {
                    StringBuilder sb = new StringBuilder();
                    URI uri = URI.create(reqPrefix);
                    sb.append(uri.getScheme()).append("://").append(uri.getRawAuthority());
                    String contextPath = request.getContextPath();
                    if (contextPath != null) {
                        sb.append(contextPath);
                    }
                    String servletPath = request.getServletPath();
                    if (servletPath != null) {
                        sb.append(servletPath);
                    }

                    reqPrefix = sb.toString();
                }
                frame.returnString(reqPrefix);
            }
        endcode
    endpatch

    patch("CVE-2016-6812 :02"):
        function("org/apache/cxf/transport/servlet/servicelist/FormattedServiceListWriter.getAbsoluteAddress(Ljava/lang/String;Lorg/apache/cxf/transport/AbstractDestination;)Ljava/lang/String;",
            checksums: ["ba371e8213",   // cxf-rt-transports-http-2.7.18
                        "0a39fe8248"])  // cxf-rt-transports-http-3.1.8
        callreturn("org/apache/cxf/service/model/EndpointInfo.getAddress()Ljava/lang/String;")

        code(language: java):
            public void patch(JavaFrame frame) {
                String endpointAddress = frame.loadStringOperand(0);
                if (endpointAddress.startsWith("http://") || endpointAddress.startsWith("https://")) {
                    return;
                } else {
                    String basePath = frame.loadStringVariable(1);
                    String address = basePath;
                    if (address.endsWith("/") && endpointAddress.startsWith("/")) {
                        address = address.substring(0, address.length() - 1);
                    }
                    frame.returnString(address + endpointAddress);
                }
            }
        endcode
    endpatch

    patch("CVE-2016-6812 :03"):
        function("org/apache/cxf/transport/servlet/servicelist/ServiceListGeneratorServlet.service(Ljavax/servlet/http/HttpServletRequest;Ljavax/servlet/http/HttpServletResponse;)V",
            checksums: ["5181258d31"])  // cxf-rt-transports-http-2.7.18
        callsite("org/apache/cxf/transport/servlet/servicelist/FormattedServiceListWriter.<init>(Ljava/lang/String;Ljava/lang/String;ZLjava/util/Map;)V")

        code(language: java,   import: ["javax.servlet.ServletRequest",
                                        "javax.servlet.http.HttpServletRequest"]):
            private static JavaField serviceListStyleSheetField;

            public void load() {
                serviceListStyleSheetField = JavaField.load("org/apache/cxf/transport/servlet/servicelist/ServiceListGeneratorServlet.serviceListStyleSheet");
            }

            public void patch(JavaFrame frame) {
                Object self = frame.loadThisVariable();
                HttpServletRequest request = (HttpServletRequest) frame.loadObjectVariable(1);
                String serviceListStyleSheet = serviceListStyleSheetField.readString(self);

                String styleSheetPath;
                if (serviceListStyleSheet != null) {
                    styleSheetPath = request.getContextPath() + "/" + serviceListStyleSheet;
                } else {
                    styleSheetPath = "";
                    String contextPath = request.getContextPath();
                    if (contextPath != null) {
                         styleSheetPath += contextPath;
                    }
                    String servletPath = request.getServletPath();
                    if (servletPath != null) {
                        styleSheetPath += servletPath;
                    }
                    String pathInfo = request.getPathInfo();
                    if (pathInfo != null) {
                        styleSheetPath += pathInfo;
                    }
                    if (!styleSheetPath.endsWith("/")) {
                        styleSheetPath += "/";
                    }
                    styleSheetPath += "?stylesheet=1";
                }
                frame.storeStringOperand(1, styleSheetPath);
            }
        endcode
    endpatch

    patch("CVE-2016-6812 :04"):
        function("org/apache/cxf/transport/servlet/servicelist/ServiceListGeneratorServlet.service(Ljavax/servlet/http/HttpServletRequest;Ljavax/servlet/http/HttpServletResponse;)V",
            checksums: ["d31fe23fd9"])  // cxf-rt-transports-http-3.1.8
        callsite("org/apache/cxf/transport/servlet/servicelist/FormattedServiceListWriter.<init>(Ljava/lang/String;Ljava/lang/String;ZLorg/apache/cxf/Bus;)V")

        code(language: java,   import: ["javax.servlet.ServletRequest",
                                        "javax.servlet.http.HttpServletRequest"]):
            private static JavaField serviceListStyleSheetField;

            public void load() {
                serviceListStyleSheetField = JavaField.load("org/apache/cxf/transport/servlet/servicelist/ServiceListGeneratorServlet.serviceListStyleSheet");
            }

            public void patch(JavaFrame frame) {
                Object self = frame.loadThisVariable();
                HttpServletRequest request = (HttpServletRequest) frame.loadObjectVariable(1);
                String serviceListStyleSheet = serviceListStyleSheetField.readString(self);

                String styleSheetPath;
                if (serviceListStyleSheet != null) {
                    styleSheetPath = request.getContextPath() + "/" + serviceListStyleSheet;
                } else {
                    styleSheetPath = "";
                    String contextPath = request.getContextPath();
                    if (contextPath != null) {
                         styleSheetPath += contextPath;
                    }
                    String servletPath = request.getServletPath();
                    if (servletPath != null) {
                        styleSheetPath += servletPath;
                    }
                    String pathInfo = request.getPathInfo();
                    if (pathInfo != null) {
                        styleSheetPath += pathInfo;
                    }
                    if (!styleSheetPath.endsWith("/")) {
                        styleSheetPath += "/";
                    }
                    styleSheetPath += "?stylesheet=1";
                }
                frame.storeStringOperand(1, styleSheetPath);
            }
        endcode
    endpatch

endapp

CVSS

6.1 MEDIUM v3.0 CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N 2 metrics

VRT selects the newest version's highest entry and publishes it as cvssScore, newest rather than largest because scores are not comparable across versions, and highest rather than first because the first entry is frequently a CNA placeholder scoring 0.0 over NVD's own analysis.

VersionScoreBandVectorAssignerType
CVSS 3.0 6.1 MEDIUM CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N NVD Primary published
CVSS 2.0 4.3 no band published AV:N/AC:M/Au:N/C:N/I:P/A:N NVD Primary

Affected Software & Releases

☕ Maven Library Packages

Artifact coordinates and fix boundaries from OSV.dev
Package CoordinateIntroducedFixedLast affected
org.apache.cxf:cxf-core 0 3.0.12 unbounded
org.apache.cxf:cxf-core 3.1.0 3.1.9 unbounded

🖥️ Product CPEs & Version Ranges

2 product(s) over 12 version claims (uncapped)
SourceVendorProductSchemeAffected Versions
nvd apache cxf generic ≤ 3.0.11 · 3.1.0 · 3.1.1 · 3.1.2 · 3.1.3 · 3.1.4 · 3.1.5 · 3.1.6 · 3.1.7 · 3.1.8
osv org.apache.cxf cxf-core generic < 3.0.12 · ≥ 3.1.0 and < 3.1.9

References

URLTags
https://github.com/apache/cxf/commit/1be97cb13aef121b799b1be4d9793c0e8b925a12 WEB
https://github.com/apache/cxf/commit/1f824d8039c7a42a4aa46f844e6c800e1143c7e7 WEB
https://github.com/apache/cxf/commit/32e89366e2daa5670ac7a5c5c19f0bf9329a4c1e WEB
https://github.com/apache/cxf/commit/a30397b0 WEB
https://access.redhat.com/errata/RHSA-2017:0868 WEB
https://github.com/apache/cxf WEB
https://issues.apache.org/jira/browse/CXF-6216 WEB
https://lists.apache.org/thread.html/r36e44ffc1a9b365327df62cdfaabe85b9a5637de102cea07d79b2dbf@%3Ccommits.cxf.apache.org%3E WEB
https://lists.apache.org/thread.html/rc774278135816e7afc943dc9fc78eb0764f2c84a2b96470a0187315c@%3Ccommits.cxf.apache.org%3E WEB
https://lists.apache.org/thread.html/rd49aabd984ed540c8ff7916d4d79405f3fa311d2fdbcf9ed307839a6@%3Ccommits.cxf.apache.org%3E WEB

Timeline

Published 2017-08-10 Last modified 2026-06-17
Published2017-08-10By the CVE Program.
ARMR remediation created2020-06-25Earliest commit adding this CVE's ARMR patch or security rule.
ARMR remediation last updated2026-03-04Most recent commit touching this CVE's ARMR patch or security rule.
Last VRT activity2026-03-04Most recent commit touching this CVE's classification, patch or rule file.
NVD record modified2026-06-17NVD's own last-modified date for this record.