Details
-
Type:
Bug
-
Status:
Resolved
-
Priority:
Minor
-
Resolution: Not A Bug
-
Affects Version/s: 6.1.25, 6.1.26
-
Fix Version/s: None
-
Labels:
-
Environment:java version "1.6.0_26"
Java(TM) SE Runtime Environment (build 1.6.0_26-b03)
Java HotSpot(TM) Client VM (build 20.1-b02, mixed mode, sharing)
Linux Ubuntu 11.04
AMD Athon64 3200
-
Number of attachments :
Description
Jetty 6.1.26 throws java.lang.NumberFormatException when the URL contains the string "%..", eg. http://localhost:8080/example%..
Copy of stacktrace
java.lang.NumberFormatException
at org.mortbay.util.TypeUtil.parseInt(TypeUtil.java:380)
at org.mortbay.jetty.HttpURI.getDecodedPath(HttpURI.java:473)
at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:526)
at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:928)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:549)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)
Activity
| Field | Original Value | New Value |
|---|---|---|
| Assignee | Jan Bartel [ janb ] |
| Status | Open [ 1 ] | Resolved [ 5 ] |
| Resolution | Not A Bug [ 6 ] |
Hi Juan,
% is a special character to indicate encoding. It is always followed by 2 hex digits. If you want to have the % character itself, it itself must be encoded. Here's the relevant section from RFC2396:
If this does not address your issue, please reopen with an exact example url and explanation of where you think the problem is.
thanks
Jan