This repository has been archived by the owner on Jun 27, 2024. It is now read-only.
fix(deps): update dependency org.eclipse.jetty:jetty-server to v9.4.51.v20230217 [security] #79
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
9.4.15.v20190215
->9.4.51.v20230217
Warning
Some dependencies could not be looked up. Check the Dependency Dashboard for more information.
GitHub Vulnerability Alerts
CVE-2020-27218
Impact
If GZIP request body inflation is enabled and requests from different clients are multiplexed onto a single connection and if an
attacker can send a request with a body that is received entirely by not consumed by the application, then a subsequent request
on the same connection will see that body prepended to it's body.
The attacker will not see any data, but may inject data into the body of the subsequent request
CVE score is 4.8 AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:L/A:L
Workarounds
The problem can be worked around by either:
Connection: close
to any response where the servlet does not fully consume request content.CVE-2020-27223
Impact
When Jetty handles a request containing request headers with a large number of “quality” (i.e. q) parameters (such as what are seen on the
Accept
,Accept-Encoding
, andAccept-Language
request headers), the server may enter a denial of service (DoS) state due to high CPU usage while sorting the list of values based on their quality values. A single request can easily consume minutes of CPU time before it is even dispatched to the application.The only features within Jetty that can trigger this behavior are:
Accept
request header with theQuotedQualityCSV
is used to determine what kind of content to send back to the client (html, text, json, xml, etc)StatisticsServlet
- uses theAccept
request header with theQuotedQualityCSV
to determine what kind of content to send back to the client (xml, json, text, html, etc)HttpServletRequest.getLocale()
- uses theAccept-Language
request header with theQuotedQualityCSV
to determine which “preferred” language is returned on this call.HttpservletRequest.getLocales()
- is similar to the above, but returns an ordered list of locales based on the quality values on theAccept-Language
request header.DefaultServlet
- uses theAccept-Encoding
request header with theQuotedQualityCSV
to determine which kind of pre-compressed content should be sent back for static content (content that is not matched against a url-pattern in your web app)Versions
QuotedQualityCSV
was introduced to Jetty 9.3.9.v20160517 and the bug that introduced the vulnerability was in 9.4.6.v20170531.Currently, known vulnerable versions include:
Workarounds
Quality ordered values are used infrequently by jetty so they can be avoided by:
StatisticsServlet
exposed to the networkgetLocale
APIDefaultServlet
Patches
All patches are available for download from the Eclipse Jetty website at https://www.eclipse.org/jetty/download.php
CVE-2019-10247
In Eclipse Jetty version 7.x, 8.x, 9.2.27 and older, 9.3.26 and older, and 9.4.16 and older, the server running on any OS and Jetty version combination will reveal the configured fully qualified directory base resource location on the output of the 404 error for not finding a Context that matches the requested path. The default server behavior on jetty-distribution and jetty-home will include at the end of the Handler tree a DefaultHandler, which is responsible for reporting this 404 error, it presents the various configured contexts as HTML for users to click through to. This produced HTML includes output that contains the configured fully qualified directory base resource location for each context.
CVE-2019-10246
In Eclipse Jetty version 9.2.27, 9.3.26, and 9.4.16, the server running on Windows is vulnerable to exposure of the fully qualified Base Resource directory name on Windows to a remote client when it is configured for showing a Listing of directory contents. This information reveal is restricted to only the content in the configured base resource directories.
CVE-2019-10241
In Eclipse Jetty version 9.2.26 and older, 9.3.25 and older, and 9.4.15 and older, the server is vulnerable to XSS conditions if a remote client USES a specially formatted URL against the DefaultServlet or ResourceHandler that is configured for showing a Listing of directory contents.
CVE-2021-34428
Impact
If an exception is thrown from the
SessionListener#sessionDestroyed()
method, then the session ID is not invalidated in the session ID manager. On deployments with clustered sessions and multiple contexts this can result in a session not being invalidated. This can result in an application used on a shared computer being left logged in.There is no known path for an attacker to induce such an exception to be thrown, thus they must rely on an application to throw such an exception. The OP has also identified that during the call to
sessionDestroyed
, thegetLastAccessedTime()
throws anIllegalStateException
, which potentially contrary to the servlet spec, so applications calling this method may always throw and fail to log out. If such an application was only tested on a non clustered test environment, then it may be deployed on a clustered environment with multiple contexts and fail to log out.Workarounds
The application should catch all Throwables within their
SessionListener#sessionDestroyed()
implementations.CVE-2023-26048
Impact
Servlets with multipart support (e.g. annotated with
@MultipartConfig
) that callHttpServletRequest.getParameter()
orHttpServletRequest.getParts()
may causeOutOfMemoryError
when the client sends a multipart request with a part that has a name but no filename and a very large content.This happens even with the default settings of
fileSizeThreshold=0
which should stream the whole part content to disk.An attacker client may send a large multipart request and cause the server to throw
OutOfMemoryError
.However, the server may be able to recover after the
OutOfMemoryError
and continue its service -- although it may take some time.A very large number of parts may cause the same problem.
Patches
Patched in Jetty versions
Workarounds
Multipart parameter
maxRequestSize
must be set to a non-negative value, so the whole multipart content is limited (although still read into memory).Limiting multipart parameter
maxFileSize
won't be enough because an attacker can send a large number of parts that summed up will cause memory issues.References
CVE-2023-26049
Nonstandard cookie parsing in Jetty may allow an attacker to smuggle cookies within other cookies, or otherwise perform unintended behavior by tampering with the cookie parsing mechanism.
If Jetty sees a cookie VALUE that starts with
"
(double quote), it will continue to read the cookie string until it sees a closing quote -- even if a semicolon is encountered.So, a cookie header such as:
DISPLAY_LANGUAGE="b; JSESSIONID=1337; c=d"
will be parsed as one cookie, with the nameDISPLAY_LANGUAGE
and a value ofb; JSESSIONID=1337; c=d
instead of 3 separate cookies.
Impact
This has security implications because if, say,
JSESSIONID
is anHttpOnly
cookie, and theDISPLAY_LANGUAGE
cookie value is rendered on the page, an attacker can smuggle theJSESSIONID
cookie into theDISPLAY_LANGUAGE
cookie and thereby exfiltrate it. This is significant when an intermediary is enacting some policy based on cookies, so a smuggled cookie can bypass that policy yet still be seen by the Jetty server.Patches
Workarounds
No workarounds
References
CVE-2021-28165
Impact
When using SSL/TLS with Jetty, either with HTTP/1.1, HTTP/2, or WebSocket, the server may receive an invalid large (greater than 17408) TLS frame that is incorrectly handled, causing CPU resources to eventually reach 100% usage.
Workarounds
The problem can be worked around by compiling the following class:
This class can be deployed by:
${jetty.home}/modules/ssl.mod
to${jetty.base}/modules
${jetty.base}/modules/ssl.mod
file to have the following section:${jetty.home}/etc/jetty-https.xml
and${jetty.home}/etc/jetty-http2.xml
to${jetty.base}/etc
${jetty.base}/etc/jetty-https.xml
and${jetty.base}/etc/jetty-http2.xml
, changing any reference oforg.eclipse.jetty.server.SslConnectionFactory
toorg.eclipse.jetty.server.ssl.fix6072.SpaceCheckingSslConnectionFactory
. For example:Configuration
📅 Schedule: Branch creation - "" (UTC), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate. View repository job log here.