ASP. NET 4.0 event message: a verification error has occurred, and a potentially dangerous Request. Form value has been detected.

Source: Internet
Author: User

Event Type: Warning
Event Source: ASP. NET 4.0.30319.0
Event Type: Web events
Event ID: 1309
Date:
Event: 13:28:39
User: N/
COMPUTER: CNPOMO-T
Description:
Event code: 3003
Event message: a verification error has occurred.
Event Time: 13:28:39
Event Time (UTC): 5:28:39
Event ID: a4dab4bd3ebd4a9d932e6b4c403ef126
Event Sequence: 13
Event Match: 2
Event details code: 0
 
Application information:
Application domain:/LM/W3SVC/975604319/Root-2-129221764498437500
Trust level: Full
Application virtual path :/
Application Path: D: \ PP \ PP_Web \
Name: CNPOMO-T
 
Process Information:
Process ID 3164
Process name: w3wp.exe
Account name: nt authority \ NETWORK SERVICE
 
Exception information:
Exception type: HttpRequestValidationException
Exception message: from the client (ctl00 $ MainContent $ txbZW = "<cc> [\ s | \ S] +? </Cc> ") detected a potentially dangerous Request. Form value.
In System. Web. HttpRequest. ValidateString (String value, String collectionKey, RequestValidationSource requestCollection)
In System. Web. HttpRequest. ValidateNameValueCollection (NameValueCollection nvc, RequestValidationSource requestCollection)
In System. Web. HttpRequest. get_Form ()
In System. Web. HttpRequest. get_HasForm ()
In System. Web. UI. Page. GetCollectionBasedOnMethod (Boolean dontReturnNull)
In System. Web. UI. Page. DeterminePostBackMode ()
In System. Web. UI. Page. ProcessRequestMain (Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
In System. Web. UI. Page. ProcessRequest (Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
In System. Web. UI. Page. ProcessRequest ()
In System. Web. UI. Page. ProcessRequestWithNoAssert (HttpContext context)
In System. Web. UI. Page. ProcessRequest (HttpContext context)
In ASP. root_zztj_aspx.ProcessRequest (HttpContext context)
In System. Web. HttpApplication. CallHandlerExecutionStep. System. Web. HttpApplication. IExecutionStep. Execute ()
In System. Web. HttpApplication. ExecuteStep (IExecutionStep step, Boolean & completedSynchronously)

 
 
Request Information:
Request URL: http: // 192.168.0.183/Root/ZZTJ. aspx
Request Path:/Root/ZZTJ. aspx
User host address: 192.168.0.199
User:
Authenticated or not: False
Authentication Type:
Thread Account name: nt authority \ NETWORK SERVICE
 
Thread information:
Thread ID: 1
Thread Account name: nt authority \ NETWORK SERVICE
Simulated or not: False
Stack trace: In System. Web. HttpRequest. ValidateString (String value, String collectionKey, RequestValidationSource requestCollection)
In System. Web. HttpRequest. ValidateNameValueCollection (NameValueCollection nvc, RequestValidationSource requestCollection)
In System. Web. HttpRequest. get_Form ()
In System. Web. HttpRequest. get_HasForm ()
In System. Web. UI. Page. GetCollectionBasedOnMethod (Boolean dontReturnNull)
In System. Web. UI. Page. DeterminePostBackMode ()
In System. Web. UI. Page. ProcessRequestMain (Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
In System. Web. UI. Page. ProcessRequest (Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
In System. Web. UI. Page. ProcessRequest ()
In System. Web. UI. Page. ProcessRequestWithNoAssert (HttpContext context)
In System. Web. UI. Page. ProcessRequest (HttpContext context)
In ASP. root_zztj_aspx.ProcessRequest (HttpContext context)
In System. Web. HttpApplication. CallHandlerExecutionStep. System. Web. HttpApplication. IExecutionStep. Execute ()
In System. Web. HttpApplication. ExecuteStep (IExecutionStep step, Boolean & completedSynchronously)
 
 
Custom Event details:

For more information, see Help and Support Center in http://go.microsoft.com/fwlink/events.asp.

 

 

The ASP. NET Request verification feature provides protection against cross-site scripting (XSS) attacks. Earlier versions of ASP. NET are only executed on the ASP. NET page.

All requests are enabled for ASP. NET 4 request authentication because it is enabled before HTTP BeginRequest. Therefore, request authentication applies to all ASP. NET Resources, not just. aspx pages. Includes Web Services and custom HTTP processing programs.

To restore the ASP. NET Request verification feature to 2.0, SetAdd files in Web. config:

<HttpRuntime requestValidationMode = "2.0" type = "codeph" text = "/codeph"/>

Otherwise, it does not work even if validaterequest = "false" is added to the page code.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.