-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Vert.x: fix NPE in ForwardedProxyHandler #36682
Conversation
The test `TrustedXForwarderProxiesUnknownHostnameFailureTest` sometimes fail in CI due to a NPE in `ForwardedProxyHandler`. This shows an actual bug: per the documentation, `io.vertx.core.dns.DnsClient.lookup()` may succeed with a `null` value when no record was found. The `ForwardedProxyHandler` ignores the possibility of a `null` result, which this commit fixes. We deal with a `null` result just like with a failure, because it's equivalent to a NXDOMAIN error.
See #36310 (comment) for motivation. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch, thanks
Huh, I didn't even bother checking if we have a report for this :-) Thanks @gsmet, added to the description. |
Yeah, I'm trying to improve the CI situation so fixing tests, disabling some and creating issues. I hope we will get in a better state soon. |
Failing Jobs - Building 985e78e
Full information is available in the Build summary check run. Failures⚙️ Maven Tests - JDK 11 Windows #- Failing: integration-tests/maven
📦 integration-tests/maven✖
✖
✖
✖
✖
✖
|
The test
TrustedXForwarderProxiesUnknownHostnameFailureTest
sometimes fail in CI due to a NPE inForwardedProxyHandler
. This shows an actual bug: per the documentation,io.vertx.core.dns.DnsClient.lookup()
may succeed with anull
value when no record was found. TheForwardedProxyHandler
ignores the possibility of anull
result, which this commit fixes. We deal with anull
result just like with a failure, because it's equivalent to a NXDOMAIN error.Fixes #36656