Bug 63570 - NioEndpoint.populateLocalAddr() populates remote address
Summary: NioEndpoint.populateLocalAddr() populates remote address
Status: RESOLVED FIXED
Alias: None
Product: Tomcat 9
Classification: Unclassified
Component: Util (show other bugs)
Version: 9.0.22
Hardware: PC Linux
: P2 regression (vote)
Target Milestone: -----
Assignee: Tomcat Developers Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-07-17 20:04 UTC by Aditya K
Modified: 2019-07-18 13:37 UTC (History)
0 users



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Aditya K 2019-07-17 20:04:12 UTC
package org.apache.tomcat.util.net
class NioEndpoint
commit 65fb1ee548111021edde247f3b3c409ec95a5183
https://github.com/apache/tomcat/commit/65fb1ee548111021edde247f3b3c409ec95a5183#diff-0d8883b1aa000d427e4af3fa79f61483

Steps to reproduce:
The behavior-change/regression is evident by looking at diff above. Still if steps are required, let me know. Also, make sure that local and remote address are different while trying to reproduce E.g. Running as localhost, local and remote addresses may be same which would mask the problem.

Actual Results:
Now NioEndpoint.populateLocalAddr populates the remote address. Thus, APIs to return server's local address for e.g. RequestFacade.getLocalAddress will return the remote address.

Expected Results:
NioEndpoint.populateLocalAddr populates the local address.

Build Date & Hardware:
First encountered the bug on 7/15/19, Intel Xeon, Ubuntu 16.04 LTS, Tomcat 9.0.22.
Comment 1 Remy Maucherat 2019-07-17 22:13:54 UTC
Sorry for the trouble, the fix will be in Tomcat 9.0.23.
Comment 2 Aditya K 2019-07-18 13:37:57 UTC
(In reply to Remy Maucherat from comment #1)
> Sorry for the trouble, the fix will be in Tomcat 9.0.23.

Thank you.