On rare occasions you may receive the following error when starting an Asp.Net site under IIS:
Request for the permission of type 'System.Web.AspNetHostingPermission, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.
This error may occur in particular when running the application domain of the site under a custom user.
This problem is caused by insufficient rights for the user that is configured on the application pool. This problem may be resolved by logging in on Windows with the user that is used for the application pool. When you log in on Windows for the first time, a security profile is created which is required by Asp.Net.