My Oracle Support Banner

Ip Address In Sys_context('Userenv','Ip_address') Has Leading Zeroes Removed 10.1.0.5 (Doc ID 370297.1)

Last updated on MARCH 06, 2019

Applies to:

Operating System Dependent Interface - Version 10.1.0.5 to 10.2.0.3.1
IBM z/OS on System z
IBM z/OS (OS/390)
Listener Service joblog on zOS


Symptoms

SELECT SYS_CONTEXT('USERENV','IP_ADDRESS') FROM DUAL;

In previous releases the IP address contained zeros. After upgrade from
10.1.0.3 to 10.1.0.5 the zeros are truncated. So it gives the correct IP-Adress now.

The 10.1.0.5 net log shows the zeroes included.

JOBLOG from Netservice  (same in 10.1.* , 10.2.* , 9.2.*) :
--------------------------------------------------------------
MIN0733I Socket 0000 connected Subtask Kid1, IP xxx.xxx.xxx.073
MIN0742I Socket 0000 closed Subtask Kid1, IP xxx.xxx.xxx.073
-----> Ip addresses are not displayed correctly . The correct IP-Address would be xxx.xxx.xxx.73

SYS_CONTEXT('USERENV','IP_ADDRESS')
------------------------------------------------------
Connect to 10.1.0.5 :
SYS_CONTEXT('USERENV','IP_ADDRESS')
xxx.xxx.xxx.73    ----> this the correct decimal address
SQL> Disconnected from Oracle Database 10g Enterprise Edition Release 10.1.0.5.2

SQL> Connected. (to 10.1.0.3)
SQL>
SYS_CONTEXT('USERENV','IP_ADDRESS')
xxx.xxx.xxx.073     ----->  this is NOT  correct decimal address - correct is would be xxx.xxx.xxx.73
.

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Cause
Solution
References

My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.