Hi Folks!
I need some help with this one. I'm running an older, legacy type web app (forum) that can't really be updated and, worse then that, I'm not very good with things like this (oh-no!). On the more positive side, I think I can provide all the info required to hopefully make this an easy question for someone knowledgeable...
Since installing a recommdended .NET update I had been getting 'URL too long errors' in the event viewer. I solved that by adding this line to the web.config file;
<httpRuntime maxUrlLength="2048" />
<pages validateRequest="false" />
That issue seems to have gone away. However, I now see a new issue that I can replicate quite easily. In the event viewer I now see this error;
A potentially dangerous Request.Path value was detected from the client (:).
The URL that causes this error to occur is this;
http://www.cbr125world.com/forums/index.php?showtopic=8726&st=0&pid=39963&#entry39963
Can anyone tell me what the magic line is that I need to add to the web.config file to prevent this error from occurring, or, I guess, to allow IIS 7.5 to accept a URL with ampersands and #'s in it? I'm assuming that's the underlying cause as many other people have reported similar errors caused by these characters in the URL on the Internet.
Someone mentioned in another post on this site that you can add a line like this to strip colons from the invlaid characters list (which appears to be the issue other then I'm not using colons!)
<httpRuntime requestValidationMode="2.0" requestPathInvalidCharacters="<,>,*,%,&,\" />
Does anyone know how to create the same type of thing taking into account my URL ? I'm guessing that;
http://www.cbr125world.com/forums/index.php?showtopic=8726&st=0&pid=39963&#entry39963
the issue is probably caused by the & and the # symbol, or perhaps the ? in the URL.
What is interesting is that I am noticing on these particular URL's that they take roughly 2.5 seconds for the server to process which is really, really high. This is a very fast network with nearly zero traffic and everything is instant, until you click on a link with one of those URL's and then the server coughs up an error in the event viewer (A potentially dangerous Request.Path value was detected from the client (:).) and finally spits out the request.
Any help would be appreciated! This is NOT my specialty but it would be great to resolve this issue and hopefully address the sluggishness in page display time when somone clicks an link that uses that kind of URL.
Rovastar, if possible, please let someone else respond to this one. I'm not sure you understand the issue but appreciate your previous help!