Recently we have done a internal asp.net application for your Regional IT. Every thing is working fine both in out Development Server and Production Server. But after we deployed into Client's server, we keep getting 406 Not Acceptable Error. After some comunications with their supporter. No helpful, They just complain that it is our application's problem. They said that they have a lot application that using WAF without any problems.
So we have to review our code. But can not find which page or function cause the error. The strange issue is: Some page works well with no problem, only serval pages got the error. It is very hard to identify the bugs.
Finally, we remove the out application from their server, and put in some testing pages. Then we find some funny results:
1. We dynamic load dummy data into a datagrid, if we load more than 100 records, WAF will throw 406 error. with less than 100 records, the page works fine.
2. we upload a static html file, which file size is around 1M, WAF throw 406 again.
So, Finnaly we came out a summary: if the pagesize reached some limit, the WAF will throw 406 Not Accept Error.... WTF..... This waste us a whole Sunday to Idenity the Problem.