Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. A potentially dangerous Request.QueryString value was detected from the client (ReturnUrl="...1111&#Write"). [modified]

A potentially dangerous Request.QueryString value was detected from the client (ReturnUrl="...1111&#Write"). [modified]

Scheduled Pinned Locked Moved C#
helpcomquestion
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    mimimimilaw
    wrote on last edited by
    #1

    i would like my application redirect after login. Url: http://mySite.com/Login.aspx?ReturnUrl=http%3A%2F%2FmySite.com%2Fpage.aspx%3F%26pid%3D1111%26%23Write But don't know why the application return a error: A potentially dangerous Request.QueryString value was detected from the client (ReturnUrl="...1111&#Write"). Could anyone help?

    modified on Thursday, October 9, 2008 5:12 AM

    G J 2 Replies Last reply
    0
    • M mimimimilaw

      i would like my application redirect after login. Url: http://mySite.com/Login.aspx?ReturnUrl=http%3A%2F%2FmySite.com%2Fpage.aspx%3F%26pid%3D1111%26%23Write But don't know why the application return a error: A potentially dangerous Request.QueryString value was detected from the client (ReturnUrl="...1111&#Write"). Could anyone help?

      modified on Thursday, October 9, 2008 5:12 AM

      G Offline
      G Offline
      Guffa
      wrote on last edited by
      #2

      I think that it's the http:// part of the data that it reacts on. Try to use a relative url instead of a fully qualified url. Otherwise you can turn of ValidateRequest in the @Page directive.

      Despite everything, the person most likely to be fooling you next is yourself.

      1 Reply Last reply
      0
      • M mimimimilaw

        i would like my application redirect after login. Url: http://mySite.com/Login.aspx?ReturnUrl=http%3A%2F%2FmySite.com%2Fpage.aspx%3F%26pid%3D1111%26%23Write But don't know why the application return a error: A potentially dangerous Request.QueryString value was detected from the client (ReturnUrl="...1111&#Write"). Could anyone help?

        modified on Thursday, October 9, 2008 5:12 AM

        J Offline
        J Offline
        JendaPerl
        wrote on last edited by
        #3

        Because some idiot thought it would be fun to make ASP.Net websites crash randomly. This ill-designed "protection" is causing more harm than good in each and every website where it's not turned off. And now it seems in ASP.Net MVC 2 it can't be turned off. I've already modified web.config and this idiotic message still appears. Hey dude, I ain't ever gonna include that value unescaped in the HTML, shut the heck up!

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups