-
Bug
-
Resolution: Fixed
-
P4
-
1.3.0
-
None
-
beta
-
sparc
-
solaris_8
-
Verified
(See bugid 4379116.)
Currently, ObjectInputStream.resolveProxyClass always chooses to define a proxy class in the latest user defined loader (which is used to resolve the proxy interfaces, so it should be sufficient in most cases). If, however, (at least) one of the interfaces is both non-public and defined in a different loader, then the proxy class definition will fail (with an IllegalAccessError, I believe). This case should work, however, just like it can work for non-proxy cases ( except when there are non-public interfaces defined in different loaders, which would fail in the non-proxy case); ObjectInputStream.resolveProxyClass should detect this situation and choose the correct loader to define the proxy class in.
Currently, ObjectInputStream.resolveProxyClass always chooses to define a proxy class in the latest user defined loader (which is used to resolve the proxy interfaces, so it should be sufficient in most cases). If, however, (at least) one of the interfaces is both non-public and defined in a different loader, then the proxy class definition will fail (with an IllegalAccessError, I believe). This case should work, however, just like it can work for non-proxy cases ( except when there are non-public interfaces defined in different loaders, which would fail in the non-proxy case); ObjectInputStream.resolveProxyClass should detect this situation and choose the correct loader to define the proxy class in.
- relates to
-
JDK-4379116 MarshalInputStream.resolveProxyClass can fail for non-public interface cases
-
- Closed
-