Commit Graph

17439 Commits

Author SHA1 Message Date
Simone Bordet 3ce87f717c Fixes #4201 - Throw SSLHandshakeException in case of TLS handshake failures.
Now rethrowing other exceptions as SSLHandshakeException
if they happen during the TLS handshake.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2019-10-15 16:44:30 +02:00
Simone Bordet 6b26ac9ee9 Fixes #4190 Jetty hangs after thread blocked in SharedBlockingCallback.block() called by HttpOutput.close.
Now releasing the buffer when in CLOSING state.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2019-10-15 15:47:03 +02:00
Simone Bordet 83185334e0
Merge pull request #4182 from eclipse/jetty-9.4.x-4142-RateControl
Issue #4142 - module config for http2 maxSettingsKeys and RateControl
2019-10-15 13:00:26 +02:00
Lachlan Roberts 5329ecf5be Issue #4142 - changes from review
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2019-10-15 21:56:54 +11:00
Simone Bordet a0e90bab96 Fixes #4190 Jetty hangs after thread blocked in SharedBlockingCallback.block() called by HttpOutput.close.
Now handling correctly the CLOSING case in HttpOutput.close().

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2019-10-15 12:45:10 +02:00
Lachlan Roberts 4f640387f2 Issue #4142 - changes from review
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2019-10-15 21:09:01 +11:00
Lachlan Roberts 709e05a19f Issue #4142 - changes from review
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2019-10-15 19:08:45 +11:00
Lachlan Roberts 5ff79b0bf1 Issue #4142 - changes from review
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2019-10-15 11:23:53 +11:00
contextshuffling 320e848c57 Fixes #4195: making test assertion more stable (#4196)
Signed-off-by: contextshuffling <contextshuffling@gmail.com>
2019-10-15 07:54:09 +11:00
Joakim Erdfelt 0fbb507841
Issue #4191 - GzipHandler.minGzipSize cannot be lower then 23.
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2019-10-14 13:21:01 -05:00
Greg Wilkins f09e03c586
Issue #4156 - Session Already in Cache during forwarding (#4159)
* Issue #4156 - Adding test to replicate issue

Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>

* Issue #4156 Session already in cache

+ check validity of sessions in getSession(SessionHandler)
+ do not replace session in doScope if SessionHandler is the same.

Signed-off-by: Greg Wilkins <gregw@webtide.com>
2019-10-14 11:18:37 +11:00
Lachlan Roberts a96fb176f6 Issue #4142 - module config for http2 maxSettingsKeys and RateControl
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2019-10-11 11:24:48 +11:00
Simone Bordet ec56739d3c
Merge pull request #4180 from eclipse/jetty-9.4.x-4179-SendCallback-gc
Issue #4179 SendCallback GC
2019-10-10 12:45:30 +02:00
Simone Bordet cd57af4caf
Merge pull request #4116 from eclipse/jetty-9.4.x-4115-drop_http2_pseudo_headers
Fixes #4115 - Drop HTTP/2 pseudo headers.
2019-10-10 12:15:58 +02:00
Simone Bordet 687873cb7b Issue #4115 - Drop HTTP/2 pseudo headers.
Fixed NPE if the method was missing.
Renamed lowCase -> lowerCase.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2019-10-10 11:11:36 +02:00
Simone Bordet cf687457e7 Issue #4177 - Configure HTTP proxy with SslContextFactory.
Small fixes after merge.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2019-10-10 10:41:42 +02:00
Greg Wilkins ce41c122a6
Issue #4176 setHeader after sendError (#4181)
* Issue #4176 setHeader after sendError

SendError now makes the response immutable for headers and status.

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Issue #4176 setHeader after sendError

cleanup after review
better names

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Issue #4176 setHeader after sendError

better name

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Issue #4176 setHeader after sendError

even better name

Signed-off-by: Greg Wilkins <gregw@webtide.com>
2019-10-10 19:35:28 +11:00
Simone Bordet 53ed8f346c
Merge pull request #4178 from eclipse/jetty-9.4.x-4177-http_proxy_sslcontextfactory
Fixes #4177 - Configure HTTP proxy with SslContextFactory.
2019-10-10 10:02:48 +02:00
Simone Bordet a73568df28 Fixes #4177 - Configure HTTP proxy with SslContextFactory.
Updates after review.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2019-10-10 10:00:17 +02:00
Lachlan 00baa7147e
Merge pull request #4153 from eclipse/jetty-9.4.x-3558-websocket_onErrorAfterClose
Issue #3558 - only notify WS onError if onClose has not been called
2019-10-10 15:27:11 +11:00
Greg Wilkins faac5d7f04 Issue #4179 SendCallback GC
The HttpConnection.SendCallback nulls it's reference to buffers and callbacks after completion to assist with easy GC, since the connection callback is a long lived instance.

Signed-off-by: Greg Wilkins <gregw@webtide.com>
2019-10-10 09:09:53 +11:00
Simone Bordet 6acc9f7be5 Issue #4115 - Drop HTTP/2 pseudo headers.
Updates after review.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2019-10-09 21:01:30 +02:00
Simone Bordet c8175ec107 Fixes #4177 - Configure HTTP proxy with SslContextFactory.
It is now possible to pass a `SslContextFactory.Client` to HttpProxy
so that it is possible to use a keystore for the proxy communication
and another keystore for the server communication.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2019-10-09 17:37:00 +02:00
Simone Bordet b48873f33b Issue #4170 - Client-side alias selection based on SSLEngine.
Cosmetics.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2019-10-09 10:23:22 +02:00
Simone Bordet 0fc5ec9d18
Merge pull request #4171 from eclipse/jetty-9.4.x-4170-client_side_alias_selection
Fixes #4170 - Client-side alias selection based on SSLEngine.
2019-10-09 09:30:37 +02:00
Greg Wilkins 0bd71a4359
Pathwatcher Concurrent modification #4174 (#4175)
There is a race between the doStop clearing the key map and the watching thread
checking isRunning before iterating over the key map.

While more sophisticated approaches could be used, I think that is best to defer
until this class is reworked entirely.  For now just using a ConcurrentHashMap will
avoid the exception and the closing of the pathwatcher will prevent watching forever.

Signed-off-by: Greg Wilkins <gregw@webtide.com>
2019-10-09 13:58:16 +11:00
Greg Wilkins 31a0180133 Improve debug logging of gzip inflation
Signed-off-by: Greg Wilkins <gregw@webtide.com>
2019-10-09 11:51:13 +11:00
Greg Wilkins 8087e29211 Reverted getSession(id) to public
This method is used by third party session handlers.
Reverts change made as part of #3913

Signed-off-by: Greg Wilkins <gregw@webtide.com>
2019-10-09 11:46:43 +11:00
Chris Walker 3328a28f09
Added instructions for a shaded start.jar maven dependency. Resolves #2407 2019-10-08 15:21:59 -04:00
Simone Bordet 742f564332 Fixes #4170 - Client-side alias selection based on SSLEngine.
Fixed setting of host/port in AbstractConnectorHttpClientTransport
and HttpProxy so that the creation of SSLEngine can use the proper
host/port pair, and can be subsequently used in TLS components.

Introduced SslContextFactory X509ExtendedKeyManagerWrapper and
X509ExtendedTrustManagerWrapper as utility classes used internally
and in tests.

The test case for this issue required 3 keystores, so other test
classes have been refactored to use the new keystores.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2019-10-08 18:32:23 +02:00
Simone Bordet 7164171674 Issue #2429 - Review HttpClient backpressure semantic.
Restored tests that were commented out.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2019-10-08 09:54:41 +02:00
Greg Wilkins 1c5a53a512 test async gzip close
Signed-off-by: Greg Wilkins <gregw@webtide.com>
2019-10-08 18:14:17 +11:00
Simone Bordet f68ed50405
Merge pull request #4106 from eclipse/jetty-9.4.x-2429-httpclient_backpressure
Issue #2429 - Review HttpClient backpressure semantic.
2019-10-08 09:10:51 +02:00
Lachlan 0403f0bc85
Merge pull request #4133 from travisspencer/feature-4132
Issue #4132 - Allow token and authorization endpoints to be configured
2019-10-08 13:46:21 +11:00
Travis Spencer 1d5ceee267 Issue #4132 Allow token and authorization endpoints to be configured
Signed-off-by: Travis Spencer <travis@curity.io>
2019-10-08 01:04:34 +02:00
Simone Bordet a4603c4237 Issue #2429 - Review HttpClient backpressure semantic.
Updated after review.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2019-10-08 00:52:11 +02:00
Lachlan 6e698df4d3
Merge pull request #4135 from travisspencer/4134-fix-aud
Issue #4134 - Validate audience (aud) claim as list or string, not just string
2019-10-08 09:28:22 +11:00
Lachlan acf4eeff65
Merge pull request #4129 from travisspencer/fix-4128
Issue #4128 - Add missing padding and use URL decoder
2019-10-08 09:17:12 +11:00
Travis Spencer 1c6202658e Validate aud claim as list or string, not just string
Signed-off-by: Travis Spencer <travis@curity.io>
2019-10-06 18:00:32 +02:00
Travis Spencer 8b37a8f7fe Issue #4128 - Add missing padding and use URL decoder
Signed-off-by: Travis Spencer <travis@curity.io>
2019-10-05 18:06:26 +02:00
Jesse Wilson d4270d9e97 Better advice for skipping tests in README.md (#4157)
This causes test artifacts to be built even though tests are not run.

Signed-off-by: Jesse Wilson <jwilson@squareup.com>
2019-10-05 08:32:16 +10:00
Lachlan Roberts d95c825c5c Issue #3558 - only notify WS onError if onClose has not been called
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2019-10-04 11:13:38 +10:00
Simone Bordet ef05f730e6 Issue #4115 - Drop HTTP/2 pseudo headers.
Added Javadocs.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2019-10-03 16:58:16 +02:00
Simone Bordet 3be178c966 Merged 'jetty-9.4.x' into 'jetty-9.4.x-2429-httpclient_backpressure'. 2019-10-03 13:17:39 +02:00
Simone Bordet 609c144ae0 Fixes #4115 - Drop HTTP/2 pseudo headers.
Invalid HTTP/2 headers are now causing an error rather than being ignored.

HTTP2Flusher now catches HpackException.StreamException and generates a
RST_STREAM frame, rather than just closing the connection.

Modified HpackEncoder to throw HpackException in case of encoding failure.
Introduced HpackEncoder.validateEncoding (defaults true) so validation of
the headers can be disabled (useful for tests).

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2019-10-03 12:45:55 +02:00
Joakim Erdfelt c19d33dc59
Merge pull request #4149 from eclipse/jetty-9.4.x-4121-qtp-threadfactory
Issue #4121 - ThreadFactory support in QTP
2019-10-02 14:43:08 -05:00
Joakim Erdfelt ed9031bd30
Merge pull request #4143 from eclipse/jetty-9.4.x-4141-classcastexception-request-async
Fixes #4141 - Servlet not async + async Filter + wrapped request
2019-10-02 13:49:21 -05:00
Joakim Erdfelt b121ba786b
Issue #4121 - Tests for ThreadFactory support in QTP
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2019-10-02 13:37:22 -05:00
Joakim Erdfelt b82b337e8e
Merge branch 'jetty-9.4.x' into jetty-9.4.x-4121-qtp-threadfactory 2019-10-02 12:55:25 -05:00
Simone Bordet 2f06976e41 Fixed flaky test and code cleanup.
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2019-10-02 17:06:45 +02:00