Skip to content
This repository was archived by the owner on Aug 17, 2018. It is now read-only.

Commit 0f9ed39

Browse files
committed
submit security fix for GF bug 24659612
svn path=/trunk/; revision=1489
1 parent e47b49c commit 0f9ed39

1 file changed

Lines changed: 0 additions & 54 deletions

File tree

impl/src/main/java/org/apache/jasper/runtime/JspRuntimeLibrary.java

Lines changed: 0 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -64,9 +64,6 @@
6464
import java.io.IOException;
6565
import java.io.OutputStreamWriter;
6666
import java.lang.reflect.Method;
67-
import java.security.AccessController;
68-
import java.security.PrivilegedActionException;
69-
import java.security.PrivilegedExceptionAction;
7067
import java.util.Enumeration;
7168

7269
import javax.servlet.RequestDispatcher;
@@ -78,7 +75,6 @@
7875
import javax.servlet.jsp.PageContext;
7976
import javax.servlet.jsp.tagext.BodyContent;
8077

81-
import org.apache.jasper.Constants;
8278
import org.apache.jasper.JasperException;
8379
import org.apache.jasper.compiler.Localizer;
8480

@@ -101,35 +97,6 @@ public class JspRuntimeLibrary {
10197
private static final String JSP_EXCEPTION
10298
= "javax.servlet.jsp.jspException";
10399

104-
protected static class PrivilegedIntrospectHelper
105-
implements PrivilegedExceptionAction<Object> {
106-
107-
private Object bean;
108-
private String prop;
109-
private String value;
110-
private ServletRequest request;
111-
private String param;
112-
private boolean ignoreMethodNF;
113-
114-
PrivilegedIntrospectHelper(Object bean, String prop,
115-
String value, ServletRequest request,
116-
String param, boolean ignoreMethodNF)
117-
{
118-
this.bean = bean;
119-
this.prop = prop;
120-
this.value = value;
121-
this.request = request;
122-
this.param = param;
123-
this.ignoreMethodNF = ignoreMethodNF;
124-
}
125-
126-
public Object run() throws JasperException {
127-
internalIntrospecthelper(
128-
bean,prop,value,request,param,ignoreMethodNF);
129-
return null;
130-
}
131-
}
132-
133100
/**
134101
* Returns the value of the javax.servlet.error.exception request
135102
* attribute value, if present, otherwise the value of the
@@ -339,27 +306,6 @@ public static void introspecthelper(Object bean, String prop,
339306
String value, ServletRequest request,
340307
String param, boolean ignoreMethodNF)
341308
throws JasperException
342-
{
343-
if (Constants.IS_SECURITY_ENABLED) {
344-
try {
345-
PrivilegedIntrospectHelper dp =
346-
new PrivilegedIntrospectHelper(
347-
bean,prop,value,request,param,ignoreMethodNF);
348-
AccessController.doPrivileged(dp);
349-
} catch( PrivilegedActionException pe) {
350-
Exception e = pe.getException();
351-
throw (JasperException)e;
352-
}
353-
} else {
354-
internalIntrospecthelper(
355-
bean,prop,value,request,param,ignoreMethodNF);
356-
}
357-
}
358-
359-
private static void internalIntrospecthelper(Object bean, String prop,
360-
String value, ServletRequest request,
361-
String param, boolean ignoreMethodNF)
362-
throws JasperException
363309
{
364310
Method method = null;
365311
Class type = null;

0 commit comments

Comments
 (0)