PQ62047: UNKNOWNHOSTEXCEPTION WHEN CALLING GETREMOTEADDR() FOR A CLIENT IP ADDRESS THAT STARTS WITH A NUMBER > 127

 A fix may be available

Obtain the fix for this APAR



APAR status
Closed as program error.

Error description
When calling the method getRemoteAddr(), and the IP address of
the client starts with a number greater than 127 (for example,
164.5.6.7), the Web container incorrectly translates the
metadata sent by the control region.
Local fix Problem summary
****************************************************************
* USERS AFFECTED: Users of the Web container through the       *
*                 HTTP Transport Handler of the WebSphere      *
*                 Application Server Version V4.0.1 for z/OS   *
*                 and OS/390 may experience the problem.       *
****************************************************************
* PROBLEM DESCRIPTION: Exception UnknownHostException is       *
*                      encountered when method                 *
*                      request.getRemoteAddr() is invoked for  *
*                      an IP address that starts with a        *
*                      number greater than 127.                *
****************************************************************
* RECOMMENDATION:                                              *
****************************************************************
The method invocation request.getRemoteAddr() on the
javax.servlet.http.HttpServletRequest object produces the
following stack trace when the servlet is deployed on
z/OS or OS/390:

java.net.UnknownHostException: -92.xxx.xxx.xxx at
java.net.InetAddress.getAllByName0(InetAddress.java:591) at
java.net.InetAddress.getAllByName0(InetAddress.java:560) at
java.net.InetAddress.getByName(InetAddress.java:469) at
com.ibm.ws390.wc.httpcatcher.SocketAdapter.getInetAddress
  (SocketAdapter.java:65) at
com.ibm.ws.http.HttpConnection.getConnectionRemoteAddr
  (HttpConnection.java:86) at
com.ibm.servlet.engine.http11.HttpConnection.getRemoteAddr
  (HttpConnection.java:245) at
com.ibm.servlet.engine.srp.SRPConnection.getRemoteAddr
  (SRPConnection.java:311) at
com.ibm.servlet.engine.srt.SRTServletRequest.getRemoteAddr
  (SRTServletRequest.java:467) at
com.ibm.servlet.engine.webapp.HttpServletRequestProxy.
  getRemoteAddr(HttpServletRequestProxy.java:220) at
com.ibm.servlet.engine.webapp.HttpServletRequestProxy.
  getRemoteAddr(HttpServletRequestProxy.java:220)

The client IP address is 164.xxx.xxx.xxx.  The first byte of
the IP address is being interpreted as a signed byte by the
SocketAdapter.getInetAddress() method for the HTTP Transport
Handler code.

If the client IP address (remote address) first qualifier is
higher than 127 (7f in hex), then the HTTP Transport Handler
code that handles metadata sent by the control region is
incorrectly interpreting the high order bit as a sign bit.
This problem will also occur if the server IP address (local
address) first qualifier is higher than 127.
Problem conclusion
The code for the HTTP Transport Handler has been changed to read
the local and remote IP addresses in the metadata as four
unsigned bytes rather than as a signed integer.

This change affects COMPID 5655A9800 R401 for z/OS and OS/390.
The code changes are stored in CMVC under defect PQ62047.

401Y
EJSJWCSC
EJSJWCWC

* Cross Reference between External and Internal Names
Temporary fix Comments
APAR information
APAR number PQ62047
Reported component name WEBSPHERE OS/39
Reported component ID 5655A9800
Reported release 401
Status CLOSED PER
PE NoPE
HIPER NoHIPER
Submitted date 2002-06-07
Closed date 2002-07-31
Last modified date 2002-09-04

APAR is sysrouted FROM one or more of the following:

APAR is sysrouted TO one or more of the following:

Modules/Macros
EJSJWCSC EJSJWCWC        

Fix information
Fixed component name WEBSPHERE OS/39
Fixed component ID 5655A9800

Applicable component levels
R401 PSY UQ68592    UP02/08/03 P F208

  Fix is available
Select the PTF appropriate for your component level. You will be required to sign in. Distribution on physical media is not available in all countries.


Document Information


Product categories: Software > Application Servers > Distributed Application & Web Servers > WebSphere Application Server for z/OS
Operating system(s):
Software version: 401
Software edition:
Reference #: PQ62047
IBM Group: Software Group
Modified date: Sep 4, 2002