Background

Tomcat defines, for internal use, a WAR URL similar to JAR URLs except it uses "*/" rather than "!/" to allow URLs for JARs nested in WARs without confusing the JREs handling of JAR URLs.

The use of "*" causes problems in some environments so we are considering alternatives.

Whatever is used needs to be valid in a URL. The relevant ABNF from RFC 3986 is:

absolute-path  = 1*( "/" segment )
pchar = unreserved / pct-encoded / sub-delims / ":" / "@"
unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"
sub-delims = "!" / "$" / "&" / "'" / "(" / ")"
               / "*" / "+" / "," / ";" / "="

Single character options

Exclude "*" as that is the option we are trying to replace.

Exclude "!" as it is used in JAR URLs.

Exclude "+" as it is used to encode space.

Exclude ";" as it is used to delimit path parameters and for file versions in VMS.

Exclude ALPHA, DIGIT, ".", "-", "_" as they are frequently used in file names.

The remaining options are:

":" / "@" /  "~" / "$" / "&" / "'" / "(" / ")" / "," / "="

Multiple character options

Use ".war/"

Alternatives

Make the single character configurable.

 

  • No labels