Heap corruption in HttpCacheModule while you try to remove HTTP headers in your custom HTTP module.

Some users want to remove certain HTTP headers in IIS 7.0/7.5 to avoid divulging platform information through response headers.  They usually implement a custom HTTP module and remove the headers in  PreSendRequestHeaders notification.                   public void Init(HttpApplication app)        {            app.PreSendRequestHeaders += new EventHandler(this.PreSendRequestHeaders);        }        private void PreSendRequestHeaders(object sender, EventArgs e)        {            HttpContext.Current.Response.Headers.Remove(“Server”);            HttpContext.Current.Response.Headers.Remove(“X-AspNet-Version”);            HttpContext.Current.Response.Headers.Remove(“X-Powered-By”);       …

3

How to completely release WorkflowRuntime resource

In case you need to create multiple WF 3.5/3.0 WorkflowRuntime objects, you may find the memory usage of the workflow application keep rising (memory leak) although you have disposed the objects.   To completely release the resource of WorkflowRuntime, we need to call StopRuntime method before it is disposed. For example:                 using…

0