浏览代码

jfinal 3.6

James 7 年之前
父节点
当前提交
deed2c5861
共有 1 个文件被更改,包括 3 次插入2 次删除
  1. 3 2
      src/main/java/com/jfinal/template/expr/ast/MethodKit.java

+ 3 - 2
src/main/java/com/jfinal/template/expr/ast/MethodKit.java

@@ -48,7 +48,8 @@ public class MethodKit {
 		Class<?>[] cs = {
 		Class<?>[] cs = {
 			System.class, Runtime.class, Thread.class, Class.class, ClassLoader.class, File.class,
 			System.class, Runtime.class, Thread.class, Class.class, ClassLoader.class, File.class,
 			Compiler.class, InheritableThreadLocal.class, Package.class, Process.class,
 			Compiler.class, InheritableThreadLocal.class, Package.class, Process.class,
-			RuntimePermission.class, SecurityManager.class, ThreadGroup.class, ThreadLocal.class
+			RuntimePermission.class, SecurityManager.class, ThreadGroup.class, ThreadLocal.class,
+			java.lang.reflect.Method.class
 		};
 		};
 		for (Class<?> c : cs) {
 		for (Class<?> c : cs) {
 			forbiddenClasses.add(c);
 			forbiddenClasses.add(c);
@@ -59,7 +60,7 @@ public class MethodKit {
 	static {
 	static {
 		String[] ms = {
 		String[] ms = {
 			"getClass", "getDeclaringClass", "forName", "newInstance", "getClassLoader",
 			"getClass", "getDeclaringClass", "forName", "newInstance", "getClassLoader",
-			"getMethod", "getMethods", "getField", "getFields",
+			"getMethod", "getMethods", "invoke", // "getField", "getFields",
 			"notify", "notifyAll", "wait",
 			"notify", "notifyAll", "wait",
 			"load", "exit", "loadLibrary", "halt",
 			"load", "exit", "loadLibrary", "halt",
 			"stop", "suspend", "resume", "setDaemon", "setPriority",
 			"stop", "suspend", "resume", "setDaemon", "setPriority",