ASP.Net Response Filter Causing SharePoint 2010 "Unexpected Error"

Posted by Jason Weber on Stack Overflow See other posts from Stack Overflow or by Jason Weber
Published on 2010-03-19T02:20:06Z Indexed on 2010/03/19 2:21 UTC
Read the original article Hit count: 352

Hello everyone,

I'm debugging an HttpModule with an ASP.NET response filter. This dynamically rewrites portions of rendered SharePoint WCM pages. The publishing pages render fine in SP2007 on both Server 2003 and Server 2008. However the equivalent pages fail to render in SP2010 B2 on Server 2008 R2. The generic "An unexpected error has occurred message" page is displayed.

This error only happens when the response filter is applied to an .aspx page. Other page types, such as .css, render fine on this platform. This error also happens when the response filter does not modify the page at all (pure pass-through). This KB article seems very closely related: http://support.microsoft.com/kb/2014472. However, this same error occurs with caching disabled.

I see no related entries in any of the following: ULS for SP, Event Log, Failed Request Tracing (IIS7). Running under the debugger suggests that the custom code is not raising any exceptions. Any help or insight would be greatly appreciated.

© Stack Overflow or respective owner

Related posts about sharepoint2010

Related posts about iis7