<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.iis.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:cs="http://blogs.iis.net/"><channel><title>Won Yoo&amp;#39;s Blog : ASP.NET</title><link>http://blogs.iis.net/wonyoo/archive/tags/ASP.NET/default.aspx</link><description>Tags: ASP.NET</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP1 (Build: 20510.895)</generator><item><title>Workaround: Running ASP.NET 1.1 on Vista SP2/WS08 SP2</title><link>http://blogs.iis.net/wonyoo/archive/2009/06/18/workaround-running-asp-net-1-1-on-vista-sp2-ws08-sp2.aspx</link><pubDate>Thu, 18 Jun 2009 22:01:00 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:3243800</guid><dc:creator>wonyoo</dc:creator><slash:comments>7</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://blogs.iis.net/wonyoo/rsscomments.aspx?PostID=3243800</wfw:commentRss><comments>http://blogs.iis.net/wonyoo/archive/2009/06/18/workaround-running-asp-net-1-1-on-vista-sp2-ws08-sp2.aspx#comments</comments><description>&lt;P mce_keep="true"&gt;Many of you have probably read the article on how to install ASP.NET 1.1 on IIS7 on Vista and WS08 (The article can be found at &lt;A href="http://learn.iis.net/page.aspx/472/how-to-install-aspnet-11-with-iis7-on-vista-and-windows-2008/" mce_href="http://learn.iis.net/page.aspx/472/how-to-install-aspnet-11-with-iis7-on-vista-and-windows-2008/"&gt;http://learn.iis.net/page.aspx/472/how-to-install-aspnet-11-with-iis7-on-vista-and-windows-2008/&lt;/A&gt;).&lt;/P&gt;
&lt;P mce_keep="true"&gt;While above works great on Vista/Vista SP1/WS08 RTM, if you try to run ASP.NET 1.1 on &lt;STRONG&gt;Vista SP2/WS08 SP2&lt;/STRONG&gt;, you&amp;nbsp;may have experienced the following error if you are on a &lt;STRONG&gt;64-bit OS&lt;/STRONG&gt;:&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;There was an error while performing this operation.&lt;/P&gt;
&lt;P&gt;Details:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;Filename:&lt;BR&gt;\\?\C:\Windows\system32\inetsrv\config\applicationHost.config&lt;BR&gt;Error:&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&lt;U&gt;Here is the problem.&lt;/U&gt;&lt;/P&gt;
&lt;P&gt;In order to support .NET 4.0 Framework, IIS team has released a hotfix (&lt;A href="http://support.microsoft.com/kb/958854" mce_href="http://support.microsoft.com/kb/958854"&gt;http://support.microsoft.com/kb/958854&lt;/A&gt;) which is also included in SP2.&amp;nbsp; At the root of the problem is that this hotfix allows the IIS runtime to read the correct version of .NET Framework configuration based on the .NET Framework version that is associated with the application pool.&amp;nbsp; For example:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;.NET Framework version 1.1: the config location is %windir%\Microsoft.NET\Framework\v1.1.4322\CONFIG&lt;/LI&gt;
&lt;LI&gt;.NET Framework version 2.0: the config location is %windir%\Microsoft.NET\Framework\v2.0.50727\CONFIG&lt;/LI&gt;
&lt;LI&gt;.NET Framework version 4.0: the config location is %windir%\Microsoft.NET\Framework\v4.0.nnnnn\CONFIG&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;The problem is that when the runtime tries to load the corresponding configuration, it doesn't take the bitness of the application pool into the consideration.&amp;nbsp; As you know, ASP.NET 1.1 is only supported on 32-bit.&amp;nbsp; So if you have a 64-bit OS, in order to run ASP.NET 1.1, you have to enable 32-bit applications in the application pool.&amp;nbsp; So, with the QFE/SP2 on 64-bit OS (and only on 64-bit OS), the runtime is incorrectly looking for the 1.1 version of the configuration under Framework64, which does not exist.&lt;/P&gt;
&lt;P&gt;&lt;U&gt;Workaround:&lt;/U&gt;&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;&lt;STRONG&gt;Create the Framework64 directory for 1.1&lt;/STRONG&gt;&lt;BR&gt;md \windows\microsoft.net\framework64\v1.1.4322\config\&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;Copy the 32bit config to 64bit config location created in step 1.&lt;/STRONG&gt;&lt;BR&gt;copy \windows\microsoft.net\framework\v1.1.4322\config\machine.config \windows\microsoft.net\framework64\v1.1.4322\config\&lt;/LI&gt;&lt;/OL&gt;
&lt;P&gt;In the spirit of full disclosure, without the hotfix/SP2, the behavior was still incorrect on Vista/Vista SP1/WS08 RTM in that the runtime was alreays reading the 2.0 configuration&amp;nbsp;although the application pool is configured to use .NET 1.1.&amp;nbsp; (Because the runtime was&amp;nbsp;always reading the 2.0 config regardless of the&amp;nbsp;.NET Framework version that is associated with the application pool.&amp;nbsp; This was the bug that hotfix/SP2 tried to address as&amp;nbsp;part of supporting .NET 4.0, but it didn't quite consider the fact that ASP.NET 1.1 is only available in 32-bit.)&amp;nbsp; This bug in Vista/Vista SP1/WS08 RTM may not have been too obvious to those running ASP.NET 1.1 on 64-bit Vista/Vista SP1/WS08 RTM unless you have significant/specific settings/differences between 1.1 and 2.0 configurations.&lt;/P&gt;&lt;img src="http://blogs.iis.net/aggbug.aspx?PostID=3243800" width="1" height="1"&gt;</description><category domain="http://blogs.iis.net/wonyoo/archive/tags/Configuration/default.aspx">Configuration</category><category domain="http://blogs.iis.net/wonyoo/archive/tags/ASP.NET/default.aspx">ASP.NET</category><category domain="http://blogs.iis.net/wonyoo/archive/tags/vista+SP2/default.aspx">vista SP2</category></item><item><title>Section level encryption of ASP.NET settings in IIS 7</title><link>http://blogs.iis.net/wonyoo/archive/2008/01/09/section-level-encryption-of-asp-net-in-iis-7.aspx</link><pubDate>Thu, 10 Jan 2008 06:31:00 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:2100973</guid><dc:creator>wonyoo</dc:creator><slash:comments>4</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://blogs.iis.net/wonyoo/rsscomments.aspx?PostID=2100973</wfw:commentRss><comments>http://blogs.iis.net/wonyoo/archive/2008/01/09/section-level-encryption-of-asp-net-in-iis-7.aspx#comments</comments><description>&lt;P mce_keep="true"&gt;As you know, ASP.NET supports section level encryption for protecting its configuration.&amp;nbsp; It supports both RSA, which is default,&amp;nbsp;and DPAPI out of the box and it also provides a way to use a custom protection provider.&amp;nbsp; (Click &lt;A class="" href="http://msdn2.microsoft.com/en-us/library/ms998283.aspx" target=_blank mce_href="http://msdn2.microsoft.com/en-us/library/ms998283.aspx"&gt;here&lt;/A&gt; for more information on using RSA.&amp;nbsp; Click &lt;A class="" href="http://msdn2.microsoft.com/en-us/library/ms998280.aspx" target=_blank mce_href="http://msdn2.microsoft.com/en-us/library/ms998280.aspx"&gt;here&lt;/A&gt; for DPAPI.)&amp;nbsp; The most commonly encrypted sections are appSettings, connectionStrings, identity and sesstionState.&lt;/P&gt;
&lt;P mce_keep="true"&gt;While the initial encryption is done using the aspnet_regiis.exe, once the sections are encrypted, IIS 6 inetmgr allowed the users to view the encrypted settings in clear text (ie. the UI decrypted the sections) and it also allowed the users to edit the values and saved the settings encrypted (ie. the UI re-encrypted the sections).&amp;nbsp; &lt;/P&gt;
&lt;P mce_keep="true"&gt;Unfortunately, in IIS 7, the inetmgr does not know how to handle encrypted sections for ASP.NET settings.&amp;nbsp; It is important to note that the section level encryption is still supported and it is as secure as it was in IIS 6.&amp;nbsp; It is just that the manageability of the encrypted sections is not supported in the IIS 7 inetmgr.&amp;nbsp; If the connection string section is encrypted in configuration, the user will see the following error when clicking on the connection string icon in IIS 7 inetmgr:&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;&lt;EM&gt;There was an error while performing this operation.&lt;BR&gt;Details:&lt;BR&gt;Filename: &amp;lt;path to configuration file&amp;gt;&lt;BR&gt;Line number: &amp;lt;line number&amp;gt;&lt;BR&gt;Error: Configuration section encryption is not supported&lt;/EM&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;P mce_keep="true"&gt;This was a consious design decision in IIS 7.&lt;/P&gt;
&lt;P mce_keep="true"&gt;I still recommend the users to encrypt and secure the ASP.NET settings that they find sensitive.&amp;nbsp; However, in order to view the values and/or update them, the users will first have to manually decrypt the sections using aspnet_regiis.exe, edit the file, and again re-encrypt the sections using aspnet_regiis.exe.&amp;nbsp; The steps to encrypt and decrypt the sections using RSA and DPAPI are provided in the links above.&amp;nbsp; &lt;/P&gt;&lt;img src="http://blogs.iis.net/aggbug.aspx?PostID=2100973" width="1" height="1"&gt;</description><category domain="http://blogs.iis.net/wonyoo/archive/tags/Configuration/default.aspx">Configuration</category><category domain="http://blogs.iis.net/wonyoo/archive/tags/ASP.NET/default.aspx">ASP.NET</category></item></channel></rss>