<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://weblogs.asp.net/utility/FeedStylesheets/atom.xsl" media="screen"?><feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en"><title type="html">Asp.Net QA Team</title><subtitle type="html">Thoughts and experiences from a test team</subtitle><id>http://weblogs.asp.net/asptest/atom.aspx</id><link rel="alternate" type="text/html" href="http://weblogs.asp.net/asptest/default.aspx" /><link rel="self" type="application/atom+xml" href="http://weblogs.asp.net/asptest/atom.aspx" /><generator uri="http://communityserver.org" version="3.0.20510.895">Community Server</generator><updated>2009-03-31T16:07:00Z</updated><entry><title>What is New in ASP.NET 4.0 Code Access Security</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/asptest/archive/2010/04/23/what-is-new-in-asp-net-4-0-code-access-security.aspx" /><id>http://weblogs.asp.net/asptest/archive/2010/04/23/what-is-new-in-asp-net-4-0-code-access-security.aspx</id><published>2010-04-23T19:37:00Z</published><updated>2010-04-23T19:37:00Z</updated><content type="html">&lt;P&gt;ASP.NET Code Access Security (CAS) is a feature that helps protect server applications on hosting multiple Web sites, ASP.NET lets you assign a configurable trust level that corresponds to a predefined set of permissions. ASP.NET has predefined &lt;A href="http://msdn.microsoft.com/en-us/library/wyts434y.aspx" mce_href="http://msdn.microsoft.com/en-us/library/wyts434y.aspx"&gt;ASP.NET Trust Levels and Policy Files&lt;/A&gt; that you can assign to applications, you also can assign custom trust level and policy files. Most web hosting companies run ASP.NET applications in Medium Trust to prevent that one website affect or harm another site etc. &lt;/P&gt;
&lt;P&gt;As .NET Framework's Code Access Security model has evolved, ASP.NET 4.0 Code Access Security also has introduced several changes and improvements. &lt;/P&gt;
&lt;H2&gt;The main change in ASP.NET 4.0 CAS&lt;/H2&gt;
&lt;P&gt;&lt;B&gt;&lt;/B&gt;&lt;/P&gt;
&lt;P&gt;In ASP.NET v4.0 partial trust applications, &lt;A href="http://msdn.microsoft.com/en-us/library/cxk374d9.aspx" mce_href="http://msdn.microsoft.com/en-us/library/cxk374d9.aspx"&gt;application domain&lt;/A&gt; can have a default partial trust permission set as opposed to being full-trust, the permission set name is defined in the &amp;lt;trust /&amp;gt; new attribute &lt;U&gt;&lt;A href="http://msdn.microsoft.com/en-us/library/system.web.configuration.trustsection.permissionsetname(VS.100).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.web.configuration.trustsection.permissionsetname(VS.100).aspx"&gt;permissionSetName&lt;/A&gt;&lt;/U&gt; that is used to initialize the application domain . By default, the PermissionSetName attribute value is "ASP.Net" which is the name of the permission set you can find in all predefined partial trust configuration files. &lt;/P&gt;
&lt;DIV id=codeSnippetWrapper&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;trust&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;level&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="Something"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;permissionSetName&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="ASP.Net"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;BR&gt;&lt;/DIV&gt;
&lt;P&gt;This is ASP.NET 4.0 new CAS model. For compatibility ASP.NET 4.0 also support legacy CAS model where application domain still has full trust permission set. &lt;/P&gt;
&lt;P&gt;You can specify new &lt;A href="http://msdn.microsoft.com/en-us/library/system.web.configuration.trustsection.legacycasmodel(VS.100).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.web.configuration.trustsection.legacycasmodel(VS.100).aspx"&gt;legacyCasModel&lt;/A&gt; attribute on the &amp;lt;trust /&amp;gt; element to indicate whether the legacy CAS model is enabled. By default legacyCasModel is false which means that new 4.0 CAS model is the default. &lt;/P&gt;
&lt;DIV id=codeSnippetWrapper&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;trust&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;level&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="Something"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;legacyCasModel&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="true|false"&lt;/SPAN&gt;  &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;BR&gt;&lt;/DIV&gt;
&lt;P&gt;In .Net FX 4.0 Config directory, there are two set of predefined partial trust config files for each new CAS model and legacy CAS model, trust config files with name legacy.XYZ.config are for legacy CAS model:&lt;/P&gt;
&lt;TABLE border=0 cellSpacing=0 cellPadding=2 width=400&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD vAlign=top width=200&gt;New CAS model:&lt;/TD&gt;
&lt;TD vAlign=top width=200&gt;Legacy CAS model:&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD vAlign=top width=200&gt;web_hightrust.config&lt;/TD&gt;
&lt;TD vAlign=top width=200&gt;legacy.web_hightrust.config&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD vAlign=top width=200&gt;web_mediumtrust.config&lt;/TD&gt;
&lt;TD vAlign=top width=200&gt;legacy.web_mediumtrust.config&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD vAlign=top width=200&gt;web_lowtrust.config&lt;/TD&gt;
&lt;TD vAlign=top width=200&gt;legacy.web_lowtrust.config&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD vAlign=top width=200&gt;web_minimaltrust.config&lt;/TD&gt;
&lt;TD vAlign=top width=200&gt;legacy.web_minimaltrust.config&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;
&lt;P&gt;The figure below shows in ASP.NET 4.0 new CAS model what permission set to grant to code for partial trust application using predefined partial trust levels and policy files:&amp;nbsp; &lt;/P&gt;
&lt;P&gt;&lt;A href="http://weblogs.asp.net/blogs/asptest/Temp_244BCBAB.jpg" mce_href="http://weblogs.asp.net/blogs/asptest/Temp_244BCBAB.jpg"&gt;&lt;IMG style="BORDER-RIGHT-WIDTH: 0px; MARGIN: 0px 25px 0px 0px; DISPLAY: inline; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px" title=Temp border=0 alt=Temp src="http://weblogs.asp.net/blogs/asptest/Temp_thumb_27310A91.jpg" width=303 height=174 mce_src="http://weblogs.asp.net/blogs/asptest/Temp_thumb_27310A91.jpg"&gt;&lt;/A&gt;&amp;nbsp; &lt;/P&gt;
&lt;P&gt;There also some benefits that comes with the new CAS model:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;
&lt;DIV&gt;You can lock down a machine by making all managed code no-execute by default (e.g. setting the MyComputer zone to have no managed execution code permissions), it should still be possible to configure ASP.NET web applications to run as either full-trust or partial trust.&lt;/DIV&gt;&lt;/LI&gt;
&lt;LI&gt;UNC share doesn’t require full trust with CASPOL at machine-level CAS policy. &lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;Side effect that comes with the new CAS model:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;A href="http://msdn.microsoft.com/en-us/library/system.web.configuration.trustsection.processrequestinapplicationtrust.aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.web.configuration.trustsection.processrequestinapplicationtrust.aspx"&gt;processRequestInApplicationTrust&lt;/A&gt; attribute is deprecated&amp;nbsp; in new CAS model since application domain always has partial trust permission set in new CAS model. &lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;In ASP.NET 4.0 legacy CAS model or ASP.NET 2.0 CAS model, even though you assign partial trust level to a application but the application domain still has full trust permission set.&lt;/P&gt;
&lt;P&gt;The figure below shows in ASP.NET 4.0 legacy CAS model (or ASP.NET 2.0 CAS model) what permission set to grant to code for partial trust application using predefined partial trust levels and policy files: &lt;/P&gt;
&lt;P&gt;&lt;A href="http://weblogs.asp.net/blogs/asptest/Temp2_786B51EE.jpg" mce_href="http://weblogs.asp.net/blogs/asptest/Temp2_786B51EE.jpg"&gt;&lt;IMG style="BORDER-RIGHT-WIDTH: 0px; DISPLAY: inline; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px" title=Temp2 border=0 alt=Temp2 src="http://weblogs.asp.net/blogs/asptest/Temp2_thumb_3E7C0F02.jpg" width=350 height=191 mce_src="http://weblogs.asp.net/blogs/asptest/Temp2_thumb_3E7C0F02.jpg"&gt;&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;What $AppDirUrl$, $CodeGen$, $Gac$ represents: &lt;/P&gt;
&lt;TABLE border=1 cellSpacing=0 cellPadding=0&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD vAlign=top&gt;
&lt;P&gt;$AppDirUrl$&lt;/P&gt;&lt;/TD&gt;
&lt;TD vAlign=top&gt;
&lt;P&gt;The application's virtual root directory. This allows permissions to be applied to code that is located in the application's bin directory. &lt;/P&gt;
&lt;P&gt;For example, if a virtual directory is mapped to C:\YourWebApp, then $AppDirUrl$ would equate to C:\YourWebApp.&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD vAlign=top&gt;
&lt;P&gt;$CodeGen$&lt;/P&gt;&lt;/TD&gt;
&lt;TD vAlign=top&gt;
&lt;P&gt;The directory that contains dynamically generated assemblies (for example, the result of .aspx page compiles). This can be configured on a per application basis and defaults to %windir%\Microsoft.NET\Framework\{version}\Temporary ASP.NET Files. &lt;/P&gt;
&lt;P&gt;$CodeGen$ allows permissions to be applied to dynamically generated assemblies.&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD vAlign=top&gt;
&lt;P&gt;$Gac$&lt;/P&gt;&lt;/TD&gt;
&lt;TD vAlign=top&gt;
&lt;P&gt;Any assembly that is installed in the computer's &lt;A href="http://msdn.microsoft.com/en-us/library/yf1d93sz(VS.71).aspx" mce_href="http://msdn.microsoft.com/en-us/library/yf1d93sz(VS.71).aspx"&gt;global assembly cache&lt;/A&gt; (GAC). This allows permissions to be granted to strong named assemblies loaded from the GAC by the Web application.&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;
&lt;P&gt;&lt;B&gt;&lt;/B&gt;&lt;/P&gt;
&lt;H4&gt;&amp;nbsp;&lt;/H4&gt;
&lt;H2&gt;The new customization of CAS Policy in ASP.NET 4.0 new CAS model&lt;/H2&gt;
&lt;H3&gt;1. Define which named permission set in partial trust configuration files &lt;/H3&gt;
&lt;BLOCKQUOTE&gt;
&lt;P align=left&gt;By default the permission set that will be assigned at application domain initialization time is the named "ASP.Net" permission set found in all predefined partial trust configuration files. However ASP.NET 4.0 allows you set &lt;A href="http://msdn.microsoft.com/en-us/library/system.web.configuration.trustsection.permissionsetname(VS.100).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.web.configuration.trustsection.permissionsetname(VS.100).aspx"&gt;PermissionSetName&lt;/A&gt; attribute to define which named permission set in a partial trust configuration file should be the one used to initialize an application domain. &lt;/P&gt;
&lt;P align=left&gt;Example: add "ASP.Net_2" named permission set in partial trust configuration file:&lt;/P&gt;
&lt;DIV id=codeSnippetWrapper&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;PermissionSet&lt;/SPAN&gt;&lt;BR&gt;  &lt;SPAN style="COLOR: #ff0000"&gt;class&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="NamedPermissionSet"&lt;/SPAN&gt;&lt;BR&gt;  &lt;SPAN style="COLOR: #ff0000"&gt;version&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="1"&lt;/SPAN&gt;&lt;BR&gt;  &lt;SPAN style="COLOR: #ff0000"&gt;Name&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="ASP.Net_2"&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;   &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;IPermission&lt;/SPAN&gt;&lt;BR&gt;        &lt;SPAN style="COLOR: #ff0000"&gt;class&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="FileIOPermission"&lt;/SPAN&gt;&lt;BR&gt;         &lt;SPAN style="COLOR: #ff0000"&gt;version&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="1"&lt;/SPAN&gt;&lt;BR&gt;         &lt;SPAN style="COLOR: #ff0000"&gt;Read&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="$AppDir$"&lt;/SPAN&gt;&lt;BR&gt;         &lt;SPAN style="COLOR: #ff0000"&gt;PathDiscovery&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="$AppDir$"&lt;/SPAN&gt;&lt;BR&gt;        &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;  &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;IPermission&lt;/SPAN&gt;&lt;BR&gt;        &lt;SPAN style="COLOR: #ff0000"&gt;class&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="ReflectionPermission"&lt;/SPAN&gt;&lt;BR&gt;        &lt;SPAN style="COLOR: #ff0000"&gt;version&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="1"&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #ff0000"&gt;        Flags&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;="RestrictedMemberAccess"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;  &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;IPermission&lt;/SPAN&gt;&lt;BR&gt;        &lt;SPAN style="COLOR: #ff0000"&gt;class&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="SecurityPermission "&lt;/SPAN&gt;&lt;BR&gt;        &lt;SPAN style="COLOR: #ff0000"&gt;version&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="1"&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #ff0000"&gt;        Flags&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;="Execution, ControlThread, ControlPrincipal, RemotingConfiguration"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;PermissionSet&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;/PRE&gt;&lt;/DIV&gt;&lt;/BLOCKQUOTE&gt;
&lt;BLOCKQUOTE&gt;
&lt;DIV align=left&gt;
&lt;P&gt;Then you can use "ASP.Net_2" named permission set for the application domain permission set:&lt;/P&gt;&lt;/DIV&gt;&lt;/BLOCKQUOTE&gt;
&lt;BLOCKQUOTE&gt;
&lt;DIV&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;trust&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;level&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="Something"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;legacyCasModel&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="false"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;permissionSetName&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="ASP.Net_2"&lt;/SPAN&gt;  &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;BR&gt;&lt;/DIV&gt;&lt;/BLOCKQUOTE&gt;
&lt;DIV&gt;&lt;BR&gt;&lt;B&gt;&lt;/B&gt;&lt;B&gt;&lt;/B&gt;&lt;B&gt;&lt;/B&gt;&lt;/DIV&gt;
&lt;H3&gt;2. Define a custom set of Full Trust Assemblies for an application&lt;/H3&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;By using the new &lt;A href="http://msdn.microsoft.com/en-us/library/dd551436(v=VS.100).aspx" mce_href="http://msdn.microsoft.com/en-us/library/dd551436(v=VS.100).aspx"&gt;fullTrustAssemblies&lt;/A&gt; element to configure a set of Full Trust Assemblies for an application, you can modify set of partial trust assemblies to full trust at the machine, site or application level. &lt;/P&gt;
&lt;P&gt;The configuration definition is shown below:&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;BLOCKQUOTE&gt;
&lt;DIV id=codeSnippetWrapper&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;fullTrustAssemblies&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;    &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;add&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;assemblyName&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="MyAssembly"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;version&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="1.1.2.3"&lt;/SPAN&gt; &lt;BR&gt;          &lt;SPAN style="COLOR: #ff0000"&gt;publicKey&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="hex_char_representation_of_key_blob"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;fullTrustAssemblies&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;/PRE&gt;&lt;BR&gt;&lt;/DIV&gt;&lt;/BLOCKQUOTE&gt;
&lt;H3&gt;3. Define &amp;lt;CodeGroup /&amp;gt; policy in partial trust configuration files&lt;/H3&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;ASP.NET 4.0 new CAS model will retain the ability for developers to optionally define &amp;lt;CodeGroup /&amp;gt;with membership conditions and assigned permission sets. The specific restriction in ASP.NET 4.0 new CAS model though will be that the results of evaluating custom policies can only result in one of two outcomes: either an assembly is granted full trust, or an assembly is granted the partial trust permission set currently associated with the running application domain. It will not be possible to use custom policies to create additional custom partial trust permission sets.&lt;/P&gt;
&lt;P&gt;When parsing the partial trust configuration file:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Any assemblies that match to code groups associated with "PermissionSet='FullTrust'" will run at full trust. &lt;B&gt;&lt;/B&gt;&lt;/LI&gt;
&lt;LI&gt;Any assemblies that match to code groups associated with "PermissionSet='Nothing'" will result in a PolicyError being thrown from the CLR. This is acceptable since it provides administrators with a way to do a blanket-deny of managed code followed by selectively defining policy in a &amp;lt;CodeGroup /&amp;gt; that re-adds assemblies that would be allowed to run.&lt;B&gt;&lt;/B&gt; &lt;/LI&gt;
&lt;LI&gt;Any assemblies that match to code groups associated with other permissions sets will be interpreted to mean the assembly should run at the permission set of the appdomain. This means that even though syntactically a developer could define additional "flavors" of partial trust in an ASP.NET partial trust configuration file, those "flavors" will always be ignored.&lt;B&gt;&lt;/B&gt; &lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;Example: defines full trust in &amp;lt;CodeGroup /&amp;gt; for my strong named assemblies in partial trust config files:&lt;/P&gt;
&lt;DIV id=codeSnippetWrapper&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;CodeGroup&lt;/SPAN&gt;&lt;BR&gt;    &lt;SPAN style="COLOR: #ff0000"&gt;class&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="FirstMatchCodeGroup"&lt;/SPAN&gt;&lt;BR&gt;    &lt;SPAN style="COLOR: #ff0000"&gt;version&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="1"&lt;/SPAN&gt;&lt;BR&gt;    &lt;SPAN style="COLOR: #ff0000"&gt;PermissionSetName&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="Nothing"&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;    &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;IMembershipCondition&lt;/SPAN&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #ff0000"&gt;class&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="AllMembershipCondition"&lt;/SPAN&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #ff0000"&gt;version&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="1"&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;    /&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;    &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;CodeGroup&lt;/SPAN&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #ff0000"&gt;class&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="UnionCodeGroup"&lt;/SPAN&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #ff0000"&gt;version&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="1"&lt;/SPAN&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #ff0000"&gt;PermissionSetName&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="FullTrust"&lt;/SPAN&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #ff0000"&gt;Name&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="My_Strong_Name"&lt;/SPAN&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #ff0000"&gt;Description&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="This code group grants code signed full trust. "&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;     &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;IMembershipCondition&lt;/SPAN&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #ff0000"&gt;class&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="StrongNameMembershipCondition"&lt;/SPAN&gt;&lt;BR&gt;        &lt;SPAN style="COLOR: #ff0000"&gt;version&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="1"&lt;/SPAN&gt;                             &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #ff0000"&gt;PublicKeyBlob&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="hex_char_representation_of_key_blob"&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;      /&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;    &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;CodeGroup&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;    &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;CodeGroup&lt;/SPAN&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #ff0000"&gt;class&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="UnionCodeGroup"&lt;/SPAN&gt;&lt;BR&gt;      &lt;SPAN style="COLOR: #ff0000"&gt;version&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="1"&lt;/SPAN&gt;&lt;BR&gt;      &lt;SPAN style="COLOR: #ff0000"&gt;PermissionSetName&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="ASP.Net"&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;IMembershipCondition&lt;/SPAN&gt;&lt;BR&gt;        &lt;SPAN style="COLOR: #ff0000"&gt;class&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="UrlMembershipCondition"&lt;/SPAN&gt;&lt;BR&gt;        &lt;SPAN style="COLOR: #ff0000"&gt;version&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="1"&lt;/SPAN&gt;&lt;BR&gt;        &lt;SPAN style="COLOR: #ff0000"&gt;Url&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="$AppDirUrl$/*"&lt;/SPAN&gt;&lt;BR&gt;      &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;    &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;CodeGroup&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;    &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;CodeGroup&lt;/SPAN&gt;&lt;BR&gt;     &lt;SPAN style="COLOR: #ff0000"&gt;class&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="UnionCodeGroup"&lt;/SPAN&gt;&lt;BR&gt;     &lt;SPAN style="COLOR: #ff0000"&gt;version&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="1"&lt;/SPAN&gt;&lt;BR&gt;     &lt;SPAN style="COLOR: #ff0000"&gt;PermissionSetName&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="ASP.Net"&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;IMembershipCondition&lt;/SPAN&gt;&lt;BR&gt;      &lt;SPAN style="COLOR: #ff0000"&gt;class&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="UrlMembershipCondition"&lt;/SPAN&gt;&lt;BR&gt;      &lt;SPAN style="COLOR: #ff0000"&gt;version&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="1"&lt;/SPAN&gt;&lt;BR&gt;      &lt;SPAN style="COLOR: #ff0000"&gt;Url&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="$CodeGen$/*"&lt;/SPAN&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;    &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;CodeGroup&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;CodeGroup&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;/PRE&gt;&lt;/DIV&gt;&lt;/BLOCKQUOTE&gt;
&lt;H3&gt;4. Customize CAS policy at runtime in ASP.NET 4.0 new CAS model&lt;/H3&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;ASP.NET 4.0 new CAS model allows to customize CAS policy at runtime by using custom &lt;A href="http://msdn.microsoft.com/en-us/library/system.web.hosting.hostsecuritypolicyresolver(VS.100).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.web.hosting.hostsecuritypolicyresolver(VS.100).aspx"&gt;HostSecurityPolicyResolver&lt;/A&gt; that overrides the ASP.NET code access security policy.&lt;/P&gt;
&lt;P&gt;Example: use custom host security policy resolver to resolve partial trust web application bin folder MyTrustedAssembly.dll to full trust at runtime:&lt;/P&gt;
&lt;P&gt;You can create a custom host security policy resolver and compile it to assembly MyCustomResolver.dll with strong name enabled and deploy in GAC: &lt;/P&gt;
&lt;DIV&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;SPAN style="COLOR: #0000ff"&gt;public&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;class&lt;/SPAN&gt; MyCustomResolver : HostSecurityPolicyResolver&lt;BR&gt;{&lt;BR&gt;  &lt;SPAN style="COLOR: #0000ff"&gt;public&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;override&lt;/SPAN&gt; HostSecurityPolicyResults ResolvePolicy(Evidence evidence)&lt;BR&gt;  {&lt;BR&gt;        IEnumerator hostEvidence = evidence.GetHostEnumerator();&lt;BR&gt;&lt;BR&gt;        &lt;SPAN style="COLOR: #0000ff"&gt;while&lt;/SPAN&gt; (hostEvidence.MoveNext())&lt;BR&gt;        {&lt;BR&gt;            &lt;SPAN style="COLOR: #0000ff"&gt;object&lt;/SPAN&gt; hostEvidenceObject = hostEvidence.Current;&lt;BR&gt;            &lt;BR&gt;            &lt;SPAN style="COLOR: #0000ff"&gt;if&lt;/SPAN&gt; (hostEvidenceObject &lt;SPAN style="COLOR: #0000ff"&gt;is&lt;/SPAN&gt; System.Security.Policy.Url)&lt;BR&gt;            {&lt;BR&gt;               &lt;SPAN style="COLOR: #0000ff"&gt;string&lt;/SPAN&gt; assemblyName = hostEvidenceObject.ToString();&lt;BR&gt;               &lt;SPAN style="COLOR: #0000ff"&gt;if&lt;/SPAN&gt; (assemblyName.Contains(“MyTrustedAssembly.dll”)&lt;BR&gt;                  &lt;SPAN style="COLOR: #0000ff"&gt;return&lt;/SPAN&gt; HostSecurityPolicyResult.FullTrust;&lt;BR&gt;            }&lt;BR&gt;        }  &lt;BR&gt;&lt;BR&gt;        &lt;SPAN style="COLOR: #008000"&gt;//default fall-through&lt;/SPAN&gt;&lt;BR&gt;        &lt;SPAN style="COLOR: #0000ff"&gt;return&lt;/SPAN&gt; HostSecurityPolicyResult.DefaultPolicy;&lt;BR&gt;  }&lt;BR&gt;}&lt;/PRE&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;BR&gt;Because ASP.NET accesses the custom HostSecurityPolicyResolver during application domain initialization, and a custom policy resolver requires full trust, you also can add a custom policy resolver in &amp;lt;fullTrustAssemblies /&amp;gt; , or deploy in the GAC. &lt;/DIV&gt;&lt;/BLOCKQUOTE&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;You also need configure a custom HostSecurityPolicyResolver instance by adding the &lt;A href="http://msdn.microsoft.com/en-us/library/system.web.configuration.trustsection.hostsecuritypolicyresolvertype(v=VS.100).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.web.configuration.trustsection.hostsecuritypolicyresolvertype(v=VS.100).aspx"&gt;HostSecurityPolicyResolverType&lt;/A&gt; attribute in the &amp;lt;trust /&amp;gt; element: &lt;/P&gt;
&lt;DIV id=codeSnippetWrapper&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;trust&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;level&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="Something"&lt;/SPAN&gt;  &lt;BR&gt;    &lt;SPAN style="COLOR: #ff0000"&gt;legacyCasModel&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="false"&lt;/SPAN&gt; &lt;BR&gt;    &lt;SPAN style="COLOR: #ff0000"&gt;hostSecurityPolicyResolverType&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="MyCustomResolver,  MyCustomResolver"&lt;/SPAN&gt;&lt;BR&gt;    &lt;SPAN style="COLOR: #ff0000"&gt;permissionSetName&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="ASP.Net"&lt;/SPAN&gt; &lt;BR&gt;    &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;/PRE&gt;&lt;/DIV&gt;&lt;/BLOCKQUOTE&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;P&gt;Note:&lt;/P&gt;
&lt;P&gt;If an assembly policy define in &amp;lt;CodeGroup/&amp;gt; and also in hostSecurityPolicyResolverType, hostSecurityPolicyResolverType will win.&lt;/P&gt;
&lt;P&gt;If an assembly added in &amp;lt;fullTrustAssemblies/&amp;gt; then the assembly has full trust no matter what policy in &amp;lt;CodeGroup/&amp;gt; or in hostSecurityPolicyResolverType.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;H2&gt;&lt;B&gt;Other changes in ASP.NET 4.0 CAS&lt;/B&gt;&lt;B&gt;&lt;/B&gt;&lt;/H2&gt;
&lt;H3&gt;Use the new transparency model introduced in .Net Framework 4.0&lt;/H3&gt;
&lt;UL&gt;
&lt;LI&gt;Change in dynamically compiled code generated assemblies by ASP.NET: &lt;/LI&gt;&lt;/UL&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;In new CAS model they will be marked as &lt;A href="http://msdn.microsoft.com/en-us/library/dd233102(v=VS.100).aspx" mce_href="http://msdn.microsoft.com/en-us/library/dd233102(v=VS.100).aspx"&gt;security transparent level2&lt;/A&gt; to use Framework 4.0 security transparent rule that means partial trust code is treated as completely Transparent and it is more strict enforcement.&lt;/P&gt;
&lt;P&gt;In legacy CAS model they will be marked as &lt;A href="http://msdn.microsoft.com/en-us/library/bb397858(v=VS.100).aspx" mce_href="http://msdn.microsoft.com/en-us/library/bb397858(v=VS.100).aspx"&gt;security transparent level1&lt;/A&gt; to use Framework 2.0 security transparent rule for compatibility.&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;UL&gt;
&lt;LI&gt;Most of ASP.NET products runtime assemblies are also changed to be marked as security transparent level2 to switch to &lt;A href="http://msdn.microsoft.com/en-us/library/system.security.securitytransparentattribute(v=VS.100).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.security.securitytransparentattribute(v=VS.100).aspx"&gt;SecurityTransparent&lt;/A&gt; code by default unless &lt;A href="http://msdn.microsoft.com/en-us/library/system.security.securitycriticalattribute(v=VS.100).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.security.securitycriticalattribute(v=VS.100).aspx"&gt;SecurityCritical&lt;/A&gt; or &lt;A href="http://msdn.microsoft.com/en-us/library/system.security.securitysafecriticalattribute(v=VS.100).aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.security.securitysafecriticalattribute(v=VS.100).aspx"&gt;SecuritySafeCritical&lt;/A&gt; attribute specified. &lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;You also can look at &lt;A href="http://msdn.microsoft.com/en-us/library/dd233103(v=VS.100).aspx" mce_href="http://msdn.microsoft.com/en-us/library/dd233103(v=VS.100).aspx"&gt;Security Changes in the .NET Framework 4&lt;/A&gt; for more information about these security attributes.&lt;/P&gt;
&lt;H3&gt;Support conditional APTCA &lt;/H3&gt;
&lt;UL&gt;
&lt;LI&gt;If an assembly is marked with the &lt;A href="http://msdn.microsoft.com/en-us/library/dd233103(VS.100).aspx#aptca" mce_href="http://msdn.microsoft.com/en-us/library/dd233103(VS.100).aspx#aptca"&gt;Conditional APTCA&lt;/A&gt; attribute to allow partially trusted callers, and if you want to make the assembly both visible and accessible to partial-trust code in your web application, you must add a reference to the assembly in the &lt;A href="http://msdn.microsoft.com/en-us/library/dd551439(VS.100).aspx" mce_href="http://msdn.microsoft.com/en-us/library/dd551439(VS.100).aspx"&gt;partialTrustVisibleAssemblies&lt;/A&gt; section: &lt;/LI&gt;&lt;/UL&gt;
&lt;BLOCKQUOTE&gt;
&lt;DIV&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;partialTrustVisibleAssemblies&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;   &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;add&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;assemblyName&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="MyAssembly"&lt;/SPAN&gt; &lt;BR&gt;        &lt;SPAN style="COLOR: #ff0000"&gt;publicKey&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="hex_char_representation_of_key_blob"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;/partialTrustVisibleAssemblies&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;/PRE&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/BLOCKQUOTE&gt;
&lt;UL&gt;
&lt;LI&gt;Most of ASP.NET products runtime assemblies are also changed to be marked as conditional APTCA to prevent use of ASP.NET APIs in partial trust environments such as Winforms or WPF UI controls hosted in Internet Explorer. &lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;B&gt;&lt;/B&gt;&lt;/P&gt;
&lt;H3&gt;&amp;nbsp;&lt;/H3&gt;
&lt;H2&gt;Differences between ASP.NET new CAS model and legacy CAS model:&lt;/H2&gt;
&lt;P&gt;Here list some differences between ASP.NET new CAS model and legacy CAS model&lt;/P&gt;
&lt;P&gt;&lt;B&gt;ASP.NET 4.0 legacy CAS model:&lt;/B&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Asp.net partial trust appdomains have full trust permission &lt;/LI&gt;&lt;/UL&gt;
&lt;UL&gt;
&lt;LI&gt;Multiple different permission sets in a single appdomain are allowed in ASP.NET partial trust configuration files Code groups &lt;/LI&gt;&lt;/UL&gt;
&lt;UL&gt;
&lt;LI&gt;Machine CAS policy is honored &lt;/LI&gt;&lt;/UL&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;A href="http://msdn.microsoft.com/en-us/library/system.web.configuration.trustsection.processrequestinapplicationtrust.aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.web.configuration.trustsection.processrequestinapplicationtrust.aspx"&gt;processRequestInApplicationTrust&lt;/A&gt; attribute is still honored&amp;nbsp; &lt;/LI&gt;&lt;/UL&gt;
&lt;BLOCKQUOTE&gt;&lt;/BLOCKQUOTE&gt;
&lt;UL&gt;
&lt;LI&gt;New configuration setting for legacy model: &lt;/LI&gt;&lt;/UL&gt;
&lt;BLOCKQUOTE&gt;
&lt;BLOCKQUOTE&gt;
&lt;DIV&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;P&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;trust&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;level&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="Something"&lt;/SPAN&gt; &lt;BR&gt;    &lt;SPAN style="COLOR: #ff0000"&gt;legacyCASModel&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="true"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;trust&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;partialTrustVisibleAssemblies&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;    &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;add&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;assemblyName&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="MyAssembly"&lt;/SPAN&gt; &lt;BR&gt;          &lt;SPAN style="COLOR: #ff0000"&gt;publicKey&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="hex_char_representation_of_key_blob"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;partialTrustVisibleAssemblies&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;/P&gt;&lt;/PRE&gt;&lt;/DIV&gt;&lt;/BLOCKQUOTE&gt;&lt;/BLOCKQUOTE&gt;
&lt;BLOCKQUOTE&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&lt;B&gt;&lt;/B&gt;&lt;/P&gt;
&lt;P&gt;&lt;B&gt;&lt;/B&gt;&lt;/P&gt;
&lt;P&gt;&lt;B&gt;ASP.NET 4.0 new CAS model:&lt;/B&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;ASP.NET will now run in homogeneous application domains. Only full trust or the app-domain's partial trust grant set, are allowable permission sets. &lt;/LI&gt;&lt;/UL&gt;
&lt;UL&gt;
&lt;LI&gt;It is no longer possible to define arbitrary permission sets that get assigned to different assemblies. If an application currently depends on fine-tuning the partial trust permission set using the ASP.NET partial trust configuration file, this will no longer be possible. &lt;/LI&gt;&lt;/UL&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;A href="http://msdn.microsoft.com/en-us/library/system.web.configuration.trustsection.processrequestinapplicationtrust.aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.web.configuration.trustsection.processrequestinapplicationtrust.aspx"&gt;processRequestInApplicationTrust&lt;/A&gt; attribute is deprecated &lt;/LI&gt;&lt;/UL&gt;
&lt;UL&gt;
&lt;LI&gt;Dynamically compiled assemblies output by ASP.NET build providers will be updated to explicitly mark assemblies as transparent. &lt;/LI&gt;&lt;/UL&gt;
&lt;UL&gt;
&lt;LI&gt;ASP.NET partial trust grant sets will be independent from any enterprise, machine, or user CAS policy levels. &lt;/LI&gt;&lt;/UL&gt;
&lt;UL&gt;
&lt;LI&gt;A simplified model for locking down web servers that only allows trusted managed web applications to run. 
&lt;UL&gt;
&lt;LI&gt;Machine policy used to always grant full-trust to managed code (based on membership conditions) can instead be configured using the new ASP.NET 4.0 full-trust assembly configuration section. The full-trust assembly configuration section requires explicitly listing each assembly as opposed to using membership conditions. &lt;/LI&gt;
&lt;LI&gt;Alternatively, the membership condition(s) used in machine policy can instead be re-defined in a &amp;lt;CodeGroup /&amp;gt; within ASP.NET's partial trust configuration file to grant full-trust. &lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;UL&gt;
&lt;LI&gt;New configuration setting for new model: &lt;/LI&gt;&lt;/UL&gt;
&lt;BLOCKQUOTE&gt;
&lt;BLOCKQUOTE&gt;
&lt;DIV&gt;&lt;PRE style="BORDER-BOTTOM-STYLE: none; TEXT-ALIGN: left; PADDING-BOTTOM: 0px; LINE-HEIGHT: 12pt; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: #f4f4f4; MARGIN: 0em; PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; FONT-FAMILY: 'Courier New', courier, monospace; DIRECTION: ltr; BORDER-TOP-STYLE: none; COLOR: black; FONT-SIZE: 8pt; BORDER-LEFT-STYLE: none; OVERFLOW: visible; PADDING-TOP: 0px" id=codeSnippet&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;trust&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;level&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="Something"&lt;/SPAN&gt; &lt;BR&gt;&lt;SPAN style="COLOR: #ff0000"&gt;    legacyCASModel&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="false"&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #ff0000"&gt;    permissionSetName&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="ASP.Net"&lt;/SPAN&gt; &lt;BR&gt;&lt;SPAN style="COLOR: #ff0000"&gt;    hostSecurityPolicyResolverType&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;=".NET type string"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;trust&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&lt;P&gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;fullTrustAssemblies&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;    &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;add&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;assemblyName&lt;/SPAN&gt;=”&lt;SPAN style="COLOR: #ff0000"&gt;MyAssembly&lt;/SPAN&gt;” &lt;SPAN style="COLOR: #ff0000"&gt;version&lt;/SPAN&gt;=”&lt;SPAN style="COLOR: #ff0000"&gt;1&lt;/SPAN&gt;.&lt;SPAN style="COLOR: #ff0000"&gt;0&lt;/SPAN&gt;.&lt;SPAN style="COLOR: #ff0000"&gt;0&lt;/SPAN&gt;.&lt;SPAN style="COLOR: #ff0000"&gt;0&lt;/SPAN&gt;”&lt;BR&gt;        &lt;SPAN style="COLOR: #ff0000"&gt;publicKey&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="hex_char_representation_of_key_blob"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;fullTrustAssemblies&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;partialTrustVisibleAssemblies&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;    &lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;add&lt;/SPAN&gt; &lt;SPAN style="COLOR: #ff0000"&gt;assemblyName&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="MyAssembly"&lt;/SPAN&gt; &lt;BR&gt;          &lt;SPAN style="COLOR: #ff0000"&gt;publicKey&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;="hex_char_representation_of_key_blob"&lt;/SPAN&gt; &lt;SPAN style="COLOR: #0000ff"&gt;/&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: #800000"&gt;partialTrustVisibleAssemblies&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;/P&gt;&lt;/PRE&gt;&lt;/DIV&gt;&lt;/BLOCKQUOTE&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/BLOCKQUOTE&gt;
&lt;BLOCKQUOTE&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Hope this post is helpful to better understand the ASP.Net 4.0 CAS.&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Xiaohong Tang &lt;BR&gt;ASP.NET QA Team&lt;/STRONG&gt;&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7456209" width="1" height="1"&gt;</content><author><name>Xiaohong</name><uri>http://weblogs.asp.net/members/Xiaohong.aspx</uri></author><category term="ASP.NET" scheme="http://weblogs.asp.net/asptest/archive/tags/ASP.NET/default.aspx" /><category term="CAS" scheme="http://weblogs.asp.net/asptest/archive/tags/CAS/default.aspx" /><category term="Code Access Security" scheme="http://weblogs.asp.net/asptest/archive/tags/Code+Access+Security/default.aspx" /></entry><entry><title>News from the QA team</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/asptest/archive/2009/09/13/news-from-the-qa-team.aspx" /><id>http://weblogs.asp.net/asptest/archive/2009/09/13/news-from-the-qa-team.aspx</id><published>2009-09-14T03:40:48Z</published><updated>2009-09-14T03:40:48Z</updated><content type="html">&lt;p&gt;I know there has been very little traffic on our team blog, but I recently decided to start my own blog so that I could share my personal opinions. However, here is a small news update from the ASP.NET QA team:&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;First and fore most: the ASP.NET QA team is hiring! If you are interested, check out our job posting &lt;a href="https://careers.microsoft.com/JobDetails.aspx?jid=6745&amp;amp;lang=en"&gt;here&lt;/a&gt;. You can also read about it in Matthew Osborn’s blog &lt;a href="http://blog.osbornm.com/archive/2009/09/01/71.aspx"&gt;here&lt;/a&gt;.      &lt;br /&gt;&lt;/li&gt;    &lt;li&gt;The weekly &lt;a href="http://www.codingqa.com/"&gt;CodingQA&lt;/a&gt; podcast is alive and kicking. Check it out, and if you like it you can subscribe using iTunes and Zune.      &lt;br /&gt;&lt;/li&gt;    &lt;li&gt;Jim Wang, the lead tester for ASP.NE Ajax, posted a nice tutorial using ASP.NET Ajax Preview 5 &lt;a href="http://weblogs.asp.net/jimwang/archive/2009/09/11/asp-net-ajax-preview-5-and-updatepanel.aspx"&gt;here&lt;/a&gt;.      &lt;br /&gt;&lt;/li&gt;    &lt;li&gt;Federico Silva Armas (me :P) is presenting at &lt;a href="http://www.devconnections.com/"&gt;DevConnections&lt;/a&gt; this year. Check this &lt;a href="http://testertales.blogspot.com/2009/09/presenting-at-devconnections.html"&gt;post&lt;/a&gt; for more information.      &lt;br /&gt;&lt;/li&gt;    &lt;li&gt;Last but not least, &lt;a href="http://testertales.blogspot.com/"&gt;Tales of Testing&lt;/a&gt; is my personal blog where I cover everything that has to do with testing. If you are into testing and want to share your ideas I am interested in listening.&lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Federico Silva Armas     &lt;br /&gt;SDET, ASP.NET QA Team&lt;/strong&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7204472" width="1" height="1"&gt;</content><author><name>farmas</name><uri>http://weblogs.asp.net/members/farmas.aspx</uri></author></entry><entry><title>CodingQA Podcast Episodes 10-12</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/asptest/archive/2009/07/03/codingqa-podcast-episodes-10-12.aspx" /><id>http://weblogs.asp.net/asptest/archive/2009/07/03/codingqa-podcast-episodes-10-12.aspx</id><published>2009-07-03T14:01:02Z</published><updated>2009-07-03T14:01:02Z</updated><content type="html">&lt;h4&gt;&lt;/h4&gt;  &lt;h4&gt;&lt;a href="http://codingqa.com/index.php?post_id=490794#"&gt;Episode 10 Project Structure &lt;/a&gt;&lt;/h4&gt;  &lt;p&gt;In this show Matthew and Federico talk about how the ASP.NET team structures it’s sources and the theory behind it all. They talk about how the team handles the organization of all of it’s sources and what seems to work well along with what seems to cause hang ups. &lt;/p&gt;  &lt;h4&gt;&lt;a href="http://codingqa.com/index.php?post_id=493601#"&gt;Episode 11 Interviewing Hong Li &lt;/a&gt;&lt;/h4&gt;  &lt;p&gt;In the eleventh installment of &lt;a href="http://www.codingqa.com/"&gt;Coding QA&lt;/a&gt; Federico is on vacation so Matthew sits down with his mentor, Hong Li, for an interview. Join Matthew as he learns a little about one of his fellow team members, servicing an released product, and working with team members that are offshore in China. &lt;/p&gt;  &lt;h4&gt;&lt;a href="http://codingqa.com/index.php?post_id=496207#"&gt;Episode 12 Jim Wang on Microsoft AJAX &lt;/a&gt;&lt;/h4&gt;  &lt;p&gt;In the twelfth installment of &lt;a href="http://www.codingqa.com/"&gt;Coding QA&lt;/a&gt; Federico is still enjoying his vacation so Matthew sits down with his officemate Jim Wang to discuss the ins and outs of test the Microsoft AJAX libraries. Tune in as Matthew picks Jim’s brain on what it was like to test a client side framework. &lt;/p&gt;  &lt;p&gt;&amp;#160; &lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Federico Silva Armas     &lt;br /&gt;SDET, ASP.NET QA Team&lt;/strong&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7139334" width="1" height="1"&gt;</content><author><name>farmas</name><uri>http://weblogs.asp.net/members/farmas.aspx</uri></author><category term="Testing" scheme="http://weblogs.asp.net/asptest/archive/tags/Testing/default.aspx" /><category term="ASP.NET" scheme="http://weblogs.asp.net/asptest/archive/tags/ASP.NET/default.aspx" /></entry><entry><title>How to write a custom log in LTAF June release?</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/asptest/archive/2009/06/10/how-to-write-a-custom-log-in-ltaf-june-release.aspx" /><id>http://weblogs.asp.net/asptest/archive/2009/06/10/how-to-write-a-custom-log-in-ltaf-june-release.aspx</id><published>2009-06-10T19:35:12Z</published><updated>2009-06-10T19:35:12Z</updated><content type="html">&lt;p&gt;If you want to write a custom log while running your test, the June 2009 release of LTAF now provides an easier way to set that up. The DriverPage gives access to a TestcaseExecutor object that exposes several lifecycle events&lt;/p&gt;  &lt;p&gt;Here is a code snippet that shows how to write your own log (MyCustomLog.txt) by attaching to the proper events to gather information while the tests are executing.&lt;/p&gt;  &lt;pre class="code"&gt;&lt;span style="color: blue"&gt;private &lt;/span&gt;&lt;span style="color: #2b91af"&gt;StringBuilder &lt;/span&gt;_log;
&lt;span style="color: blue"&gt;private string &lt;/span&gt;_logPath;

&lt;span style="color: blue"&gt;protected override void &lt;/span&gt;RunTestCases()
{
    &lt;span style="color: green"&gt;// if user checked the Write Log To Disk checkbox
    &lt;/span&gt;&lt;span style="color: blue"&gt;if &lt;/span&gt;(&lt;span style="color: blue"&gt;this&lt;/span&gt;.WriteLogToDiskCheckBox.Checked)
    {
        &lt;span style="color: green"&gt;// attach event handlers to write my custom log
        &lt;/span&gt;&lt;span style="color: blue"&gt;this&lt;/span&gt;.TestcaseExecutor.TestcaseExecuted += 
            &lt;span style="color: blue"&gt;new &lt;/span&gt;&lt;span style="color: #2b91af"&gt;EventHandler&lt;/span&gt;&amp;lt;&lt;span style="color: #2b91af"&gt;TestcaseExecutionEventArgs&lt;/span&gt;&amp;gt;(TestcaseExecutor_TestcaseExecuted);
        
        &lt;span style="color: blue"&gt;this&lt;/span&gt;.TestcaseExecutor.TestRunFinished += 
            &lt;span style="color: blue"&gt;new &lt;/span&gt;&lt;span style="color: #2b91af"&gt;EventHandler&lt;/span&gt;&amp;lt;&lt;span style="color: #2b91af"&gt;TestRunFinishedEventArgs&lt;/span&gt;&amp;gt;(TestcaseExecutor_TestRunFinished);

        &lt;span style="color: blue"&gt;this&lt;/span&gt;.TestcaseExecutor.TestRunStarted += &lt;span style="color: blue"&gt;new &lt;/span&gt;&lt;span style="color: #2b91af"&gt;EventHandler&lt;/span&gt;(TestcaseExecutor_TestRunStarted);

        _logPath = System.IO.&lt;span style="color: #2b91af"&gt;Path&lt;/span&gt;.Combine(Server.MapPath(&lt;span style="color: #a31515"&gt;&amp;quot;&amp;quot;&lt;/span&gt;), &lt;span style="color: #a31515"&gt;&amp;quot;MyCustomLog.txt&amp;quot;&lt;/span&gt;);
        _log = &lt;span style="color: blue"&gt;new &lt;/span&gt;&lt;span style="color: #2b91af"&gt;StringBuilder&lt;/span&gt;();
    }
    
    &lt;span style="color: blue"&gt;base&lt;/span&gt;.RunTestCases();
}

&lt;span style="color: blue"&gt;void &lt;/span&gt;TestcaseExecutor_TestRunStarted(&lt;span style="color: blue"&gt;object &lt;/span&gt;sender, &lt;span style="color: #2b91af"&gt;EventArgs &lt;/span&gt;e)
{
    _log.AppendLine(&lt;span style="color: #a31515"&gt;&amp;quot;Test Run Started.&amp;quot;&lt;/span&gt;);
}

&lt;span style="color: blue"&gt;void &lt;/span&gt;TestcaseExecutor_TestcaseExecuted(&lt;span style="color: blue"&gt;object &lt;/span&gt;sender, &lt;span style="color: #2b91af"&gt;TestcaseExecutionEventArgs &lt;/span&gt;e)
{
    _log.AppendLine(&lt;span style="color: #2b91af"&gt;String&lt;/span&gt;.Format(
        &lt;span style="color: #a31515"&gt;&amp;quot;Finished running test '{0}'. Status='{1}'&amp;quot;&lt;/span&gt;, 
        e.WebTestName, 
        e.Passed));
}

&lt;span style="color: blue"&gt;void &lt;/span&gt;TestcaseExecutor_TestRunFinished(&lt;span style="color: blue"&gt;object &lt;/span&gt;sender, &lt;span style="color: #2b91af"&gt;TestRunFinishedEventArgs &lt;/span&gt;e)
{   
    _log.AppendLine(&lt;span style="color: #a31515"&gt;&amp;quot;Test Run Finished.&amp;quot;&lt;/span&gt;);
    
    &lt;span style="color: green"&gt;// make sure that you have write access to the test folder
    &lt;/span&gt;System.IO.&lt;span style="color: #2b91af"&gt;File&lt;/span&gt;.WriteAllText(_logPath, _log.ToString());
}&lt;/pre&gt;

&lt;p&gt;The &amp;quot;MyCustomLog.txt&amp;quot; file will be written into the same folder where the DriverPage.aspx exists.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Federico Silva Armas 
    &lt;br /&gt;SDET, ASP.NET QA Team&lt;/strong&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7116557" width="1" height="1"&gt;</content><author><name>farmas</name><uri>http://weblogs.asp.net/members/farmas.aspx</uri></author><category term="Testing" scheme="http://weblogs.asp.net/asptest/archive/tags/Testing/default.aspx" /><category term="ASP.NET" scheme="http://weblogs.asp.net/asptest/archive/tags/ASP.NET/default.aspx" /></entry><entry><title>What's new in LTAF June release?</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/asptest/archive/2009/06/10/what-s-new-in-ltaf-june-release.aspx" /><id>http://weblogs.asp.net/asptest/archive/2009/06/10/what-s-new-in-ltaf-june-release.aspx</id><published>2009-06-10T19:34:06Z</published><updated>2009-06-10T19:34:06Z</updated><content type="html">&lt;p&gt;&lt;/p&gt;  &lt;p&gt;The June 2009 release of the Lightweight Test Automation Framework is out on &lt;a href="http://aspnet.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=28536"&gt;CodePlex&lt;/a&gt;. Here is a small write up of the new features available.&lt;/p&gt;  &lt;h3&gt;Automation of frames&lt;/h3&gt;  &lt;p&gt;Now tests can automate pages that contain framesets and iFrames. For example:&lt;/p&gt;  &lt;pre class="code"&gt;[&lt;span style="color: #2b91af"&gt;WebTestMethod&lt;/span&gt;]
    &lt;span style="color: blue"&gt;public void &lt;/span&gt;Frame()
    {
        &lt;span style="color: #2b91af"&gt;HtmlPage &lt;/span&gt;page = &lt;span style="color: blue"&gt;new &lt;/span&gt;&lt;span style="color: #2b91af"&gt;HtmlPage&lt;/span&gt;(&lt;span style="color: #a31515"&gt;&amp;quot;TestFrameSet.htm&amp;quot;&lt;/span&gt;);

        &lt;span style="color: green"&gt;// get top frame
        &lt;/span&gt;&lt;span style="color: #2b91af"&gt;HtmlPage &lt;/span&gt;frame = page.GetFramePage(&lt;span style="color: #a31515"&gt;&amp;quot;topFrame&amp;quot;&lt;/span&gt;);

        &lt;span style="color: green"&gt;// verify title of frame
        &lt;/span&gt;&lt;span style="color: #2b91af"&gt;Assert&lt;/span&gt;.AreEqual(&lt;span style="color: #a31515"&gt;&amp;quot;This is the top frame&amp;quot;&lt;/span&gt;, frame.Elements.Find(&lt;span style="color: #a31515"&gt;&amp;quot;h1&amp;quot;&lt;/span&gt;, 0).GetInnerText());
    }&lt;/pre&gt;
&lt;a href="http://11011.net/software/vspaste"&gt;&lt;/a&gt;

&lt;p&gt;&amp;#160;&lt;/p&gt;

&lt;h3&gt;Write to the test console&lt;/h3&gt;

&lt;p&gt;This is an experimental feature that is useful to debug tests. You can now write messages from your test into the test console that appears in the driver page. For example:&lt;/p&gt;

&lt;pre class="code"&gt;[&lt;span style="color: #2b91af"&gt;WebTestMethod&lt;/span&gt;]
    &lt;span style="color: blue"&gt;public void &lt;/span&gt;PopupPageWithIndex()
    {&lt;span style="color: green"&gt;
        // Navigate to the frameset
        &lt;/span&gt;&lt;span style="color: #2b91af"&gt;HtmlPage &lt;/span&gt;page = &lt;span style="color: blue"&gt;new &lt;/span&gt;&lt;span style="color: #2b91af"&gt;HtmlPage&lt;/span&gt;(&lt;span style="color: #a31515"&gt;&amp;quot;TestFrameSet.htm&amp;quot;&lt;/span&gt;);

        &lt;span style="color: green"&gt;//get the top frame
        &lt;/span&gt;&lt;span style="color: #2b91af"&gt;WebTestConsole&lt;/span&gt;.Write(&lt;span style="color: #a31515"&gt;&amp;quot;Get the top frame&amp;quot;&lt;/span&gt;);
        &lt;span style="color: #2b91af"&gt;HtmlPage &lt;/span&gt;frame = page.GetFramePage(&lt;span style="color: #a31515"&gt;&amp;quot;topFrame&amp;quot;&lt;/span&gt;);

        &lt;span style="color: green"&gt;// click on the button that opens a new page
        &lt;/span&gt;&lt;span style="color: #2b91af"&gt;WebTestConsole&lt;/span&gt;.Write(&lt;span style="color: #a31515"&gt;&amp;quot;Click the openwindow button&amp;quot;&lt;/span&gt;);
        frame.Elements.Find(&lt;span style="color: #a31515"&gt;&amp;quot;OpenWindow&amp;quot;&lt;/span&gt;).Click();

    ...&lt;/pre&gt;
&lt;a href="http://11011.net/software/vspaste"&gt;&lt;/a&gt;

&lt;p&gt;When run, this test will output traces into the console UI:&lt;/p&gt;

&lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/asptest/WindowsLiveWriter/WhatsnewinLTAFJunerelease_F0FB/image_2.png"&gt;&lt;img style="border-right-width: 0px; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" border="0" alt="image" src="http://weblogs.asp.net/blogs/asptest/WindowsLiveWriter/WhatsnewinLTAFJunerelease_F0FB/image_thumb.png" width="754" height="246" /&gt;&lt;/a&gt; &lt;/p&gt;

&lt;h3&gt;&amp;#160;&lt;/h3&gt;

&lt;h3&gt;Hide the test console&lt;/h3&gt;

&lt;p&gt;New option in the UI allows user to hide the test console. This is useful for long running test suites, to prevent the browser from maintain a grown list of commands.&lt;/p&gt;

&lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/asptest/WindowsLiveWriter/WhatsnewinLTAFJunerelease_F0FB/image_4.png"&gt;&lt;img style="border-right-width: 0px; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" border="0" alt="image" src="http://weblogs.asp.net/blogs/asptest/WindowsLiveWriter/WhatsnewinLTAFJunerelease_F0FB/image_thumb_1.png" width="447" height="123" /&gt;&lt;/a&gt; &lt;/p&gt;

&lt;h3&gt;&amp;#160;&lt;/h3&gt;

&lt;h3&gt;Quickly verify page is rendering an asp.net error&lt;/h3&gt;

&lt;p&gt;New helper method in HtmlPage makes it easy to quickly verify if a asp.net error page is being rendered. This is useful to immediately stop the test if an error has occurred, instead of waiting for a timeout. For example:&lt;/p&gt;

&lt;pre class="code"&gt;[&lt;span style="color: #2b91af"&gt;WebTestMethod&lt;/span&gt;]
    &lt;span style="color: blue"&gt;public void &lt;/span&gt;VerifyTheAspNetErrorPage()
    {
        &lt;span style="color: #2b91af"&gt;HtmlPage &lt;/span&gt;p = &lt;span style="color: blue"&gt;new &lt;/span&gt;&lt;span style="color: #2b91af"&gt;HtmlPage&lt;/span&gt;(&lt;span style="color: #a31515"&gt;&amp;quot;PageWithError.aspx&amp;quot;&lt;/span&gt;);
        &lt;span style="color: blue"&gt;bool &lt;/span&gt;pageFail = p.IsServerError();
        &lt;span style="color: #2b91af"&gt;Assert&lt;/span&gt;.IsFalse(pageFail);

        ...
    }&lt;/pre&gt;
&lt;a href="http://11011.net/software/vspaste"&gt;&lt;/a&gt;

&lt;p&gt;&amp;#160;&lt;/p&gt;

&lt;h3&gt;Exposed test run lifecycle events&lt;/h3&gt;

&lt;p&gt;Users can now register handlers in the DriverPage.aspx to several life cycle events. This is useful, for example, to generate a custom log:&lt;/p&gt;

&lt;pre class="code"&gt;&lt;span style="color: blue"&gt;protected override void &lt;/span&gt;RunTestCases()
   {
       &lt;span style="color: green"&gt;// if user checked the Write Log To Disk checkbox
       &lt;/span&gt;&lt;span style="color: blue"&gt;if &lt;/span&gt;(&lt;span style="color: blue"&gt;this&lt;/span&gt;.WriteLogToDiskCheckBox.Checked)
       {
           &lt;span style="color: green"&gt;// attach event handlers to write my custom log
           &lt;/span&gt;&lt;span style="color: blue"&gt;this&lt;/span&gt;.TestcaseExecutor.TestcaseExecuted += 
               &lt;span style="color: blue"&gt;new &lt;/span&gt;&lt;span style="color: #2b91af"&gt;EventHandler&lt;/span&gt;&amp;lt;&lt;span style="color: #2b91af"&gt;TestcaseExecutionEventArgs&lt;/span&gt;&amp;gt;(TestcaseExecutor_TestcaseExecuted);
           
           &lt;span style="color: blue"&gt;this&lt;/span&gt;.TestcaseExecutor.TestRunFinished += 
               &lt;span style="color: blue"&gt;new &lt;/span&gt;&lt;span style="color: #2b91af"&gt;EventHandler&lt;/span&gt;&amp;lt;&lt;span style="color: #2b91af"&gt;TestRunFinishedEventArgs&lt;/span&gt;&amp;gt;(TestcaseExecutor_TestRunFinished);    
       }
       
       &lt;span style="color: blue"&gt;base&lt;/span&gt;.RunTestCases();
   }&lt;/pre&gt;
&lt;a href="http://11011.net/software/vspaste"&gt;&lt;/a&gt;

&lt;p&gt;&amp;#160;&lt;/p&gt;

&lt;h3&gt;&lt;/h3&gt;

&lt;h3&gt;Additional Resources&lt;/h3&gt;

&lt;ul&gt;
  &lt;li&gt;Visit our &lt;a href="http://forums.asp.net/1193.aspx"&gt;forum&lt;/a&gt; for any questions and feedback &lt;/li&gt;

  &lt;li&gt;&lt;a href="http://aspnet.codeplex.com/Wiki/View.aspx?title=Lightweight%20Test%20Automation%20Framework%20known%20issues"&gt;List of known issues&lt;/a&gt; &lt;/li&gt;

  &lt;li&gt;&lt;a href="http://aspnet.codeplex.com/Wiki/View.aspx?title=Lightweight%20Test%20Automation%20Framework%20Release%20History&amp;amp;referringTitle=Home"&gt;Release history&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&amp;#160;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Federico Silva Armas 
    &lt;br /&gt;SDET, ASP.NET QA Team&lt;/strong&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7116556" width="1" height="1"&gt;</content><author><name>farmas</name><uri>http://weblogs.asp.net/members/farmas.aspx</uri></author><category term="Testing" scheme="http://weblogs.asp.net/asptest/archive/tags/Testing/default.aspx" /><category term="ASP.NET" scheme="http://weblogs.asp.net/asptest/archive/tags/ASP.NET/default.aspx" /></entry><entry><title>CodingQA Podcast Episode 9</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/asptest/archive/2009/06/06/codingqa-podcast-episode-9.aspx" /><id>http://weblogs.asp.net/asptest/archive/2009/06/06/codingqa-podcast-episode-9.aspx</id><published>2009-06-06T16:09:38Z</published><updated>2009-06-06T16:09:38Z</updated><content type="html">&lt;p&gt;&lt;strong&gt;Download&lt;/strong&gt;: &lt;a href="http://media.libsyn.com/media/aspnetqa/CodingQAEpisode9.mp3"&gt;Episode 9&lt;/a&gt;     &lt;br /&gt;&lt;strong&gt;Streaming&lt;/strong&gt;: &lt;a href="http://codingqa.com/index.php?post_id=488153#"&gt;Episode 9&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;In this show Matthew and Federico talk about what the ASP.NET QA team does to prepare for a release. Taking into account the recent release of ASP.NET 4 Beta 1, they’ll go over several of the &amp;quot;exit criteria&amp;quot; that the product must meet before delivery to the public. &lt;/p&gt;  &lt;p&gt;News&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;Lightweight Test Automation Framework June Release &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;Sign off on a release&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;Difference between Quality Gates and Exit Criteria &lt;/li&gt;    &lt;li&gt;Accessibility. Mainly manual tests to validate feature conforms to accessibility standards. &lt;/li&gt;    &lt;li&gt;Code Coverage. Metric used to identify problematic development areas. &lt;/li&gt;    &lt;li&gt;Stress. Specialized automated long running tests to spot memory leaks and other stress problems. &lt;/li&gt;    &lt;li&gt;Localization. Verification that the product can be correctly localized to several languages. &lt;/li&gt;    &lt;li&gt;Test Passes. Functional verification of the product across many platform combinations. &lt;/li&gt;    &lt;li&gt;Zero Active Bugs. Series of step down goals to drive feature crews to finish development. &lt;/li&gt; &lt;/ul&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7109715" width="1" height="1"&gt;</content><author><name>farmas</name><uri>http://weblogs.asp.net/members/farmas.aspx</uri></author><category term="Testing" scheme="http://weblogs.asp.net/asptest/archive/tags/Testing/default.aspx" /><category term="ASP.NET" scheme="http://weblogs.asp.net/asptest/archive/tags/ASP.NET/default.aspx" /></entry><entry><title>CodingQA Podcast Episode 8</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/asptest/archive/2009/06/06/codingqa-podcast-episode-8.aspx" /><id>http://weblogs.asp.net/asptest/archive/2009/06/06/codingqa-podcast-episode-8.aspx</id><published>2009-06-06T16:06:30Z</published><updated>2009-06-06T16:06:30Z</updated><content type="html">&lt;p&gt;&lt;strong&gt;Download&lt;/strong&gt;: &lt;a href="http://media.libsyn.com/media/aspnetqa/CodingQAEpisode8.mp3"&gt;Episode 8&lt;/a&gt;    &lt;br /&gt;&lt;strong&gt;Streaming&lt;/strong&gt;: &lt;a href="http://codingqa.com/index.php?post_id=485096#"&gt;Episode 8&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;This show is an open discussion about what testing means. Federico and Matthew share their opinions around the meaning of &amp;quot;testing&amp;quot;, &amp;quot;quality&amp;quot; and the role of a QA team. They don't always agree but each brings something unique to the table on topics so basic yet somewhat mysterious in the testing discipline. &lt;/p&gt;  &lt;p&gt;&lt;strong&gt;News&lt;/strong&gt;&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;&lt;a href="http://msdn.microsoft.com/en-us/vstudio/dd582936.aspx"&gt;Release of .NET Framework 4 Beta 1&lt;/a&gt;&lt;/li&gt;    &lt;li&gt;&lt;a href="http://msdn.microsoft.com/en-us/vstudio/dd582936.aspx"&gt;Release of Visual Studio 2010 Beta 1&lt;/a&gt;&lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;&lt;strong&gt;Topics of Discussion&lt;/strong&gt;&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;What is the role of QA? &lt;/li&gt;    &lt;li&gt;What is testing? &lt;/li&gt;    &lt;li&gt;What is quality? &lt;/li&gt;    &lt;li&gt;Should quality be measurable? &lt;/li&gt;    &lt;li&gt;What is risk? &lt;/li&gt;    &lt;li&gt;What is the difference between Dev and Test? &lt;/li&gt; &lt;/ul&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7109714" width="1" height="1"&gt;</content><author><name>farmas</name><uri>http://weblogs.asp.net/members/farmas.aspx</uri></author><category term="Testing" scheme="http://weblogs.asp.net/asptest/archive/tags/Testing/default.aspx" /><category term="ASP.NET" scheme="http://weblogs.asp.net/asptest/archive/tags/ASP.NET/default.aspx" /></entry><entry><title>CodingQA Podcast Episode 7</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/asptest/archive/2009/05/25/codingqa-podcast-episode-7.aspx" /><id>http://weblogs.asp.net/asptest/archive/2009/05/25/codingqa-podcast-episode-7.aspx</id><published>2009-05-26T03:28:46Z</published><updated>2009-05-26T03:28:46Z</updated><content type="html">&lt;p&gt;&lt;strong&gt;Download&lt;/strong&gt;: &lt;a href="http://media.libsyn.com/media/aspnetqa/CodingQAEpisode7.mp3"&gt;Episode 7&lt;/a&gt;     &lt;br /&gt;&lt;strong&gt;Streaming&lt;/strong&gt;: &lt;a href="http://www.codingqa.com/index.php?post_id=482513"&gt;Episode 7&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;In this show Federico and Matthew talk about what exploratory testing (ET) is and how the ASP.NET QA team uses this methodology for testing. &lt;/p&gt;  &lt;p&gt;News&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;&lt;a href="http://aspnet.codeplex.com/Wiki/View.aspx?title=Dynamic%20Data"&gt;Dynamic Data release in CodePlex.com&lt;/a&gt; &lt;/li&gt;    &lt;li&gt;TechEd 2009 &lt;/li&gt;    &lt;li&gt;&lt;a href="http://www.asp.net/ajax/AjaxControlToolkit/Samples/"&gt;Ajax Control Toolkit Refresh released&lt;/a&gt;. &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;Exploratory Testing&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;Definition &lt;/li&gt;    &lt;li&gt;Differences between exploratory testing and scripted testing &lt;/li&gt;    &lt;li&gt;Differences between exploratory testing and ad-hoc testing &lt;/li&gt;    &lt;li&gt;The 4 principles of exploratory testing      &lt;ul&gt;       &lt;li&gt;Creativity &lt;/li&gt;        &lt;li&gt;Goal oriented &lt;/li&gt;        &lt;li&gt;Reproducibility &lt;/li&gt;        &lt;li&gt;Adaptability &lt;/li&gt;     &lt;/ul&gt;   &lt;/li&gt;    &lt;li&gt;How the ASP.NET QA team uses exploratory testing &lt;/li&gt;    &lt;li&gt;When is exploratory testing a good fit to test a product &lt;/li&gt;    &lt;li&gt;Brief example of an exploratory testing session &lt;/li&gt;    &lt;li&gt;What are the outcomes of an exploratory testing session      &lt;ul&gt;       &lt;li&gt;Scenarios tried &lt;/li&gt;        &lt;li&gt;Questions &lt;/li&gt;        &lt;li&gt;Assumptions &lt;/li&gt;        &lt;li&gt;Defects &lt;/li&gt;        &lt;li&gt;Future scenarios &lt;/li&gt;     &lt;/ul&gt;   &lt;/li&gt; &lt;/ul&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7097750" width="1" height="1"&gt;</content><author><name>farmas</name><uri>http://weblogs.asp.net/members/farmas.aspx</uri></author><category term="Testing" scheme="http://weblogs.asp.net/asptest/archive/tags/Testing/default.aspx" /><category term="ASP.NET" scheme="http://weblogs.asp.net/asptest/archive/tags/ASP.NET/default.aspx" /></entry><entry><title>CodingQA Podcast Episode 6</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/asptest/archive/2009/05/21/codingqa-podcast-episode-6.aspx" /><id>http://weblogs.asp.net/asptest/archive/2009/05/21/codingqa-podcast-episode-6.aspx</id><published>2009-05-22T03:29:40Z</published><updated>2009-05-22T03:29:40Z</updated><content type="html">&lt;p&gt;&lt;strong&gt;Download&lt;/strong&gt;: &lt;a href="http://media.libsyn.com/media/aspnetqa/CodingQAEpisode6.mp3"&gt;Episode 6&lt;/a&gt;     &lt;br /&gt;&lt;strong&gt;Streaming&lt;/strong&gt;: &lt;a href="http://codingqa.com/index.php?post_id=479060#"&gt;Episode 6&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;In this show Federico and Matthew explore the question of &amp;quot;when too much automation is too much?&amp;quot; Based on their experiences in the ASP.NET QA team, they talk about the danger of automating for the sake of automation, the problems that it can create, and the value of context driven testing.&lt;/p&gt;  &lt;p&gt;News&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;New name and name website: Coding QA. &lt;/li&gt;    &lt;li&gt;.NET Micro Framework has been open sourced. &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;Automation for the sake of automation&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;What is the goal of automation? To find bugs during development vs. to find regressions after development. &lt;/li&gt;    &lt;li&gt;What problems can arise from having too much automation? The tale of the ASP.NET QA &amp;quot;boat anchor&amp;quot;. &lt;/li&gt;    &lt;li&gt;Context matters when deciding how to ensure a feature does not regress. &lt;/li&gt;    &lt;li&gt;What parameters can be used to decide the testing approach      &lt;ul&gt;       &lt;li&gt;Automation cost. &lt;/li&gt;        &lt;li&gt;Time of delivery. &lt;/li&gt;        &lt;li&gt;Resources available. &lt;/li&gt;        &lt;li&gt;Risk of a regression. &lt;/li&gt;        &lt;li&gt;Customer impact if a regression is introduced. &lt;/li&gt;        &lt;li&gt;Quickness between when the regression is introduced and when it is discovered. &lt;/li&gt;     &lt;/ul&gt;   &lt;/li&gt;    &lt;li&gt;Real examples from the team      &lt;ul&gt;       &lt;li&gt;Testing event handler generation for web controls in VS. &lt;/li&gt;        &lt;li&gt;Testing picker dialogs for web controls in VS. &lt;/li&gt;     &lt;/ul&gt;   &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Federico Silva Armas     &lt;br /&gt;SDET, ASP.NET QA Team&lt;/strong&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7094487" width="1" height="1"&gt;</content><author><name>farmas</name><uri>http://weblogs.asp.net/members/farmas.aspx</uri></author><category term="Testing" scheme="http://weblogs.asp.net/asptest/archive/tags/Testing/default.aspx" /><category term="ASP.NET" scheme="http://weblogs.asp.net/asptest/archive/tags/ASP.NET/default.aspx" /></entry><entry><title>CodingQA Podcast - Episode 5</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/asptest/archive/2009/05/17/codingqa-podcast-episode-5.aspx" /><id>http://weblogs.asp.net/asptest/archive/2009/05/17/codingqa-podcast-episode-5.aspx</id><published>2009-05-17T05:19:08Z</published><updated>2009-05-17T05:19:08Z</updated><content type="html">&lt;p&gt;&lt;strong&gt;Download&lt;/strong&gt;: &lt;a href="http://media.libsyn.com/media/aspnetqa/CodingQAEpisode5.mp3"&gt;Episode 5&lt;/a&gt;    &lt;br /&gt;&lt;strong&gt;Streaming&lt;/strong&gt;: &lt;a href="http://codingqa.com/index.php?post_id=475884#"&gt;Episode 5&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;In this episode Matthew interviews Carl Dacosta, lead tester for the MVC 1.0 project, and talks about what it was like to develop and test a product with so many releases. &lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;MVC crossed the 100,000 downloads mark (currently at 140,000) &lt;/li&gt;    &lt;li&gt;MVC released under MS-PL license &lt;/li&gt;    &lt;li&gt;Interview with Carl Dacosta      &lt;ul&gt;       &lt;li&gt;Some history on Carl and how he got into test. &lt;/li&gt;        &lt;li&gt;Role of Carl as a tester in the MVC crew. &lt;/li&gt;        &lt;li&gt;What was the development and testing process of MVC to enable frequent releases. &lt;/li&gt;        &lt;li&gt;Parts of the testing process that worked well for this kind of project, and parts that didn't work so well. &lt;/li&gt;        &lt;li&gt;How to handle quality of releases when external partners are starting to rely on the framework. &lt;/li&gt;        &lt;li&gt;What did Carl enjoy the most working on the MVC crew. &lt;/li&gt;        &lt;li&gt;Testing the &amp;quot;unit testing&amp;quot; experience for developers working on MVC. &lt;/li&gt;     &lt;/ul&gt;   &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Federico Silva Armas     &lt;br /&gt;SDET, ASP.NET QA Team&lt;/strong&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7091206" width="1" height="1"&gt;</content><author><name>farmas</name><uri>http://weblogs.asp.net/members/farmas.aspx</uri></author><category term="Testing" scheme="http://weblogs.asp.net/asptest/archive/tags/Testing/default.aspx" /><category term="ASP.NET" scheme="http://weblogs.asp.net/asptest/archive/tags/ASP.NET/default.aspx" /></entry><entry><title>CodingQA Podcast Feed</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/asptest/archive/2009/05/17/codingqa-podcast-feed.aspx" /><id>http://weblogs.asp.net/asptest/archive/2009/05/17/codingqa-podcast-feed.aspx</id><published>2009-05-17T05:17:26Z</published><updated>2009-05-17T05:17:26Z</updated><content type="html">&lt;p&gt;We now have a proper feed for our podcast, head over to &lt;a href="http://codingqa.com/"&gt;codingqa.com&lt;/a&gt; to subscribe. You can also find us in iTunes and very soon in Zune Marketplace as well.&amp;#160; &lt;/p&gt;  &lt;p&gt;For the time being I’ll keep posting here whenever an episode comes out. .&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Federico Silva Armas     &lt;br /&gt;SDET, ASP.NE QA Team&lt;/strong&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7091204" width="1" height="1"&gt;</content><author><name>farmas</name><uri>http://weblogs.asp.net/members/farmas.aspx</uri></author><category term="Testing" scheme="http://weblogs.asp.net/asptest/archive/tags/Testing/default.aspx" /><category term="ASP.NET" scheme="http://weblogs.asp.net/asptest/archive/tags/ASP.NET/default.aspx" /></entry><entry><title>Web Accessibility Standards</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/asptest/archive/2009/04/29/web-accessibility-standards.aspx" /><id>http://weblogs.asp.net/asptest/archive/2009/04/29/web-accessibility-standards.aspx</id><published>2009-04-29T20:29:55Z</published><updated>2009-04-29T20:29:55Z</updated><content type="html">&lt;p&gt;Due to some test activities that I have been engaged on lately I have had to educate myself in regards to web standards. One of our PM's sent me this &lt;a href="http://www.mass.gov/?pageID=itdmodulechunk&amp;amp;&amp;amp;L=3&amp;amp;L0=Home&amp;amp;L1=Application+Services&amp;amp;L2=Portal+Products+%26+Services&amp;amp;sid=Aitd&amp;amp;b=terminalcontent&amp;amp;f=policies_standards_web_accessibility&amp;amp;csid=Aitd"&gt;&lt;strong&gt;link&lt;/strong&gt;&lt;/a&gt; that I want to share out with any testers out there that are not aware of it. This is a document found within the Massachusetts government website, and I am not sure if it is somehow special for that state (it's from 2005, so a little old). Even though it is not a replacement for Section 508, I liked the way it is presented because for each standard it explains &amp;quot;why&amp;quot; the standard is needed and &amp;quot;what' it means with examples. I include the list of standards that are defined:&lt;/p&gt;  &lt;p&gt;&lt;em&gt;1. Layout and Design&lt;/em&gt;&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;Standard 1.1: A state agency web page must use HTML markup tags according to industry standards. &lt;/li&gt;    &lt;li&gt;Standard 1.2: A state agency web page should control presentation with style sheets, but the web pages must be organized so they are readable without requiring an associated style sheet. &lt;/li&gt;    &lt;li&gt;&lt;a name="frames"&gt;Standard 1.3: A state agency web page should avoid using frames.&lt;/a&gt; &lt;/li&gt;    &lt;li&gt;Standard 1.4: State agencies must ensure that their web pages are usable when scripts, applets, or other programmed objects are turned off or are not supported. &lt;/li&gt;    &lt;li&gt;&lt;a name="forms"&gt;Standard 1.5: Forms designed to be completed online, and other interactive interface elements, must be accessible by people using assistive technology.&lt;/a&gt; &lt;/li&gt;    &lt;li&gt;Standard 1.6: When a timed response is required, the user must be provided the opportunity to request additional time to continue working before the time-out occurs. &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;&lt;em&gt;2. Navigation&lt;/em&gt;&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;&lt;a name="clear"&gt;Standard 2.1: A state agency web page must use clear and consistent navigation mechanisms.&lt;/a&gt; &lt;/li&gt;    &lt;li&gt;Standard 2.2: A state agency must ensure that users are able to interact with web page elements in a device independent manner. &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;&lt;em&gt;3. Graphics and Sound&lt;/em&gt;&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;&lt;a name="nontext"&gt;Standard 3.1: A state agencyweb page must provide a text equivalent for every non-text element.&lt;/a&gt; &lt;/li&gt;    &lt;li&gt;Standard 3.2: A state agency web page must provide synchronized auditory and readable text descriptions of the important information of the visual track of a multimedia presentation. &lt;/li&gt;    &lt;li&gt;Standard 3.3: A state agency web page must provide a text equivalent for information provided in audio format. &lt;/li&gt;    &lt;li&gt;Standard 3.4: A state agency web page that uses motion must ensure that the motion is integral to the content of the site, user-controlled, and limited to three cycles and then stopped automatically. &lt;/li&gt;    &lt;li&gt;Standard 3.5: A state agency must ensure that the use and selection of color do not affect the information conveyed on a page. &lt;/li&gt;    &lt;li&gt;Standard 3.6: Client-side image maps are recommended. If server-side image maps must be used, provide redundant text links for each active region. &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;&lt;em&gt;4. Content Requiring Additional Software&lt;/em&gt;&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;&lt;a name="html"&gt;Standard 4.1: All information published on a state agency web page must be published in HTML, whenever possible, to eliminate the need for additional software.&lt;/a&gt; &lt;/li&gt;    &lt;li&gt;Standard 4.2: A state agency that offers files to download in compressed format (Zip files, for example) must also provide the same information in its uncompressed format or as a self extracting file. &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;&lt;em&gt;5. File Size&lt;/em&gt;&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;&lt;a name="optimization"&gt;Standard 5.1: A state agency must optimize files to improve download time.&lt;/a&gt; &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;&lt;em&gt;6. Web Accessibility Statement&lt;/em&gt;&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;&lt;a name="accessibilitystatement"&gt;Standard 6.1: A state agency web site must provide a link to a web accessibility statement.&lt;/a&gt; &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;&lt;em&gt;7. Web Site Validation&lt;/em&gt;&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;&lt;a name="standards"&gt;Standard 7.1: A state agency must validate web content against these Standards prior to posting and at regular intervals after posting.&lt;/a&gt; &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Federico Silva Armas      &lt;br /&gt;SDET, ASP.NET QA Team&lt;/strong&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7064996" width="1" height="1"&gt;</content><author><name>farmas</name><uri>http://weblogs.asp.net/members/farmas.aspx</uri></author><category term="Testing" scheme="http://weblogs.asp.net/asptest/archive/tags/Testing/default.aspx" /><category term="ASP.NET" scheme="http://weblogs.asp.net/asptest/archive/tags/ASP.NET/default.aspx" /></entry><entry><title>ASP.NET QA Podcast – Episode 4</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/asptest/archive/2009/04/13/asp-net-qa-podcast-episode-4.aspx" /><id>http://weblogs.asp.net/asptest/archive/2009/04/13/asp-net-qa-podcast-episode-4.aspx</id><published>2009-04-13T21:54:00Z</published><updated>2009-04-13T21:54:00Z</updated><content type="html">&lt;IFRAME style="MARGIN: 10px 0px" height=25 src="http://silverlight.services.live.com/invoke/27911/ASPNETQAPodcast4/iframe.html" frameBorder=0 width=266 scrolling=no mce_src="http://silverlight.services.live.com/invoke/27911/ASPNETQAPodcast4/iframe.html"&gt;&lt;/IFRAME&gt;
&lt;P&gt;&lt;FONT size=2&gt;&lt;STRONG&gt;Download :&lt;/STRONG&gt; &lt;/FONT&gt;&lt;FONT size=2&gt;&lt;A href="http://cid-b387831f07f582b4.skydrive.live.com/self.aspx/ASP.NET%20QA%20Podcast/AspNetQAPodcast4.mp3"&gt;Episode 4&lt;/A&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;In the fourth installment of the ASP.NET QA Podcast Federico and Matthew discuss “&lt;STRONG&gt;The Good&lt;/STRONG&gt;,” “&lt;STRONG&gt;The Bad&lt;/STRONG&gt;,” and “&lt;STRONG&gt;The Ugly&lt;/STRONG&gt;” of the history of the ASP.NET QA Team. Discussion ranges from the dark ages, to the renaissance, to the industrial revolution, to the “21st and half century”.&amp;nbsp; Join them as they discuss the lessons learned and how the team has improved over time. &lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;The team released the April update to the Lightweight Test Automation Framework. &lt;/LI&gt;
&lt;LI&gt;“&lt;STRONG&gt;The Dark Ages&lt;/STRONG&gt;” ASP.NET 1.0/2.0 
&lt;UL&gt;
&lt;LI&gt;During this time the team was very focused on automating everything. &lt;/LI&gt;
&lt;LI&gt;(&lt;EM&gt;disadvantage&lt;/EM&gt;) This approach is not good with a changing Spec. &lt;/LI&gt;
&lt;LI&gt;(&lt;EM&gt;disadvantage&lt;/EM&gt;) Bugs were being found to late in the process. &lt;/LI&gt;
&lt;LI&gt;(advantage) Excellent automation coverage. &lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;
&lt;LI&gt;“&lt;STRONG&gt;The Renaissance&lt;/STRONG&gt;” Atlas/Microsoft Ajax 
&lt;UL&gt;
&lt;LI&gt;The division moved to a feature crew model for development and QA. &lt;/LI&gt;
&lt;LI&gt;(advantage) The team adopted a heavy unit testing practice. Increase in code coverage. &lt;/LI&gt;
&lt;LI&gt;(&lt;EM&gt;disadvantage&lt;/EM&gt;) The QA team still worked has it had before. It would automate everything is less time. &lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;
&lt;LI&gt;“&lt;STRONG&gt;The Industrial Revolution&lt;/STRONG&gt;” ASP.NET 3.5 
&lt;UL&gt;
&lt;LI&gt;The QA team began to adopt the Feature crew model and started the process of agile testing with exploratory testing. &lt;/LI&gt;
&lt;LI&gt;(&lt;EM&gt;advantage&lt;/EM&gt;) Bugs were being found at the beginning of the process. &lt;/LI&gt;
&lt;LI&gt;(&lt;EM&gt;disadvantage&lt;/EM&gt;) The team still wrote a large amount of automation. &lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;
&lt;LI&gt;“&lt;STRONG&gt;21st and half century&lt;/STRONG&gt;” ASP.NET 3.5 SP1/ASP.NET 4.0/vNext 
&lt;UL&gt;
&lt;LI&gt;The team has really started moving away from automating everything and is spending more time investigating user scenarios. &lt;/LI&gt;
&lt;LI&gt;The team has formed its own unique blend of agile, scrum, and any other buzz word project management theory. &lt;/LI&gt;
&lt;LI&gt;(&lt;EM&gt;advantage&lt;/EM&gt;) Creating and automating sample applications provides feedback for real world customer scenarios. &lt;/LI&gt;
&lt;LI&gt;(&lt;EM&gt;disadvantage&lt;/EM&gt;) The team is young and is still learning the best practices. &lt;/LI&gt;
&lt;LI&gt;(&lt;EM&gt;Struggle&lt;/EM&gt;) Costing has become less of a clear cut process. &lt;/LI&gt;
&lt;LI&gt;(&lt;EM&gt;Struggle&lt;/EM&gt;) The is still a barrier between the QA and Dev teams. &lt;/LI&gt;
&lt;LI&gt;(&lt;EM&gt;Struggle&lt;/EM&gt;) No one wants the blame when a bug is found. &lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;STRONG&gt;Links from the show :&lt;/STRONG&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;A href="http://aspnet.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=25887"&gt;Lightweight Test Automation Framework April Release&lt;/A&gt; &lt;/LI&gt;
&lt;LI&gt;&lt;A href="mailto:farmas@microsoft.com" mce_href="mailto:farmas@microsoft.com"&gt;Federico’s Email&lt;/A&gt; &lt;/LI&gt;
&lt;LI&gt;&lt;A href="mailto:mosborn@microsoft.com" mce_href="mailto:mosborn@microsoft.com"&gt;Matthew’ Email&lt;/A&gt; &lt;/LI&gt;
&lt;LI&gt;&lt;A href="http://weblogs.asp.net/asptest" mce_href="http://weblogs.asp.net/asptest"&gt;ASP.NET QA Team Blog&lt;/A&gt; &lt;/LI&gt;&lt;/UL&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7045470" width="1" height="1"&gt;</content><author><name>osbornm</name><uri>http://weblogs.asp.net/members/osbornm.aspx</uri></author><category term="Testing" scheme="http://weblogs.asp.net/asptest/archive/tags/Testing/default.aspx" /><category term="ASP.NET" scheme="http://weblogs.asp.net/asptest/archive/tags/ASP.NET/default.aspx" /><category term="Podcast" scheme="http://weblogs.asp.net/asptest/archive/tags/Podcast/default.aspx" /></entry><entry><title>Lightweight Test Automation Framework April Release</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/asptest/archive/2009/04/09/lightweight-test-automation-framework-april-release.aspx" /><id>http://weblogs.asp.net/asptest/archive/2009/04/09/lightweight-test-automation-framework-april-release.aspx</id><published>2009-04-09T19:07:00Z</published><updated>2009-04-09T19:07:00Z</updated><content type="html">&lt;P&gt;The April release of the Lightweight Test Automation Framework for ASP.NET has just been posted and you can download it &lt;A title="April Update" href="http://aspnet.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=25887" mce_href="http://aspnet.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=25887"&gt;here&lt;/A&gt;. For this release, the team has worked hard to include the following bug fixes and new features. Please continue to give us your feedback as many of the fixes and features are based what we have heard from the community.&lt;/P&gt;
&lt;H3&gt;Improvements to the user interface&lt;/H3&gt;
&lt;UL&gt;
&lt;LI&gt;
&lt;DIV align=left&gt;A new look has been given to the test name when it passes or fails.&amp;nbsp; There is both color and visual queues that indicate weather a test has passed or failed.&amp;nbsp; Failed test names also appear slightly larger to help them stand out. &lt;/DIV&gt;&lt;/LI&gt;
&lt;LI&gt;
&lt;DIV align=left&gt;There is now a “Run Failed Tests” button. This button will open a new browser window that will select and run only the failed tests, for easy verification of fixes. &lt;/DIV&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;IMG style="BORDER-RIGHT-WIDTH: 0px; DISPLAY: inline; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; MARGIN-LEFT: 0px; BORDER-LEFT-WIDTH: 0px; MARGIN-RIGHT: 0px" title=NewUI2 border=0 alt=NewUI2 align=left src="http://weblogs.asp.net/blogs/asptest/NewUI2_3C8C3F9E.png" width=504 height=363 mce_src="http://weblogs.asp.net/blogs/asptest/NewUI2_3C8C3F9E.png"&gt; &lt;BR style="CLEAR: both"&gt;
&lt;H3&gt;The ability to automate popup windows&lt;/H3&gt;
&lt;P&gt;In previous versions of the framework there was no way to verify the contents of a popup window.&amp;nbsp; With this release we have far better support for opening and verifying the contents of popup windows.&lt;/P&gt;&lt;PRE class=code&gt;&lt;SPAN style="COLOR: #2b91af"&gt;HtmlPage &lt;/SPAN&gt;page = &lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: #2b91af"&gt;HtmlPage&lt;/SPAN&gt;(&lt;SPAN style="COLOR: #a31515"&gt;"MyPage.aspx"&lt;/SPAN&gt;);
page.Elements.Find(&lt;SPAN style="COLOR: #a31515"&gt;"OpenPopup"&lt;/SPAN&gt;).Click();
&lt;SPAN style="COLOR: green"&gt;// get popup window
&lt;/SPAN&gt;&lt;SPAN style="COLOR: #2b91af"&gt;HtmlPage &lt;/SPAN&gt;popup = page.GetPopupWindow(1);
&lt;SPAN style="COLOR: green"&gt;// verify title of popup
&lt;/SPAN&gt;&lt;SPAN style="COLOR: #2b91af"&gt;Assert&lt;/SPAN&gt;.AreEqual(&lt;SPAN style="COLOR: #a31515"&gt;"This is the Popup Page"&lt;/SPAN&gt;, popup.Elements.Find(&lt;SPAN style="COLOR: #a31515"&gt;"h1"&lt;/SPAN&gt;, 0).GetInnerText());&lt;/PRE&gt;&lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;/A&gt;
&lt;P&gt;The GetPopupWindow method returns a HtmlPage object that is representative of the window at that index.&amp;nbsp; This is pulled from the collection that is maintained by the framework with index zero being the main, or starting, window. In this example index zero is MyPage.aspx, while index one is the popup window.&amp;nbsp; &lt;/P&gt;
&lt;H3&gt;The ability to find elements by partial attribute values&lt;/H3&gt;
&lt;P&gt;In previous versions of the framework when finding elements on a page you could only use the ID attribute to match against.&amp;nbsp; So if you wanted to match all the elements that had a CSS class applied to them, as is common in jQuery, you had to supply that whole value for the class attribute.&amp;nbsp; So, in previous versions of the framework if you wanted to find elements that had a CSS class applied to them you had to specify the whole value for the class attribute.&amp;nbsp; Meaning that if the element has more than only class and you search based on only one class that element would not be returned.&amp;nbsp; Now you have the ability to match based on any part of the value for the attribute. Below is an example of how to find elements that have the CSS Class “blue” applied to them.&lt;/P&gt;&lt;PRE class=code&gt;&lt;SPAN style="COLOR: #2b91af"&gt;HtmlElementFindParams &lt;/SPAN&gt;find = &lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: #2b91af"&gt;HtmlElementFindParams&lt;/SPAN&gt;();
find.Attributes.Add(&lt;SPAN style="COLOR: #a31515"&gt;"class"&lt;/SPAN&gt;, &lt;SPAN style="COLOR: #a31515"&gt;"blue"&lt;/SPAN&gt;, &lt;SPAN style="COLOR: #2b91af"&gt;MatchMethod&lt;/SPAN&gt;.Contains);
&lt;SPAN style="COLOR: #2b91af"&gt;ReadOnlyCollection&lt;/SPAN&gt;&amp;lt;&lt;SPAN style="COLOR: #2b91af"&gt;HtmlElement&lt;/SPAN&gt;&amp;gt; elements = page.Elements.FindAll(find);&lt;/PRE&gt;&lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;/A&gt;
&lt;H3&gt;Assembly name change&lt;/H3&gt;
&lt;UL&gt;
&lt;LI&gt;The assembly name has been changed from “&lt;EM&gt;Microsoft.Web.Testing.Light.dll&lt;/EM&gt;” to “&lt;EM&gt;Microsoft.Web.Testing.Lightweight.dll&lt;/EM&gt;” The namespaces have not changed. &lt;/LI&gt;&lt;/UL&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7037453" width="1" height="1"&gt;</content><author><name>osbornm</name><uri>http://weblogs.asp.net/members/osbornm.aspx</uri></author><category term="Testing" scheme="http://weblogs.asp.net/asptest/archive/tags/Testing/default.aspx" /><category term="ASP.NET" scheme="http://weblogs.asp.net/asptest/archive/tags/ASP.NET/default.aspx" /><category term="Lightweight Test Automation Framework" scheme="http://weblogs.asp.net/asptest/archive/tags/Lightweight+Test+Automation+Framework/default.aspx" /></entry><entry><title>ASP.NET QA Podcast – Episode 3</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/asptest/archive/2009/03/31/asp-net-qa-podcast-episode-3.aspx" /><id>http://weblogs.asp.net/asptest/archive/2009/03/31/asp-net-qa-podcast-episode-3.aspx</id><published>2009-03-31T23:07:00Z</published><updated>2009-03-31T23:07:00Z</updated><content type="html">&lt;IFRAME style="MARGIN: 10px 0px" height=25 src="http://silverlight.services.live.com/invoke/27911/ASPNETQAPodcast3/iframe.html" frameBorder=0 width=266 scrolling=no mce_src="http://silverlight.services.live.com/invoke/27911/ASPNETQAPodcast4/iframe.html"&gt;&lt;/IFRAME&gt;
&lt;P&gt;&lt;FONT size=2&gt;&lt;STRONG&gt;Download :&lt;/STRONG&gt; &lt;/FONT&gt;&lt;FONT size=2&gt;&lt;A href="http://cid-b387831f07f582b4.skydrive.live.com/self.aspx/ASP.NET%20QA%20Podcast/AspNetQAPodcast3%7C_Small.mp3"&gt;Episode 3&lt;/A&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;In the third installment of the ASP.NET QA Podcast Federico and Matthew interview Mark Berryman, a test lead on the ASP.NET QA Team.&amp;nbsp; Join them as they learn the ins and outs of test management through Mark’s eyes. &lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Release of the Mobile Browser Database by Live Dublin. &lt;/LI&gt;
&lt;LI&gt;April refresh of the Lightweight Test Automation Framework. &lt;/LI&gt;
&lt;LI&gt;Interview with Mark Berryman. 
&lt;UL&gt;
&lt;LI&gt;What is the difference between Test Manager and Test Lead. &lt;/LI&gt;
&lt;LI&gt;A little history of Mark and how he came to join the ASP.NET QA team. &lt;/LI&gt;
&lt;LI&gt;Responsibilities of a Test Lead / What Mark is working on. &lt;/LI&gt;
&lt;LI&gt;What Mark looks for in a tester on his team. &lt;/LI&gt;
&lt;LI&gt;Challenges Mark faced when he was an IC (individual Contributor). &lt;/LI&gt;
&lt;LI&gt;What Mark would change on items he has tested in the past. &lt;/LI&gt;
&lt;LI&gt;How Mark Manages risk on his team. &lt;/LI&gt;
&lt;LI&gt;Who is Marks favorite person in the whole world. &lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;STRONG&gt;Links from the show :&lt;/STRONG&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;A href="http://mdbf.codeplex.com/"&gt;Mobile Browser Database&lt;/A&gt; &lt;/LI&gt;
&lt;LI&gt;&lt;A href="mailto:farmas@microsoft.com"&gt;Federico’s Email&lt;/A&gt; &lt;/LI&gt;
&lt;LI&gt;&lt;A href="mailto:mosborn@microsoft.com"&gt;Matthew’ Email&lt;/A&gt; &lt;/LI&gt;
&lt;LI&gt;&lt;A href="http://weblogs.asp.net/asptest"&gt;ASP.NET QA Team Blog&lt;/A&gt; &lt;/LI&gt;&lt;/UL&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7017338" width="1" height="1"&gt;</content><author><name>osbornm</name><uri>http://weblogs.asp.net/members/osbornm.aspx</uri></author><category term="Testing" scheme="http://weblogs.asp.net/asptest/archive/tags/Testing/default.aspx" /><category term="ASP.NET" scheme="http://weblogs.asp.net/asptest/archive/tags/ASP.NET/default.aspx" /><category term="Podcast" scheme="http://weblogs.asp.net/asptest/archive/tags/Podcast/default.aspx" /></entry></feed>