[jboss-cvs] JBossAS SVN: r96467 - in projects/javaee/trunk/jboss-servlet-api/src/main/javax/servlet: annotation and 1 other directories.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Tue Nov 17 14:23:43 EST 2009
Author: remy.maucherat at jboss.com
Date: 2009-11-17 14:23:42 -0500 (Tue, 17 Nov 2009)
New Revision: 96467
Modified:
projects/javaee/trunk/jboss-servlet-api/src/main/javax/servlet/AsyncContext.java
projects/javaee/trunk/jboss-servlet-api/src/main/javax/servlet/annotation/WebServlet.java
projects/javaee/trunk/jboss-servlet-api/src/main/javax/servlet/http/Cookie.java
Log:
- Spec update.
Modified: projects/javaee/trunk/jboss-servlet-api/src/main/javax/servlet/AsyncContext.java
===================================================================
--- projects/javaee/trunk/jboss-servlet-api/src/main/javax/servlet/AsyncContext.java 2009-11-17 18:34:09 UTC (rev 96466)
+++ projects/javaee/trunk/jboss-servlet-api/src/main/javax/servlet/AsyncContext.java 2009-11-17 19:23:42 UTC (rev 96467)
@@ -341,8 +341,9 @@
/**
- * Causes the container to dispatch a thread to run the specified Runnable
- * in the {@link ServletContext} that initialized this AsyncContext.
+ * Causes the container to dispatch a thread, possibly from a managed
+ * thread pool, to run the specified <tt>Runnable</tt>. The container may
+ * propagate appropriate contextual information to the <tt>Runnable</tt>.
*
* @param run the asynchronous handler
*/
Modified: projects/javaee/trunk/jboss-servlet-api/src/main/javax/servlet/annotation/WebServlet.java
===================================================================
--- projects/javaee/trunk/jboss-servlet-api/src/main/javax/servlet/annotation/WebServlet.java 2009-11-17 18:34:09 UTC (rev 96466)
+++ projects/javaee/trunk/jboss-servlet-api/src/main/javax/servlet/annotation/WebServlet.java 2009-11-17 19:23:42 UTC (rev 96467)
@@ -109,7 +109,7 @@
String description() default "";
/**
- * * The display name of the filter
+ * The display name of the servlet
*/
String displayName() default "";
Modified: projects/javaee/trunk/jboss-servlet-api/src/main/javax/servlet/http/Cookie.java
===================================================================
--- projects/javaee/trunk/jboss-servlet-api/src/main/javax/servlet/http/Cookie.java 2009-11-17 18:34:09 UTC (rev 96466)
+++ projects/javaee/trunk/jboss-servlet-api/src/main/javax/servlet/http/Cookie.java 2009-11-17 19:23:42 UTC (rev 96467)
@@ -96,25 +96,25 @@
*/
public class Cookie implements Cloneable, Serializable {
- private static final long serialVersionUID = 4014436410614806011L;
+ private static final long serialVersionUID = -6454587001725327448L;
- public static final boolean STRICT =
- Boolean.valueOf(System.getProperty("Cookie.STRICT", "false")).booleanValue();
+ private static final String TSPECIALS;
- private static final String tspecials;
- static {
- if (STRICT) {
- tspecials = "/()<>@,;:\\\"[]?={} \t";
- } else {
- tspecials = ",; ";
- }
- }
-
private static final String LSTRING_FILE =
"javax.servlet.http.LocalStrings";
private static ResourceBundle lStrings =
ResourceBundle.getBundle(LSTRING_FILE);
+
+ static {
+ if (Boolean.valueOf(System.getProperty(
+ "org.glassfish.web.rfc2109_cookie_names_enforced",
+ "true")).booleanValue()) {
+ TSPECIALS = "/()<>@,;:\\\"[]?={} \t";
+ } else {
+ TSPECIALS = ",; ";
+ }
+ }
//
// The value of the cookie itself.
@@ -139,11 +139,13 @@
/**
* Constructs a cookie with the specified name and value.
*
- * <p>The name must conform to RFC 2109. That means it can contain
- * only ASCII alphanumeric characters and cannot contain commas,
- * semicolons, or white space or begin with a $ character. The cookie's
- * name cannot be changed after creation.
+ * <p>The name must conform to RFC 2109. However, vendors may
+ * provide a configuration option that allows cookie names conforming
+ * to the original Netscape Cookie Specification to be accepted.
*
+ * <p>The name of a cookie cannot be changed once the cookie has
+ * been created.
+ *
* <p>The value can be anything the server chooses to send. Its
* value is probably of interest only to the server. The cookie's
* value can be changed after creation with the
@@ -446,7 +448,7 @@
int len = value.length();
for (int i = 0; i < len; i++) {
char c = value.charAt(i);
- if (c < 0x20 || c >= 0x7f || tspecials.indexOf(c) != -1) {
+ if (c < 0x20 || c >= 0x7f || TSPECIALS.indexOf(c) != -1) {
return false;
}
}
More information about the jboss-cvs-commits
mailing list