<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://consultingblogs.emc.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Matt Hall's Blog</title><link>http://consultingblogs.emc.com/matthall/default.aspx</link><description>Experiences with Microsoft technologies</description><dc:language>en</dc:language><generator>CommunityServer 2.1 SP3 (Build: 20423.1)</generator><item><title>EMC Consulting Hosting Connected Systems User Group</title><link>http://consultingblogs.emc.com/matthall/archive/2011/02/09/emc-consulting-hosting-connected-systems-user-group.aspx</link><pubDate>Wed, 09 Feb 2011 21:39:00 GMT</pubDate><guid isPermaLink="false">e847c0e7-38d9-45c0-b593-56747303e088:18216</guid><dc:creator>Matthew.Hall</dc:creator><slash:comments>0</slash:comments><comments>http://consultingblogs.emc.com/matthall/comments/18216.aspx</comments><wfw:commentRss>http://consultingblogs.emc.com/matthall/commentrss.aspx?PostID=18216</wfw:commentRss><description>EMC Consulting are once again hosting the UK Connected System User Group, which is due to be held at our Notcutt office on Tuesday 15th February 2011. There are only 4 tickets remaining as I write this so if you have any interest you had better register soon. For further information please go to&amp;nbsp;&lt;a href="http://ukcsugfeb2011.eventbrite.com/"&gt;http://ukcsugfeb2011.eventbrite.com/&lt;/a&gt;&lt;img src="http://consultingblogs.emc.com/aggbug.aspx?PostID=18216" width="1" height="1"&gt;</description><category domain="http://consultingblogs.emc.com/matthall/archive/tags/BizTalk/default.aspx">BizTalk</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/WCF/default.aspx">WCF</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/Connected+Systems/default.aspx">Connected Systems</category></item><item><title>London Connected Systems User Group Session</title><link>http://consultingblogs.emc.com/matthall/archive/2010/11/22/london-connected-systems-user-group-session.aspx</link><pubDate>Mon, 22 Nov 2010 14:32:00 GMT</pubDate><guid isPermaLink="false">e847c0e7-38d9-45c0-b593-56747303e088:17939</guid><dc:creator>Matthew.Hall</dc:creator><slash:comments>0</slash:comments><comments>http://consultingblogs.emc.com/matthall/comments/17939.aspx</comments><wfw:commentRss>http://consultingblogs.emc.com/matthall/commentrss.aspx?PostID=17939</wfw:commentRss><description>&lt;DIV&gt;EMC Consulting will be hosting a ‘Connected Systems’ user group session at their London office on Tuesday 7th December.&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;BR&gt;&lt;/DIV&gt;&lt;DIV&gt;What is ‘Connected Systems’ you ask? Well, this encompasses any technology that is related to connecting systems together, which happens to be quite a broad subject. The user group focuses on Microsoft technology in particular such as WCF, WF, Azure and SSIS but is keen to also cover patterns and practices, those that are technology independent. Essentially, if you have experience or an interest in working on solutions that require any interaction with an external system then this user group could be appealing.&lt;/DIV&gt;&lt;DIV&gt;&lt;BR&gt;&lt;/DIV&gt;&lt;DIV&gt;The first event contains two sessions. The first will be&lt;STRONG&gt; Liberating Identity using Windows Identity Foundation&lt;/STRONG&gt; by &lt;STRONG&gt;Simon Evans&lt;/STRONG&gt;. The second will be on some work by&lt;STRONG&gt; Prasanna Krishnan&lt;/STRONG&gt; relating to&lt;STRONG&gt; Large Data Streaming with WCF&lt;/STRONG&gt;.&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;BR&gt;&lt;/DIV&gt;&lt;DIV&gt;This is the inaugural session and we are very interested in hosting many more events. The venue will be available for free use, so the only concern is making sure we have people that can provide some interesting content they wish to share with the rest of the community. Please feel free to come along and offer suggestions for material going forward. Alternatively, contact me directly.&lt;/DIV&gt;&lt;DIV&gt;&lt;BR&gt;&lt;/DIV&gt;&lt;DIV&gt;For details on the first event and register your place now, please visit &lt;A title="http://lcsug.eventbrite.com/" href="http://lcsug.eventbrite.com/"&gt;http://lcsug.eventbrite.com/&lt;/A&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;BR&gt;&lt;/DIV&gt;&lt;img src="http://consultingblogs.emc.com/aggbug.aspx?PostID=17939" width="1" height="1"&gt;</description><category domain="http://consultingblogs.emc.com/matthall/archive/tags/WCF/default.aspx">WCF</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/LCSUG/default.aspx">LCSUG</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/London+Connected+Systems+User+Group/default.aspx">London Connected Systems User Group</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/Connected+Systems/default.aspx">Connected Systems</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/User+Group/default.aspx">User Group</category></item><item><title>WCF Stateful Security Context Token and Service Accounts</title><link>http://consultingblogs.emc.com/matthall/archive/2009/11/05/wcf-stateful-security-context-token-and-service-accounts.aspx</link><pubDate>Thu, 05 Nov 2009 15:34:37 GMT</pubDate><guid isPermaLink="false">e847c0e7-38d9-45c0-b593-56747303e088:16518</guid><dc:creator>Matthew.Hall</dc:creator><slash:comments>0</slash:comments><comments>http://consultingblogs.emc.com/matthall/comments/16518.aspx</comments><wfw:commentRss>http://consultingblogs.emc.com/matthall/commentrss.aspx?PostID=16518</wfw:commentRss><description>I have spent some time investigating an issue relating to the configuration of WCF web services for SCT as described in &lt;a href="http://msdn.microsoft.com/en-us/library/ms731814.aspx" target="_blank"&gt;this article&lt;/a&gt; and specific service accounts.   &lt;p&gt;It turns out that when your web service is setup like this and you assign a specific service account rather than use the network service account or the new &lt;a href="http://learn.iis.net/page.aspx/624/application-pool-identities/"&gt;Application Pool Identities&lt;/a&gt;, you may get errors such as “The token provider cannot get tokens for target” or “Secure channel cannot be opened because security negotiation with the remote endpoint has failed. This may be due to absent or incorrectly specified EndpointIdentity in the EndpointAddress used to create the channel. Please verify the EndpointIdentity specified or implied by the EndpointAddress correctly identifies the remote endpoint” or “The request for security token has invalid or malformed elements”.&lt;/p&gt;  &lt;p&gt;These errors are somewhat misleading as to the underlying cause. Instead of having anything to do with security negotiation and tokens per se, I deduced that it appears to be related to the service account not having a user profile on the server. In fact the article above does mention this in the following paragraph, although at first it isn’t an obvious link to the errors highlighted above.&lt;/p&gt;  &lt;p&gt;“&lt;em&gt;For applications that use stateful SCTs in a secure session, the thread identity for the service must be a user account that has an associated user profile. When the service is run under an account that does not have a user profile, such as Local Service, an exception may be thrown&lt;/em&gt;.”&lt;/p&gt;  &lt;p&gt;Anyway, in order to get around this you can either logon as the service account on the server as part of the deployment (probably not the best option) or change the “Load User Profile” option in the associated Application Pool to True. This will create the user profile for the service account the first time the service is instantiated. You can then change this option back to false if you wish.&lt;/p&gt;  &lt;p&gt;I would be interested to know &lt;strong&gt;exactly&lt;/strong&gt; what it is from the user profile for the service account that is required when the requireSecurityContextCancellation attribute is set to false, as firstly I would just like to know, and secondly I don’t believe either of the options above are elegant. If anyone can shed any light feel free to let me know.&lt;/p&gt;&lt;img src="http://consultingblogs.emc.com/aggbug.aspx?PostID=16518" width="1" height="1"&gt;</description></item><item><title>Client Certificate Authorisation with WCF in Development Environments</title><link>http://consultingblogs.emc.com/matthall/archive/2009/10/22/client-certificate-authorisation-with-wcf-in-development-environments.aspx</link><pubDate>Thu, 22 Oct 2009 10:44:00 GMT</pubDate><guid isPermaLink="false">e847c0e7-38d9-45c0-b593-56747303e088:16440</guid><dc:creator>Matthew.Hall</dc:creator><slash:comments>0</slash:comments><comments>http://consultingblogs.emc.com/matthall/comments/16440.aspx</comments><wfw:commentRss>http://consultingblogs.emc.com/matthall/commentrss.aspx?PostID=16440</wfw:commentRss><description>&lt;P&gt;I have meant to write a blog post about client certificates in a development environment for a while now, as every time I come to implement it I forget a step somewhere. There are resources online for a number of the steps below, but I wanted to consolidate that information along with my own steps into a single place that I can use as a reference. This may also be useful to others, hence why I am making a blog post rather than file it away in my &lt;A class="" href="http://consultingblogs.emc.com/controlpanel/blogs/www.mesh.com"&gt;mesh&lt;/A&gt; repository somewhere.&lt;/P&gt;
&lt;P&gt;So, what am I trying to do here? Well, I would like to create a &lt;A href="http://msdn.microsoft.com/wcf" target=_blank&gt;WCF&lt;/A&gt; service that utilises &lt;A href="http://en.wikipedia.org/wiki/SSL" target=_blank&gt;SSL&lt;/A&gt; and requires that clients use a certificate for authentication in a development environment where I do not have any certificates supplied to me. I am setting this up in a &lt;A href="http://www.microsoft.com/windowsserver2008" target=_blank&gt;Windows 2008&lt;/A&gt; environment (so &lt;A href="http://www.iis.net/" target=_blank&gt;IIS 7&lt;/A&gt;) with .NET 3.5. The whole process will involve the following steps:&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;Create certificate to act as a root &lt;A href="http://en.wikipedia.org/wiki/Certificate_authority" target=_blank&gt;certificate authority&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;Install &lt;A href="http://en.wikipedia.org/wiki/Root_certificate" target=_blank&gt;root certificate&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;Install service certificate on server&lt;/LI&gt;
&lt;LI&gt;Configure site to use SSL certificate&lt;/LI&gt;
&lt;LI&gt;Export client certificate&lt;/LI&gt;
&lt;LI&gt;Import certificate on client&lt;/LI&gt;
&lt;LI&gt;Configure WCF Service&lt;/LI&gt;
&lt;LI&gt;Configure client(s)&lt;/LI&gt;&lt;/OL&gt;
&lt;H4&gt;Step 1 – Create Certificate to act as Root Certificate Authority&lt;/H4&gt;
&lt;P&gt;To use chain trust validation during development you need to create a self-signed root CA and place it in the Trusted Root Certification Authority store. The certificate used by WCF is then created and signed by the root self-signed certificate and installed in the LocalMachine store.&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Open the Visual Studio command prompt and browse to the location where you want to save the certificate files.&lt;/LI&gt;
&lt;LI&gt;Enter the following command:&lt;/LI&gt;&lt;/UL&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;Makecert –n “CN=MyRootCA” –r –sv MyRootCA.pvk mYRootCA.cer&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;UL&gt;
&lt;LI&gt;In the Create Private Key Password dialog box, enter a password, confirm the password, and then click OK&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;IMG src="http://consultingblogs.emc.com/photos/conchango_bloggers/images/16429/original.aspx"&gt; &lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;In the Enter Private Key Password dialog box, enter the password again and then click OK.&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;IMG src="http://consultingblogs.emc.com/photos/conchango_bloggers/images/16430/original.aspx"&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;You should now have two files MyRootCA.cer and MyRootCA.pvk&lt;/LI&gt;&lt;/UL&gt;
&lt;H4&gt;Step 2 – Install Root Certificate Authority&lt;/H4&gt;
&lt;P&gt;The certificate that will be created using this certificate authority will need to have the CA installed on both the client and the server, as it will be used to verify the certificate.&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Follow these steps on both the server and client(s)&lt;/LI&gt;
&lt;LI&gt;Run MMC&lt;/LI&gt;
&lt;LI&gt;Add certificates snap-in&lt;/LI&gt;
&lt;LI&gt;Choose computer account, as this certificate needs to be made available for all users&lt;/LI&gt;
&lt;LI&gt;Choose local computer&lt;/LI&gt;
&lt;LI&gt;Browse certificates snap-in and go to certificates node under trusted root certification authorities&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;IMG src="http://consultingblogs.emc.com/photos/conchango_bloggers/images/16431/original.aspx"&gt;&amp;nbsp;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Right-click this and select import from the popup menu&lt;/LI&gt;
&lt;LI&gt;Browse to the folder where you created the root CA certificate&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;IMG src="http://consultingblogs.emc.com/photos/conchango_bloggers/images/16432/original.aspx"&gt; &lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Accept defaults for rest of import wizard&lt;/LI&gt;
&lt;LI&gt;You can double-click the certificate entry to view and validate it installed correctly&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;IMG src="http://consultingblogs.emc.com/photos/conchango_bloggers/images/16433/original.aspx"&gt; &lt;/P&gt;
&lt;H4&gt;Step 3 – Install Service Certificate on Server&lt;/H4&gt;
&lt;P&gt;You now want to create the certificate for the service on the server and the following steps will do this. Once completed you will see the certificate via the certificates snap-in of MMC and browsing to the following location: Certificates (Local Computer) –&amp;gt; Personal –&amp;gt; Certificates&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Open the Visual Studio command prompt and browse to the location where you saved the Root CA certificate files&lt;/LI&gt;
&lt;LI&gt;Run the following command&lt;/LI&gt;&lt;/UL&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;makecert -sk &amp;lt;KeyName&amp;gt; -iv MyRootCA.pvk -n "CN=&amp;lt;MachineName&amp;gt;" -ic MyRootCA.cer -sr localmachine -ss my -sky exchange –pe&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;UL&gt;
&lt;LI&gt;Where &amp;lt;KeyName&amp;gt; is the subject’s key container name (which should be unique) and &amp;lt;MachineName&amp;gt; is name of the server which must match the DNS or NetBIOS name&lt;/LI&gt;
&lt;LI&gt;Enter the password you defined previously&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;IMG src="http://consultingblogs.emc.com/photos/conchango_bloggers/images/16434/original.aspx"&gt; &lt;/P&gt;
&lt;H4&gt;Step 4 – Configure Site to use SSL Certificate&lt;/H4&gt;
&lt;P&gt;We now want to configure the website that is to host the WCF service to use the SSL certificate we just created. This step assumes you have already created a website for HTTPS.&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Open IIS Manager&lt;/LI&gt;
&lt;LI&gt;Browse to “Sites”&lt;/LI&gt;
&lt;LI&gt;Right-click on your site and select “bindings” from popup menu&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;IMG src="http://consultingblogs.emc.com/photos/conchango_bloggers/images/16435/original.aspx"&gt; &lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Click edit and from the SSL certificate drop-down choose the certificate you have just installed&lt;/LI&gt;&lt;/UL&gt;
&lt;H4&gt;Step 5 – Export Client Certificate&lt;/H4&gt;
&lt;P&gt;Now we want to export the certificate that will be used on the client(s). At the end of this step you should have a new file created with a pfx extension.&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Open MMC&lt;/LI&gt;
&lt;LI&gt;Add the certificates snap-in and select “Computer Account”&lt;/LI&gt;
&lt;LI&gt;Browse to Certificates (Local Computer) –&amp;gt; Personal –&amp;gt; Certificates&lt;/LI&gt;
&lt;LI&gt;Right-click on the certificate you created (should be name of server), select “all tasks” and then “export”&lt;/LI&gt;
&lt;LI&gt;In the wizard select that you want to export the private key&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;IMG src="http://consultingblogs.emc.com/photos/conchango_bloggers/images/16436/original.aspx"&gt; &lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;From the next screen select the defaults&lt;/LI&gt;
&lt;LI&gt;Enter a password to protect the private key&lt;/LI&gt;
&lt;LI&gt;Select where you want to export the certificate and complete the wizard&lt;/LI&gt;&lt;/UL&gt;
&lt;H4&gt;Step 6 – Import Certificate on Client&lt;/H4&gt;
&lt;P&gt;Now we need to import the certificate we just exported onto the client(s). You should have already imported the certificate authority in step 2, but if not make sure you do so at this point. Note that we are using the current user here, it just happens to be the way we have things configured later on. You may have a different setup here.&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;In MMC, add certificate snap-in for “current user” &lt;/LI&gt;
&lt;LI&gt;Browse to Certificates (Current User) –&amp;gt; Personal –&amp;gt; Certificates&lt;/LI&gt;
&lt;LI&gt;Right click this node and select All Tasks and Import from the popup menu&lt;/LI&gt;
&lt;LI&gt;Follow the steps in the wizard, selecting the pfx file you exported in the previous step&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;IMG src="http://consultingblogs.emc.com/photos/conchango_bloggers/images/16437/original.aspx"&gt; &lt;/P&gt;
&lt;H4&gt;Step 7 – Configure WCF Service&lt;/H4&gt;
&lt;P&gt;This is the WCF service that we are hosting and requiring authentication for. We happen to be using basicHttpBinding here, but it could be something else&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Make the following entries in your web.config&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&amp;lt;services&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;service behaviorConfiguration="MyBehaviour" name="MyService"&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;endpoint name="MyEndPoint" address="" binding="basicHttpBinding" bindingConfiguration="ClientCertificateTransportSecurity" contract="MyContract" /&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;!--&amp;lt;endpoint address="mex" binding="mexHttpsBinding" contract="IMetadataExchange" /&amp;gt;--&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/service&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/services&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;behaviors&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;serviceBehaviors&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;behavior name="MyBehaviour"&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;serviceMetadata httpsGetEnabled="true" /&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;serviceDebug includeExceptionDetailInFaults="true" /&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/behavior&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/serviceBehaviors&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/behaviors&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;bindings&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;basicHttpBinding&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;binding name="ClientCertificateTransportSecurity"&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;security mode="Transport"&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;transport clientCredentialType="Certificate" /&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/security&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/binding&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/basicHttpBinding&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/bindings&amp;gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Note that if you do not have the mex commented out like above you will receive the error “The SSL settings for the service 'None' does not match those of the IIS 'Ssl, SslNegotiateCert, SslRequireCert, SslMapCert'”. &lt;/LI&gt;&lt;/UL&gt;
&lt;H4&gt;Step 8 – Configure Client(s)&lt;/H4&gt;
&lt;P&gt;&lt;U&gt;If using custom app&lt;/U&gt;&lt;/P&gt;
&lt;P&gt;Make sure you have the following in your configuration file.&lt;/P&gt;
&lt;P&gt;&amp;lt;system.serviceModel&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;client&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;endpoint address="&lt;A href="https://myserver/myService.svc%22"&gt;https://myServer/myService.svc"&lt;/A&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; binding="basicHttpBinding" &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; bindingConfiguration="ClientCertificateTransportSecurity" &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; contract="MyContract" &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; name="MyEndPoint" &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; behaviorConfiguration="ClientCertificateCredential" /&amp;gt; &lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/client&amp;gt; &lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;bindings&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;basicHttpBinding&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;binding name=" ClientCertificateTransportSecurity"&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;security mode="Transport"&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;transport clientCredentialType="Certificate" /&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/security&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/binding&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/basicHttpBinding&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/bindings&amp;gt; &lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;behaviors&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;endpointBehaviors&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;behavior name="ClientCertificateCredential"&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;clientCredentials&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;clientCertificate findValue="myThumbprint" &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; storeLocation="CurrentUser" &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; x509FindType="FindByThumbprint" /&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/clientCredentials&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/behavior&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/endpointBehaviors&amp;gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/behaviors&amp;gt; &lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;lt;/system.serviceModel&amp;gt;&lt;/P&gt;
&lt;P&gt;Where myThumbprint is available from the certificate&lt;/P&gt;
&lt;P&gt;&lt;IMG src="http://consultingblogs.emc.com/photos/conchango_bloggers/images/16438/original.aspx"&gt; &lt;/P&gt;
&lt;P&gt;&lt;U&gt;If using a browser to view the service&lt;/U&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Internet Explorer &lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Should just work, a popup should appear that asks you to specify the certificate to pass&lt;/P&gt;
&lt;P&gt;&lt;IMG src="http://consultingblogs.emc.com/photos/conchango_bloggers/images/16439/original.aspx"&gt; &lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;FireFox&lt;/STRONG&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;You will get an error that says “HTTP Error 403.7 – Forbidden” “The page you are attempting to access requires your browser to have a Secure Sockets Layer (SSL) client certificate that the Web server recognizes.”&lt;/LI&gt;
&lt;LI&gt;In &lt;A class="" href="http://www.mozilla.com/en-US/firefox"&gt;FireFox&lt;/A&gt; go to Tools –&amp;gt; Options –&amp;gt; Advanced –&amp;gt; Encryption –&amp;gt; View Certificates&lt;/LI&gt;
&lt;LI&gt;Click import and select the certificate with private key file you exported earlier (the .pfx file)&lt;/LI&gt;
&lt;LI&gt;You will need to clear history now or restart browser&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;STRONG&gt;Fiddler&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;You may want to use &lt;A class="" href="http://www.fiddler2.com/"&gt;fiddler&lt;/A&gt; to examine what is going on. When you have fiddler open you will receive a message saying “The server [your server] requires a client certificate. Please save a client certificate in the following location”. Pretty self explanatory. You will need to export your certificate from MMC certificates snap-in, certificates –&amp;gt; personal –&amp;gt; certificates but this time do not export the private key, just export as a DER encoded certificate, copy and rename to the folder/name that fiddler wanted you to.&lt;/P&gt;
&lt;H4&gt;Issues&lt;/H4&gt;
&lt;P&gt;“There was an error downloading '&lt;A href="https://machinename/servicefolder/Service.svc'"&gt;https://MachineName/servicefolder/Service.svc'&lt;/A&gt;. The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel”&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;If CA not installed on client then a trust relationship cannot be established and the above error can occur &lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;“The SSL settings for the service 'None' does not match those of the IIS 'Ssl, SslNegotiateCert, SslRequireCert, SslMapCert'”&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;You will get this error if you do not make sure the clientCredentialType is not set to certificate in the service configuration&lt;/LI&gt;
&lt;LI&gt;If the mex is not commented out in the configuration of the service&lt;/LI&gt;
&lt;LI&gt;If the binding of the website isn’t set properly (as shown in step 4)&lt;/LI&gt;&lt;/UL&gt;&lt;img src="http://consultingblogs.emc.com/aggbug.aspx?PostID=16440" width="1" height="1"&gt;</description><category domain="http://consultingblogs.emc.com/matthall/archive/tags/.NET/default.aspx">.NET</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/WCF/default.aspx">WCF</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/Certificates/default.aspx">Certificates</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/SSL/default.aspx">SSL</category></item><item><title>Microsoft BizTalk 2009 ESB Toolkit – Install Issue</title><link>http://consultingblogs.emc.com/matthall/archive/2009/10/16/microsoft-biztalk-2009-esb-toolkit-install-issue.aspx</link><pubDate>Fri, 16 Oct 2009 08:44:00 GMT</pubDate><guid isPermaLink="false">e847c0e7-38d9-45c0-b593-56747303e088:16400</guid><dc:creator>Matthew.Hall</dc:creator><slash:comments>0</slash:comments><comments>http://consultingblogs.emc.com/matthall/comments/16400.aspx</comments><wfw:commentRss>http://consultingblogs.emc.com/matthall/commentrss.aspx?PostID=16400</wfw:commentRss><description>&lt;p&gt;So, I haven’t really been doing much with BizTalk for a while now, spending more time on traditional development activities and working on some WCF specific solutions. However, I have recently been investigating &lt;a href="http://en.wikipedia.org/wiki/Service-oriented_architecture" target="_blank"&gt;SOA&lt;/a&gt; implementations in more detail, in particular the &lt;a href="http://en.wikipedia.org/wiki/Enterprise_service_bus" target="_blank"&gt;ESB&lt;/a&gt; (Enterprise Service Bus) along with how and why you would want one of these in your organisation.&lt;/p&gt;  &lt;p&gt;This has led me neatly back into the &lt;a href="http://www.microsoft.com/biztalk/en/us/default.aspx" target="_blank"&gt;BizTalk&lt;/a&gt; space. I had actively perused opportunities away from BizTalk, not necessarily due to the fact that I didn’t like working with the product, but more for the desire to get back into pure development like I used to. Hey, it’s nice to have a change every now and again. Now this particular task I am undertaking at the moment is purely focused on Microsoft technologies; I know there are numerous ESB offerings out there from various vendors. So this has led me to the &lt;a href="http://msdn.microsoft.com/en-us/biztalk/dd876606.aspx" target="_blank"&gt;BizTalk 2009 ESB Toolkit 2.0&lt;/a&gt; from a product perspective and looking into some of the enabling future technologies such as &lt;a href="http://msdn.microsoft.com/en-us/netframework/aa663324.aspx" target="_blank"&gt;WCF/WF 4.0&lt;/a&gt; and the Microsoft Application Server Extensions codenamed “&lt;a href="http://www.microsoft.com/NET/Dublin.aspx" target="_blank"&gt;Dublin&lt;/a&gt;”.&lt;/p&gt;  &lt;p&gt;Well, without going into the details of an ESB as there is a wealth of conflicting information out there already, I decided that simply reading about BizTalk 2009 ESB Toolkit would not be sufficient so with a little trepidation I decided to install BizTalk 2009 and the ESB Toolkit onto a &lt;a href="https://www.vmware.com" target="_blank"&gt;VM&lt;/a&gt; for testing. I say with trepidation, as I have spent a huge amount of time in the past installing, configuring and generally thumping my head against a heavy object in frustration at the difficulties of getting BizTalk working as expected. However, being a local development install and therefore not having the security locked down that is often the biggest inhibitor to an easy deployment, I was somewhat more optimistic.&lt;/p&gt;  &lt;p&gt;Anyway, before I decided to plough away at the install I thought it would be prudent to check whether anyone has had experienced difficulties and/or provided some steps to get going quickly; I didn’t want to spend too much time on this activity. So it was with gratitude that I came across this &lt;a href="http://www.preetham-reddy.com/2009/08/installing-and-configuring-esb-toolkit.html" target="_blank"&gt;great post&lt;/a&gt; by Preetham Reddy. By following these steps I was up and running pretty pain free. I say “pretty” pain free, as I did have one issue that I thought I would make a note of here in case anyone else comes across the same problem.&lt;/p&gt;  &lt;p&gt;Now, during the configuration steps there is a part where you need to run ESBConfigurationTool.exe to configure the settings for exception management, the ESB core components and configuration nodes. While trying to apply the configuration to any of the databases I would receive an error relating to not being able to create the database. I was logged in as an administrator and I thought this odd, so decided to simply create the databases via SQL Server Management Studio. I ran the configuration again and everything seemed to work fine.&lt;/p&gt;  &lt;p&gt;I completed the rest of the installation and when i went to browse the ESB Management Console I was presented with the following error: “An unhandled exception has occurred”. “Great” I thought, here we go again, difficulties getting things installed and configured with BizTalk. Looking at the Windows Event Viewer I saw the following entries:&lt;/p&gt;  &lt;p&gt;Event code: 3005    &lt;br&gt;Event message: An unhandled exception has occurred.     &lt;br&gt;Event time: 15/10/2009 18:35:20     &lt;br&gt;Event time (UTC): 15/10/2009 17:35:20     &lt;br&gt;Event ID: 77d00134a17e42519d7c6a11e26ce9d2     &lt;br&gt;Event sequence: 13     &lt;br&gt;Event occurrence: 4     &lt;br&gt;Event detail code: 0     &lt;br&gt;Application information:     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Application domain: /LM/W3SVC/1/ROOT/ESB.Portal-1-129001012513866430     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Trust level: Full     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Application Virtual Path: /ESB.Portal     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Application Path: C:\Program Files\Microsoft BizTalk ESB Toolkit 2.0\ESBSource\Source\Samples\Management Portal\ESB.Portal\     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Machine name: MyMachine    &lt;br&gt;Process information:     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Process ID: 4584     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Process name: w3wp.exe     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Account name: MyMachine\Administrator     &lt;br&gt;Exception information:     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Exception type: WebException     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Exception message: The remote server returned an error: (400) Bad Request.     &lt;br&gt;Request information:     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Request URL: &lt;a href="http://localhost/ESB.Portal/Default.aspx"&gt;http://localhost/ESB.Portal/Default.aspx&lt;/a&gt;    &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Request path: /ESB.Portal/Default.aspx     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; User host address: ::1     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; User: MyMachine\Administrator     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Is authenticated: True     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Authentication Type: NTLM     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Thread account name: MyMachine\Administrator     &lt;br&gt;Thread information:     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Thread ID: 12     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Thread account name: MyMachine\Administrator     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Is impersonating: False     &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Stack trace:&amp;nbsp;&amp;nbsp;&amp;nbsp; at System.Net.HttpWebRequest.GetResponse()    &lt;br&gt;&amp;nbsp;&amp;nbsp; at System.ServiceModel.Channels.HttpChannelFactory.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan timeout)&lt;/p&gt;  &lt;p&gt;Nothing particularly useful there I thought. So I eventually ended up attaching a debugger to the web application and noticed the code was having trouble retrieving data. This is when I remembered the oddity from the configuration so checked the database to see there were no tables, views, stored procedures or anything within them. So I ran through the configuration with ESBConfigurationTool.exe again, but still nothing. I then deleted the databases it had created to see if it would actually create them this time, which it did. I then went back to the ESB Management Console site and viola, there it was.&lt;/p&gt;  &lt;p&gt;So, I am a little confused why the tool could not create the database the first time, but did the second time. Anyway, this may be useful to someone out there. My thoughts on the whole install and configure process so far is that it is too laborious and error prone, as I half-expected. I want to be able to do one-click deployment, is that too much to ask these days? Perhaps this is the remnants of it being developed externally from the product, but nevertheless it isn’t a great experience for those considering using this on an enterprise-scale project is it?&lt;/p&gt;  &lt;p&gt;Anyway, back to my investigations…&lt;/p&gt;&lt;img src="http://consultingblogs.emc.com/aggbug.aspx?PostID=16400" width="1" height="1"&gt;</description><category domain="http://consultingblogs.emc.com/matthall/archive/tags/BizTalk/default.aspx">BizTalk</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/ESB/default.aspx">ESB</category></item><item><title>Powershell Zip Files on Network Drive</title><link>http://consultingblogs.emc.com/matthall/archive/2009/09/22/powershell-zip-files-on-network-drive.aspx</link><pubDate>Tue, 22 Sep 2009 10:53:00 GMT</pubDate><guid isPermaLink="false">e847c0e7-38d9-45c0-b593-56747303e088:16258</guid><dc:creator>Matthew.Hall</dc:creator><slash:comments>0</slash:comments><comments>http://consultingblogs.emc.com/matthall/comments/16258.aspx</comments><wfw:commentRss>http://consultingblogs.emc.com/matthall/commentrss.aspx?PostID=16258</wfw:commentRss><description>
&lt;p&gt;I was having a frustrating time zipping files in a &lt;a href="http://www.microsoft.com/windowsserver2003/technologies/management/powershell/default.mspx" target="_blank"&gt;Powershell&lt;/a&gt; script, one that I had created based on those discussed in David Aiken’s &lt;a href="http://blogs.msdn.com/daiken/archive/2007/02/12/compress-files-with-windows-powershell-then-package-a-windows-vista-sidebar-gadget.aspx" target="_blank"&gt;blog post&lt;/a&gt;. The name of the zip files created were quite long and were being generated a 8.3 filename automatically whenever the &lt;a href="http://msdn.microsoft.com/en-us/library/bb787866%28VS.85%29.aspx" target="_blank"&gt;CopyHere&lt;/a&gt; method was being called on the zip folder where the files were being added. It was certainly something related to this method, as the New-Zip function was creating the zip file with the desired name, but was renamed only after the CopyHere method was used. &lt;/p&gt;
  
&lt;p&gt;Now I still haven’t found a solution to this problem so if anyone has any suggestions they are most welcome to post them. What I did do however was create a workaround which entails creating the zip file locally on the machine where the script is executing and then move this to the destination. It turns out this problem only happens when attempting to write to a network folder directly.&lt;/p&gt;
  
&lt;p&gt;The following function had the issue with CopyHere&lt;/p&gt;
  
&lt;pre&gt;function Add-Zip&lt;br&gt;{&lt;br&gt;      param([string]$zipfilename)&lt;br&gt;&lt;br&gt;      if(-not (test-path($zipfilename)))&lt;br&gt;      {&lt;br&gt;            set-content $zipfilename ("PK" + [char]5 + [char]6 + ("$([char]0)" * 18))&lt;br&gt;            (dir $zipfilename).IsReadOnly = $false &lt;br&gt;      }&lt;br&gt;&lt;br&gt;      # Return the application object&lt;br&gt;      $shellApplication = new-object -com shell.application&lt;br&gt;      &lt;br&gt;      # Returns a folder object for the specified folder&lt;br&gt;      $zipPackage = $shellApplication.NameSpace($zipfilename)&lt;br&gt;&lt;br&gt;      # Returns file object for the zip file&lt;br&gt;      $zip = Get-Item $zipfilename&lt;br&gt;      $activity = 'Zipping file to ' + $zip.Name + ': '&lt;br&gt;      foreach($file in $Input) &lt;br&gt;      {&lt;br&gt;            Write-Progress -activity $activity -status $file.Name&lt;br&gt;            $zipPackage.CopyHere($file.FullName,256)&lt;br&gt;            Start-sleep -milliseconds 500&lt;br&gt;      }&lt;br&gt;}&lt;/pre&gt;
So I simply created a temporary zip and then moved it 

&lt;pre&gt;# For some reason the filename is getting trimmed when writing directly to the network, so&lt;br&gt;# we use a temporary folder here for storage before moving to the final destination&lt;br&gt;$filename = "$element-$(Get-Date -f dd-MMM-yy-HH-mm-ss)"&lt;br&gt;$zipPath = "$tempFolder\$filename.zip"&lt;br&gt;            &lt;br&gt;# Create a new zip file&lt;br&gt;New-Zip $zipPath&lt;br&gt;$path = $element.PSPath&lt;br&gt;&lt;br&gt;# Add each item in this elements path to the zip file&lt;br&gt;Get-Item $element.PSPath | Add-Zip $zipPath&lt;br&gt;            &lt;br&gt;# Now move it to the final destination&lt;br&gt;Move-Item $zipPath $componentfolder&lt;/pre&gt;&lt;img src="http://consultingblogs.emc.com/aggbug.aspx?PostID=16258" width="1" height="1"&gt;</description><category domain="http://consultingblogs.emc.com/matthall/archive/tags/Powershell/default.aspx">Powershell</category></item><item><title>ANTS Profiler 5.1 and Windows Process Activation Services (WAS)</title><link>http://consultingblogs.emc.com/matthall/archive/2009/09/08/ants-profiler-5-1-and-windows-process-activation-services-was.aspx</link><pubDate>Tue, 08 Sep 2009 11:03:00 GMT</pubDate><guid isPermaLink="false">e847c0e7-38d9-45c0-b593-56747303e088:16193</guid><dc:creator>Matthew.Hall</dc:creator><slash:comments>1</slash:comments><comments>http://consultingblogs.emc.com/matthall/comments/16193.aspx</comments><wfw:commentRss>http://consultingblogs.emc.com/matthall/commentrss.aspx?PostID=16193</wfw:commentRss><description>&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;I have been using &lt;/FONT&gt;&lt;A href="http://www.red-gate.com/products/ants_performance_profiler/index.htm"&gt;&lt;FONT face=Calibri size=3&gt;ANTS Profiler&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Calibri size=3&gt; to conduct some profiling against some WCF services hosted on Windows 2008 that I have been working on. This was working pretty well with services hosted in IIS, but I was experiencing some difficulties when attempting to hook it all up with WCF services hosted in WAS using the net.tcp binding. I still don’t have a definitive answer as to why I have been experiencing issues, but I have a workaround procedure in order to get it working.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;Firstly, you need to create a profile and choose the Windows service application type to profile, selected WAS from the, as shown in the following screen capture.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;IMG src="http://blogs.conchango.com/photos/conchango_bloggers/images/16191/original.aspx"&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;Once you click the Start Profiling button the WAS service should be stopped and started. It is at this point where I experience my first problem, as it seems to hang at the starting state. Note the status bar in the following screen capture.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;IMG style="WIDTH:606px;HEIGHT:466px;" height=466 src="http://blogs.conchango.com/photos/conchango_bloggers/images/16192/original.aspx" width=606&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;Now it appears that the service never starts and this state is also shown when you browse the Windows Process Activation Service service in the Services snap-in. After a bit of playing around I managed to get past this issue, by following these simple steps:&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoListParagraphCxSpFirst style="MARGIN:0cm 0cm 0pt 36pt;TEXT-INDENT:-18pt;mso-list:l0 level1 lfo1;"&gt;&lt;SPAN style="mso-bidi-font-family:Calibri;mso-bidi-theme-font:minor-latin;"&gt;&lt;SPAN style="mso-list:Ignore;"&gt;&lt;FONT face=Calibri size=3&gt;1.&lt;/FONT&gt;&lt;SPAN style="FONT:7pt 'Times New Roman';"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri size=3&gt;Execute iisreset from a command prompt window&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoListParagraphCxSpMiddle style="MARGIN:0cm 0cm 0pt 36pt;TEXT-INDENT:-18pt;mso-list:l0 level1 lfo1;"&gt;&lt;SPAN style="mso-bidi-font-family:Calibri;mso-bidi-theme-font:minor-latin;"&gt;&lt;SPAN style="mso-list:Ignore;"&gt;&lt;FONT face=Calibri size=3&gt;2.&lt;/FONT&gt;&lt;SPAN style="FONT:7pt 'Times New Roman';"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri size=3&gt;Once iisreset has restarted, browse to an HTTP WCF endpoint on the server&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoListParagraphCxSpLast style="MARGIN:0cm 0cm 10pt 36pt;TEXT-INDENT:-18pt;mso-list:l0 level1 lfo1;"&gt;&lt;SPAN style="mso-bidi-font-family:Calibri;mso-bidi-theme-font:minor-latin;"&gt;&lt;SPAN style="mso-list:Ignore;"&gt;&lt;FONT face=Calibri size=3&gt;3.&lt;/FONT&gt;&lt;SPAN style="FONT:7pt 'Times New Roman';"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri size=3&gt;The profiler should now be started&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;Now, at this point I also experienced an issue when attempting to take a memory snapshot, receiving the following error message where &amp;lt;some folder&amp;gt; is the location where it is trying to save the data.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;Could not start profiling as the processing being profiled was unable to create the file '&amp;lt;some folder&amp;gt;'.You can set the RGTEMP or the RGIISTEMP environment variables in the System control panel to override the location used for profiler results files.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;In order to get around this I simply gave everyone permissions to the folder it was trying to save to. I am sure there was a more focused way that this could be achieved, but as this was a development machine I was quite happy with this.&lt;/FONT&gt;&lt;/P&gt;&lt;img src="http://consultingblogs.emc.com/aggbug.aspx?PostID=16193" width="1" height="1"&gt;</description><category domain="http://consultingblogs.emc.com/matthall/archive/tags/.NET/default.aspx">.NET</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/WCF/default.aspx">WCF</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/ANTS/default.aspx">ANTS</category></item><item><title>WCF Intermediaries with Binding Switching</title><link>http://consultingblogs.emc.com/matthall/archive/2009/08/20/wcf-intermediaries-with-binding-switching.aspx</link><pubDate>Thu, 20 Aug 2009 08:31:00 GMT</pubDate><guid isPermaLink="false">e847c0e7-38d9-45c0-b593-56747303e088:16091</guid><dc:creator>Matthew.Hall</dc:creator><slash:comments>7</slash:comments><comments>http://consultingblogs.emc.com/matthall/comments/16091.aspx</comments><wfw:commentRss>http://consultingblogs.emc.com/matthall/commentrss.aspx?PostID=16091</wfw:commentRss><description>&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;I have been working on a WCF intermediary that receives messages from a 3&lt;SUP&gt;rd&lt;/SUP&gt; party and routes this onto another WCF service. The intermediary service uses basicHttpBinding whereas the destination service is netTcpBinding. I have worked on similar patterns before, but they always had the same binding on each service and they worked well, therefore I hadn’t anticipated any problems.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;However, once I had this all set-up I started receiving the following error on the intermediary service: “Addressing Version 'AddressingNone (http://schemas.microsoft.com/ws/2005/05/addressing/none)' does not support adding WS-Addressing headers.” &lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;This error appears to stem from the fact that basicHttpBinding is using SOAP 1.1 for the message version and no WS-Addressing, whereas netTcpBinding is using SOAP 1.2 for the message version with WS-Addressing. I had originally attempted to use custom bindings to get over this hurdle without much success so adopted to implement a message conversion in the intermediary service instead.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;Your typical intermediary service would tend to have a service contract that is defined as so:&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;[&lt;SPAN style="COLOR:#2b91af;"&gt;ServiceContract&lt;/SPAN&gt;]&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;public&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt; &lt;SPAN style="COLOR:blue;"&gt;interface&lt;/SPAN&gt; &lt;SPAN style="COLOR:#2b91af;"&gt;IMyIntermediaryService&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;{&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;[&lt;SPAN style="COLOR:#2b91af;"&gt;OperationContract&lt;FONT color=#000000&gt;(&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="COLOR:#2b91af;"&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; IsOneWay = &lt;SPAN style="COLOR:blue;"&gt;false&lt;/SPAN&gt;, &lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; IsInitiating = &lt;SPAN style="COLOR:blue;"&gt;true&lt;/SPAN&gt;, &lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; IsTerminating = &lt;SPAN style="COLOR:blue;"&gt;false&lt;/SPAN&gt;, &lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Action = &lt;SPAN style="COLOR:#a31515;"&gt;"*"&lt;/SPAN&gt;, &lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;ReplyAction = &lt;SPAN style="COLOR:#a31515;"&gt;"*"&lt;/SPAN&gt;)]&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;[&lt;SPAN style="COLOR:#2b91af;"&gt;FaultContract&lt;/SPAN&gt;(&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="COLOR:blue;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; typeof&lt;/SPAN&gt;(&lt;SPAN style="COLOR:#2b91af;"&gt;MyCustomFault&lt;/SPAN&gt;),&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Namespace = &lt;SPAN style="COLOR:#a31515;"&gt;"http://mydomain.com/myapplication/2009/08"&lt;/SPAN&gt;)]&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="COLOR:#2b91af;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="COLOR:#2b91af;"&gt;&amp;nbsp;&amp;nbsp; Message&lt;/SPAN&gt; ProcessMessage(&lt;SPAN style="COLOR:#2b91af;"&gt;Message&lt;/SPAN&gt; message);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;SPAN style="FONT-SIZE:10pt;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;The implementation of the ProcessMessage method would be something like the following. Note that this is a very basic example to be succinct, you would need to include error handling etc. In addition we are defining the destination endpoint in the web.config using the name “destination” as the identifier.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;public&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt; &lt;SPAN style="COLOR:#2b91af;"&gt;Message&lt;/SPAN&gt; ProcessMessage(&lt;SPAN style="COLOR:#2b91af;"&gt;Message&lt;/SPAN&gt; message)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="COLOR:blue;"&gt;&amp;nbsp;&amp;nbsp; var&lt;/SPAN&gt; channelFactory = &lt;SPAN style="COLOR:blue;"&gt;new&lt;/SPAN&gt; &lt;SPAN style="COLOR:#2b91af;"&gt;ChannelFactory&lt;/SPAN&gt;&amp;lt;&lt;SPAN style="COLOR:#2b91af;"&gt;&lt;SPAN style="COLOR:#2b91af;"&gt;IMyIntermediaryService&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&amp;gt;(&lt;SPAN style="COLOR:#a31515;"&gt;"destination"&lt;/SPAN&gt;);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="COLOR:#2b91af;"&gt;&lt;SPAN style="COLOR:#2b91af;"&gt;&amp;nbsp;&amp;nbsp; IMyIntermediaryService&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt; forwardingChannel = channelFactory.CreateChannel();&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="COLOR:#2b91af;"&gt;&amp;nbsp;&amp;nbsp; Message&lt;/SPAN&gt; responseMessage = forwardingChannel.ProcessMessage(message);&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp; channelFactory.Close();&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="COLOR:blue;"&gt;&amp;nbsp;&amp;nbsp; return&lt;/SPAN&gt; responseMessage;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;SPAN style="FONT-SIZE:10pt;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;Now, in order to handle the message conversion you would supplement the above code so that it identifies the message version received. Note that we are solely checking for netTcpBinding here, but this code could be modified to expand upon this to make it more generic.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;public&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt; &lt;SPAN style="COLOR:#2b91af;"&gt;Message&lt;/SPAN&gt; ProcessMessage(&lt;SPAN style="COLOR:#2b91af;"&gt;Message&lt;/SPAN&gt; message)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="COLOR:green;"&gt;&amp;nbsp;&amp;nbsp; // Get the message version&lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#2b91af;"&gt;MessageVersion&lt;/SPAN&gt; returnMessageVersion = message.Version;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR:blue;"&gt;bool&lt;/SPAN&gt; messageConverted = &lt;SPAN style="COLOR:blue;"&gt;false&lt;/SPAN&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR:blue;"&gt;var&lt;/SPAN&gt; channelFactory = &lt;SPAN style="COLOR:blue;"&gt;new&lt;/SPAN&gt; &lt;SPAN style="COLOR:#2b91af;"&gt;ChannelFactory&lt;/SPAN&gt;&amp;lt;&lt;SPAN style="COLOR:#2b91af;"&gt;&lt;SPAN style="COLOR:#2b91af;"&gt;IMyIntermediaryService&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&amp;gt;(&lt;SPAN style="COLOR:#a31515;"&gt;"destination"&lt;/SPAN&gt;);&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;/SPAN&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="COLOR:#2b91af;"&gt;&lt;SPAN style="COLOR:#2b91af;"&gt;&amp;nbsp;&amp;nbsp; IMyIntermediaryService&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt; forwardingChannel = channelFactory.CreateChannel();&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="COLOR:green;"&gt;&amp;nbsp;&amp;nbsp; // If we are using NetTcpBinding make sure that the message we are sending is &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="COLOR:green;"&gt;&amp;nbsp;&amp;nbsp; // Soap 1.2 WS-Addressing if it&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="COLOR:green;"&gt; is not already&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR:blue;"&gt;if&lt;/SPAN&gt; (channelFactory.Endpoint.Binding.GetType() == &lt;SPAN style="COLOR:blue;"&gt;typeof&lt;/SPAN&gt;(&lt;SPAN style="COLOR:#2b91af;"&gt;NetTcpBinding&lt;/SPAN&gt;) &lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;amp;&amp;amp; message.Version != &lt;SPAN style="COLOR:#2b91af;"&gt;MessageVersion&lt;/SPAN&gt;.Soap12WSAddressing10)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; message = CreateMessageCopy(message, &lt;SPAN style="COLOR:#2b91af;"&gt;MessageVersion&lt;/SPAN&gt;.Soap12WSAddressing10);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;messageConverted = &lt;SPAN style="COLOR:blue;"&gt;true&lt;/SPAN&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp; }&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#2b91af;"&gt;Message&lt;/SPAN&gt; responseMessage = forwardingChannel.ProcessMessage(message);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp; channelFactory.Close();&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR:green;"&gt;// Convert the message type back to that of the original if necessary&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR:blue;"&gt;if&lt;/SPAN&gt; (messageConverted)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; responseMessage = CreateMessageCopy(responseMessage, returnMessageVersion);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp; }&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="COLOR:blue;"&gt;&amp;nbsp;&amp;nbsp; return&lt;/SPAN&gt; responseMessage;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;SPAN style="FONT-SIZE:10pt;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;}&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;Note that you must also covert the result back to the original format if a conversion has taken place otherwise the client will throw an exception “An error occurred while receiving the HTTP response to http://myserver/myservice.svc. This could be due to the service endpoint binding not using the HTTP protocol. This could also be due to an HTTP request context being aborted by the server (possibly due to the service shutting down). See server logs for more details.”&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;The conversion method would be something like the following&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;private&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt; &lt;SPAN style="COLOR:blue;"&gt;static&lt;/SPAN&gt; &lt;SPAN style="COLOR:#2b91af;"&gt;Message&lt;/SPAN&gt; CreateMessageCopy(&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR:#2b91af;"&gt;Message&lt;/SPAN&gt; message, &lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR:#2b91af;"&gt;MessageVersion&lt;/SPAN&gt; newMessageVersion)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#2b91af;"&gt;Message&lt;/SPAN&gt; copy = &lt;SPAN style="COLOR:#2b91af;"&gt;Message&lt;/SPAN&gt;.CreateMessage(&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; newMessageVersion, &lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; message.Headers.Action, &lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; message.GetReaderAtBodyContents());&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;nbsp;&amp;nbsp; copy.Properties.CopyProperties(message.Properties);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="COLOR:blue;"&gt;&amp;nbsp;&amp;nbsp; return&lt;/SPAN&gt; copy;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;SPAN style="FONT-SIZE:10pt;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;}&lt;/SPAN&gt;&lt;/P&gt;&lt;img src="http://consultingblogs.emc.com/aggbug.aspx?PostID=16091" width="1" height="1"&gt;</description><category domain="http://consultingblogs.emc.com/matthall/archive/tags/.NET/default.aspx">.NET</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/WCF/default.aspx">WCF</category></item><item><title>Castle Windsor and non-HTTP Protocol WCF Services</title><link>http://consultingblogs.emc.com/matthall/archive/2009/08/18/castle-windsor-and-non-http-protocol-wcf-services.aspx</link><pubDate>Tue, 18 Aug 2009 07:46:00 GMT</pubDate><guid isPermaLink="false">e847c0e7-38d9-45c0-b593-56747303e088:16076</guid><dc:creator>Matthew.Hall</dc:creator><slash:comments>0</slash:comments><comments>http://consultingblogs.emc.com/matthall/comments/16076.aspx</comments><wfw:commentRss>http://consultingblogs.emc.com/matthall/commentrss.aspx?PostID=16076</wfw:commentRss><description>&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;I had been working quite happily with &lt;/FONT&gt;&lt;A href="http://www.castleproject.org/container/index.html"&gt;&lt;FONT face=Calibri size=3&gt;Castle Windsor&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Calibri size=3&gt; and WCF services using &lt;/FONT&gt;&lt;A href="http://www.castleproject.org/container/facilities/trunk/wcf/index.html"&gt;&lt;FONT face=Calibri color=#800080 size=3&gt;WCF Facility&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Calibri size=3&gt; when implemented through an HTTP binding of some description. You simply hook in the DefaultServiceHostFactory from Castle.Facilities.WcfIntegration into your ServiceHost declaration such as the following example:&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;BACKGROUND:yellow;FONT-FAMILY:'Courier New';mso-highlight:yellow;mso-no-proof:yes;"&gt;&amp;lt;%&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;@&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt; &lt;SPAN style="COLOR:#a31515;"&gt;ServiceHost&lt;/SPAN&gt; &lt;SPAN style="COLOR:red;"&gt;Language&lt;/SPAN&gt;&lt;SPAN style="COLOR:blue;"&gt;="C#"&lt;/SPAN&gt; &lt;SPAN style="COLOR:red;"&gt;Debug&lt;/SPAN&gt;&lt;SPAN style="COLOR:blue;"&gt;="true"&lt;/SPAN&gt; &lt;SPAN style="COLOR:red;"&gt;Service&lt;/SPAN&gt;&lt;SPAN style="COLOR:blue;"&gt;="MyService"&lt;/SPAN&gt; &lt;SPAN style="COLOR:red;"&gt;CodeBehind&lt;/SPAN&gt;&lt;SPAN style="COLOR:blue;"&gt;="MyService.svc.cs"&lt;/SPAN&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:red;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;Factory&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;="Castle.Facilities.WcfIntegration.DefaultServiceHostFactory, Castle.Facilities.WcfIntegration"&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt; &lt;SPAN style="BACKGROUND:yellow;mso-highlight:yellow;"&gt;%&amp;gt;&lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;You would then register the WindsorContainer within the Application_Start event of your Global.asax like so or however you prefer register your components, the point being it is done in the Application_Start event.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;protected&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt; &lt;SPAN style="COLOR:blue;"&gt;void&lt;/SPAN&gt; Application_Start(&lt;SPAN style="COLOR:blue;"&gt;object&lt;/SPAN&gt; sender, &lt;SPAN style="COLOR:#2b91af;"&gt;EventArgs&lt;/SPAN&gt; e)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;var&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt; container = &lt;SPAN style="COLOR:blue;"&gt;new&lt;/SPAN&gt; &lt;SPAN style="COLOR:#2b91af;"&gt;WindsorContainer&lt;/SPAN&gt;(&lt;SPAN style="COLOR:#a31515;"&gt;"ioc.config"&lt;/SPAN&gt;);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:#2b91af;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;DefaultServiceHostFactory&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;.RegisterContainer(container.Kernel);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;SPAN style="FONT-SIZE:10pt;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;However, let’s say you are binding to net.tcp and &lt;/FONT&gt;&lt;A href="http://msdn.microsoft.com/en-us/library/ms734677.aspx"&gt;&lt;FONT face=Calibri color=#800080 size=3&gt;hosting in WAS&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Calibri size=3&gt; (Windows Process Activation Service)? This event will not get called, so you need to find another way to initialise your Castle Windsor container.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;&lt;FONT face=Calibri size=3&gt;I confess I spent a while looking at the Host Factory in more detail, looking to wrap the DefaultServiceHostFactory. However, there appears to be a far simpler solution and that is to make use of the little documented AppInitialize method. If you create a class (any class), put it into the ASP.NET &lt;/FONT&gt;&lt;A href="http://msdn.microsoft.com/en-us/library/t990ks23(VS.80).aspx"&gt;&lt;FONT face=Calibri size=3&gt;App_Code&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Calibri size=3&gt; folder in your project and give it a method signature as defined below, this little baby will get fired exactly when you want it to. You can then initialise your IoC container in there.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;public&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt; &lt;SPAN style="COLOR:blue;"&gt;class&lt;/SPAN&gt; &lt;SPAN style="COLOR:#2b91af;"&gt;InitialiseService&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;///&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:green;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;lt;summary&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;///&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:green;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt; Application initialisation method where we register our IOC container.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;///&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:green;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&amp;lt;/summary&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR:blue;"&gt;public&lt;/SPAN&gt; &lt;SPAN style="COLOR:blue;"&gt;static&lt;/SPAN&gt; &lt;SPAN style="COLOR:blue;"&gt;void&lt;/SPAN&gt; AppInitialize()&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR:blue;"&gt;var&lt;/SPAN&gt; container = &lt;SPAN style="COLOR:blue;"&gt;new&lt;/SPAN&gt; &lt;SPAN style="COLOR:#2b91af;"&gt;WindsorContainer&lt;/SPAN&gt;(&lt;SPAN style="COLOR:#a31515;"&gt;"ioc.config"&lt;/SPAN&gt;);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#2b91af;"&gt;DefaultServiceHostFactory&lt;/SPAN&gt;.RegisterContainer(container.Kernel);&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;LINE-HEIGHT:normal;mso-layout-grid-align:none;"&gt;&lt;SPAN style="FONT-SIZE:10pt;FONT-FAMILY:'Courier New';mso-no-proof:yes;"&gt;&lt;SPAN style="mso-spacerun:yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;SPAN style="FONT-SIZE:10pt;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';mso-no-proof:yes;mso-fareast-font-family:Calibri;mso-fareast-theme-font:minor-latin;mso-fareast-language:EN-US;mso-ansi-language:EN-GB;mso-bidi-language:AR-SA;"&gt;}&lt;/SPAN&gt;&lt;img src="http://consultingblogs.emc.com/aggbug.aspx?PostID=16076" width="1" height="1"&gt;</description><category domain="http://consultingblogs.emc.com/matthall/archive/tags/.NET/default.aspx">.NET</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/WCF/default.aspx">WCF</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/IOC/default.aspx">IOC</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/Castle+Windsor/default.aspx">Castle Windsor</category></item><item><title>Castle WcfIntegrationFacility "Could not find a component with the name &lt;my component name&gt;, did you forget to register it?"</title><link>http://consultingblogs.emc.com/matthall/archive/2009/07/10/castle-wcfintegrationfacility-quot-could-not-find-a-component-with-the-name-lt-my-component-name-gt-did-you-forget-to-register-it-quot.aspx</link><pubDate>Fri, 10 Jul 2009 16:40:00 GMT</pubDate><guid isPermaLink="false">e847c0e7-38d9-45c0-b593-56747303e088:15818</guid><dc:creator>Matthew.Hall</dc:creator><slash:comments>0</slash:comments><comments>http://consultingblogs.emc.com/matthall/comments/15818.aspx</comments><wfw:commentRss>http://consultingblogs.emc.com/matthall/commentrss.aspx?PostID=15818</wfw:commentRss><description>






&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;This post is more a reference to me in case I come across this again, but also to anyone else that may experience the same error, as I couldn’t find any reference to it when searching online. &lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;It was one of those infuriating situations where you believe everything is set-up how you expect, but you keep receiving an unexpected error. Therefore you know something isn’t quite right somewhere along the line and most likely something simple. So, after spending a bit of time going through the debug motions you obtain the extra eyes of a few colleagues to verify your sanity. Alas, still no joy. Then, after more frustration it suddenly springs out at you and you groan with the simplicity of it.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;Anyway, in my case I was attempting to use &lt;A href="http://www.castleproject.org/container/index.html"&gt;Castle&lt;/A&gt; and &lt;A href="http://msdn.microsoft.com/en-us/netframework/aa663324.aspx"&gt;WCF&lt;/A&gt;. We had this working fine on various projects using the &lt;A href="http://www.castleproject.org/container/facilities/trunk/wcf/index.html"&gt;WcfIntegrationFacility&lt;/A&gt;, but for some reason on this new set-up we were experiencing the error: “Could not find a component with the name &amp;lt;my component name&amp;gt;, did you forget to register it?”&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;It turns out that the id on the component element in the Castle configuration must &lt;B style="mso-bidi-font-weight:normal;"&gt;exactly&lt;/B&gt; match the class type. For example in the configuration snippet below, the two highlighted must be the same otherwise you get the error described.&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:#a31515;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;components&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:#a31515;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;component&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:red;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;id&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;"&lt;SPAN style="BACKGROUND:yellow;COLOR:blue;mso-highlight:yellow;"&gt;This.Should.Match&lt;/SPAN&gt;"&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:red;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;service&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;"&lt;SPAN style="COLOR:blue;"&gt;Some.Interface, Some.Assembly&lt;/SPAN&gt;"&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:red;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;type&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;"&lt;SPAN style="BACKGROUND:yellow;COLOR:blue;mso-highlight:yellow;"&gt;This.Should.Match&lt;/SPAN&gt;&lt;SPAN style="COLOR:blue;"&gt;, Some.Assembly&lt;/SPAN&gt;"&lt;SPAN style="COLOR:blue;"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:#a31515;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;component&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;&amp;nbsp; &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:#a31515;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;components&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 0pt;"&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;LINE-HEIGHT:115%;FONT-FAMILY:'Courier New';"&gt;&lt;/SPAN&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN:0cm 0cm 10pt;"&gt;I won’t be forgetting that one in a hurry.&lt;/P&gt;&lt;img src="http://consultingblogs.emc.com/aggbug.aspx?PostID=15818" width="1" height="1"&gt;</description><category domain="http://consultingblogs.emc.com/matthall/archive/tags/WCF/default.aspx">WCF</category><category domain="http://consultingblogs.emc.com/matthall/archive/tags/Castle+Windsor/default.aspx">Castle Windsor</category></item></channel></rss>
