changeset 8513:82c50cf87400

8181597: Process Proxy presentation Reviewed-by: dfuchs, ahgross, rhalade, skoivu
author igerasim
date Wed, 05 Jul 2017 13:21:08 -0700
parents 1de398ed4d75
children 827b23f9c231
files src/share/classes/java/io/ObjectInputStream.java
diffstat 1 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/classes/java/io/ObjectInputStream.java	Tue Nov 14 23:10:05 2017 +0000
+++ b/src/share/classes/java/io/ObjectInputStream.java	Wed Jul 05 13:21:08 2017 -0700
@@ -1744,6 +1744,10 @@
         passHandle = NULL_HANDLE;
 
         int numIfaces = bin.readInt();
+        if (numIfaces > 65535) {
+            throw new InvalidObjectException("interface limit exceeded: "
+                    + numIfaces);
+        }
         String[] ifaces = new String[numIfaces];
         for (int i = 0; i < numIfaces; i++) {
             ifaces[i] = bin.readUTF();