Index: modules/luni/src/main/java/java/net/Inet4Address.java =================================================================== --- modules/luni/src/main/java/java/net/Inet4Address.java (revision 546384) +++ modules/luni/src/main/java/java/net/Inet4Address.java (working copy) @@ -189,6 +189,17 @@ } /** + * Returns the IP address of this InetAddress as an array. + * The elements are in network order (the highest order address byte is in + * the zero-th element). + * + * @return byte[] the address as a byte array + */ + public byte[] getAddress() { + return super.getAddress(); + } + + /** * Returns a String representation of the IP address. * * @return Host address Index: modules/luni/src/main/java/java/net/Inet6Address.java =================================================================== --- modules/luni/src/main/java/java/net/Inet6Address.java (revision 546384) +++ modules/luni/src/main/java/java/net/Inet6Address.java (working copy) @@ -396,6 +396,17 @@ } /** + * Returns the IP address of this InetAddress as an array. + * The elements are in network order (the highest order address byte is in + * the zero-th element). + * + * @return byte[] the address as a byte array + */ + public byte[] getAddress() { + return super.getAddress(); + } + + /** * Returns the hashcode of the receiver. * * @return the hashcode