mirror of
https://github.com/apache/struts.git
synced 2026-08-07 07:37:20 +00:00
Merge pull request #729 from apache/fix/WW-5327-removes-duplicate
[WW-5327] Removes duplicated exclusion
This commit is contained in:
@@ -37,9 +37,7 @@
|
||||
java.lang.ProcessBuilder,
|
||||
java.lang.Thread,
|
||||
sun.misc.Unsafe,
|
||||
com.opensymphony.xwork2.ActionContext,
|
||||
com.opensymphony.xwork2.ognl.SecurityMemberAccess,
|
||||
com.opensymphony.xwork2.ognl.OgnlValueStack"/>
|
||||
com.opensymphony.xwork2.ActionContext"/>
|
||||
|
||||
<constant name="struts.devMode.excludedClasses"
|
||||
value="
|
||||
|
||||
@@ -879,10 +879,10 @@ public class OgnlUtilTest extends XWorkTestCase {
|
||||
assertEquals(123, foo.getALong());
|
||||
}
|
||||
|
||||
public void testBeanMapExpressions() throws OgnlException {
|
||||
public void testBeanMapExpressions() throws OgnlException, NoSuchMethodException {
|
||||
Foo foo = new Foo();
|
||||
ognlUtil.setExcludedClasses(
|
||||
"com.opensymphony.xwork2.ognl.SecurityMemberAccess"
|
||||
ognlUtil.setExcludedPackageNames(
|
||||
"com.opensymphony.xwork2.ognl."
|
||||
);
|
||||
|
||||
Map<String, Object> context = ognlUtil.createDefaultContext(foo);
|
||||
@@ -903,7 +903,7 @@ public class OgnlUtilTest extends XWorkTestCase {
|
||||
assertEquals(foo.getTitle(), expression);
|
||||
|
||||
SecurityMemberAccess sma = (SecurityMemberAccess) ((OgnlContext) context).getMemberAccess();
|
||||
assertTrue(sma.isClassExcluded(SecurityMemberAccess.class));
|
||||
assertFalse(sma.isAccessible(context, sma, sma.getClass().getDeclaredMethod("setExcludedClasses", Set.class), "excludedClasses"));
|
||||
}
|
||||
|
||||
public void testNullProperties() {
|
||||
|
||||
Reference in New Issue
Block a user