Using HttpModules to perform a SSL switch on web pages

A common requirement of any secure website is to make sure that when a user traverses to a "sensitive" part of the website such the login page, the password reset page or even the personal profile page which might contain contact detail you would want the user to be forced onto a HTTPS secured page….


HttpHandler to Authorize File Downloads – C# Code Sample

Its quite a common scenario to have a feature in a web site to check for the credentials of the user before allowing a particular download. For example, there might be some documents which should be visible only to a set of users and not to any others. This document might be anything – a…

Detecting Session Timeout in ASP.NET 2.0 Web Applications

Problem: An ASP.NET 2.0 web application needs to detect a session timeout condition so that the user can be redirected to a different page and / or an error message is displayed. Solution: There are three ways of approaching this problem, starting off with the simplest one to the most complicated one. So, here it…