Permalink
Browse files

comment, default to false

  • Loading branch information...
1 parent 7fd682c commit f9d39509da2d23cde949a2e2a4b7b9ecea3038fd @grobmeier committed Apr 3, 2012
Showing with 7 additions and 1 deletion.
  1. +7 −1 jjson-struts2/src/main/java/de/grobmeier/json/plugins/struts2/JsonResult.java
@@ -44,7 +44,7 @@
private boolean commentOutput = true;
- private boolean allowCrossSiteScripting = true;
+ private boolean allowCrossSiteScripting = false;
private String jsonResponse;
@@ -145,6 +145,12 @@ public void setJsonResponse(String response) {
this.jsonResponse = response;
}
+ /**
+ * Flag to disable cross site scripting headers (default = false). Enabling cross site scripting
+ * allows AJAX calls from clients which are not within the server domain.
+ *
+ * @param allowCrossSiteScripting true allows it, false disables it
+ */
public void setAllowCrossSiteScripting(boolean allowCrossSiteScripting) {
this.allowCrossSiteScripting = allowCrossSiteScripting;
}

0 comments on commit f9d3950

Please sign in to comment.