You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-commits@lucene.apache.org by ho...@apache.org on 2006/12/16 09:38:09 UTC
svn commit: r487773 - in /incubator/solr/trunk: CHANGES.txt
src/webapp/resources/admin/action.jsp src/webapp/resources/admin/analysis.jsp
Author: hossman
Date: Sat Dec 16 00:38:09 2006
New Revision: 487773
URL: http://svn.apache.org/viewvc?view=rev&rev=487773
Log:
SOLR-74 - user input wasn't being HTML escaped when echoed back on the page
Modified:
incubator/solr/trunk/CHANGES.txt
incubator/solr/trunk/src/webapp/resources/admin/action.jsp
incubator/solr/trunk/src/webapp/resources/admin/analysis.jsp
Modified: incubator/solr/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/incubator/solr/trunk/CHANGES.txt?view=diff&rev=487773&r1=487772&r2=487773
==============================================================================
--- incubator/solr/trunk/CHANGES.txt (original)
+++ incubator/solr/trunk/CHANGES.txt Sat Dec 16 00:38:09 2006
@@ -197,6 +197,8 @@
11. Better parsing of pingQuery from solrconfig.xml (hossman, SOLR-70)
12. Fixed bug with "Distribution" page introduced when Versions were
added to "Info" page (hossman)
+13. Fixed HTML escaping issues with user input to analysis.jsp and action.jsp
+ (hossman, SOLR-74)
Other Changes
1. Upgrade to Lucene 2.0 nightly build 2006-06-22, lucene SVN revision 416224,
Modified: incubator/solr/trunk/src/webapp/resources/admin/action.jsp
URL: http://svn.apache.org/viewvc/incubator/solr/trunk/src/webapp/resources/admin/action.jsp?view=diff&rev=487773&r1=487772&r2=487773
==============================================================================
--- incubator/solr/trunk/src/webapp/resources/admin/action.jsp (original)
+++ incubator/solr/trunk/src/webapp/resources/admin/action.jsp Sat Dec 16 00:38:09 2006
@@ -15,7 +15,7 @@
See the License for the specific language governing permissions and
limitations under the License.
--%>
-
+<%@ page import="org.apache.solr.util.XML"%>
<%@ page import="org.apache.solr.core.SolrCore,
org.apache.solr.schema.IndexSchema,
java.io.File,
@@ -98,7 +98,7 @@
<H3>Action:</H3>
</td>
<td>
- <%= action %><br>
+ <% XML.escapeCharData(action, out); %><br>
</td>
</tr>
<tr>
@@ -106,7 +106,7 @@
<H4>Result:</H4>
</td>
<td>
- <%= enableActionStatus %><br>
+ <% XML.escapeCharData(enableActionStatus, out); %><br>
</td>
</tr>
</table>
Modified: incubator/solr/trunk/src/webapp/resources/admin/analysis.jsp
URL: http://svn.apache.org/viewvc/incubator/solr/trunk/src/webapp/resources/admin/analysis.jsp?view=diff&rev=487773&r1=487772&r2=487773
==============================================================================
--- incubator/solr/trunk/src/webapp/resources/admin/analysis.jsp (original)
+++ incubator/solr/trunk/src/webapp/resources/admin/analysis.jsp Sat Dec 16 00:38:09 2006
@@ -62,7 +62,7 @@
<strong>Field name</strong>
</td>
<td>
- <input class="std" name="name" type="text" value="<%= name %>">
+ <input class="std" name="name" type="text" value="<% XML.escapeCharData(name, out); %>">
</td>
</tr>
<tr>
@@ -78,7 +78,7 @@
<%= highlight ? "checked=\"true\"" : "" %> >
</td>
<td>
- <textarea class="std" rows="3" cols="70" name="val"><%= val %></textarea>
+ <textarea class="std" rows="3" cols="70" name="val"><% XML.escapeCharData(val,out); %></textarea>
</td>
</tr>
<tr>
@@ -90,7 +90,7 @@
<%= qverbose ? "checked=\"true\"" : "" %> >
</td>
<td>
- <textarea class="std" rows="1" cols="70" name="qval"><%= qval %></textarea>
+ <textarea class="std" rows="1" cols="70" name="qval"><% XML.escapeCharData(qval,out); %></textarea>
</td>
</tr>
<tr>