[Mono-aspnet-list] Error parsing Request Headers in FastCGI

Jesse Pasichnyk jesse at pasichnyk.net
Wed Jul 21 16:36:16 EDT 2010



Hi, 

I am running a mono based service (single .ashx) and from time to
time the request errors when it try to read the request headers. The error
seems to be a string manipulation error at the fastcgi level (lighttpd +
fastcgi). 

System.ArgumentOutOfRangeException: startIndex + length >
this.lengthParameter name: length at System.String.Substring (Int32
startIndex, Int32 length) [0x00000] in :0 at
Mono.WebServer.FastCgi.WorkerRequest.ReformatHttpHeader (System.String
header) [0x00000] in :0 at
Mono.WebServer.FastCgi.WorkerRequest.GetUnknownRequestHeaders () [0x00000]
in :0 at Mono.WebServer.FastCgi.WorkerRequest.GetKnownRequestHeader (Int32
index) [0x00000] in :0 at System.Web.HeadersCollection.InsertInfo ()
[0x00000] in :0 at System.Web.BaseParamsCollection.LoadInfo () [0x00000] in
:0 at System.Web.BaseParamsCollection.GetEnumerator  

Is there a known bug
there? 99.x% of the requests come through just fine, it must just be
clients with malformed headers (broken clients, or clients trying to cause
issues...) that are erroring. I'd think that the fastcgi layer in this case
would still return what headers are valid, and disregard anything else.


I'm using Mono 2.6.4. 

Thanks, 

Jesse
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-aspnet-list/attachments/20100721/0b5ed8b6/attachment.html 


More information about the Mono-aspnet-list mailing list