Bulb Flash:- Setting a Dangerous Cookie on the Browser!!

During a recent assignment we were trying to set an xml string in the browser cookie. The string actually being a security token had a combination of signatures and unicode characters which the browser did not seem to like too much:-)

So after we set the cookie,every time i would browse the solution i was greeted by a A potentially dangerous Request.Form value was detected from the client message and i couldn’t browse any further. Seems its .NETs way of making sure no one is trying to use malicious code to hack his way into your application..

If you are sure you want this cookie then make this change in your web.config and you will be fine!

<pages validateRequest="false" />


<httpRuntime  requestValidationMode="2.0"/>

Hope this bulb flash saves you some time and gray cells!!

Until Next time!


About Cennest
Cennest is the brainchild of a group of IT Professionals keen to try their hand in the world of IT Freelancing. After working in the corpora

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: