<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://weblogs.asp.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Paolo's Notes</title><link>http://weblogs.asp.net/pmarcucci/default.aspx</link><description>BA by day, sleepy coder by night...</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP1 (Build: 20510.895)</generator><item><title>Voice 2.2 test</title><link>http://weblogs.asp.net/pmarcucci/archive/2004/04/24/119368.aspx</link><pubDate>Sat, 24 Apr 2004 11:40:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:119368</guid><dc:creator>Pmarcucci</dc:creator><slash:comments>8</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/pmarcucci/rsscomments.aspx?PostID=119368</wfw:commentRss><comments>http://weblogs.asp.net/pmarcucci/archive/2004/04/24/119368.aspx#comments</comments><description>Third test from Voice 2.2&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=119368" width="1" height="1"&gt;</description></item><item><title>Free bug tracking offer</title><link>http://weblogs.asp.net/pmarcucci/archive/2004/01/31/65468.aspx</link><pubDate>Sat, 31 Jan 2004 08:59:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:65468</guid><dc:creator>Pmarcucci</dc:creator><slash:comments>3</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/pmarcucci/rsscomments.aspx?PostID=65468</wfw:commentRss><comments>http://weblogs.asp.net/pmarcucci/archive/2004/01/31/65468.aspx#comments</comments><description>&lt;P&gt;This is making the rounds...&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www.axosoft.com/"&gt;Axosoft&lt;/A&gt; is offering bloggers a free 3-user version of their .NET &amp;amp; SQL based OnTime &lt;A href="http://www.axosoft.com/"&gt;defect tracking software&lt;/A&gt; (&lt;A href="http://www.axosoft.com/ontime.htm"&gt;bug tracking software&lt;/A&gt;).&amp;nbsp; For more information, visit &lt;A href="http://www.axosoft.com/Free3UserOffer.htm"&gt;http://www.axosoft.com/Free3UserOffer.htm&lt;/A&gt;.&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=65468" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/pmarcucci/archive/tags/.NET+Development/default.aspx">.NET Development</category></item><item><title>The fun is back</title><link>http://weblogs.asp.net/pmarcucci/archive/2004/01/28/63990.aspx</link><pubDate>Thu, 29 Jan 2004 00:49:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:63990</guid><dc:creator>Pmarcucci</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/pmarcucci/rsscomments.aspx?PostID=63990</wfw:commentRss><comments>http://weblogs.asp.net/pmarcucci/archive/2004/01/28/63990.aspx#comments</comments><description>&lt;P&gt;Well, I'm going on developing infrastructure code for NFFTI (yeah, I know. I'll post more gruesome details later) and I realized a simple fact:&lt;/P&gt;
&lt;P&gt;I'm having fun.&lt;/P&gt;
&lt;P&gt;It has been years since I had real fun coding, since Turbo Pascal 5.5 or the early Visual Basic 6 days. Java had never been "fun", just a tool I had to use for my job. And nobody in his clear mind would call PL/SQL a fun language or development environment...&lt;/P&gt;
&lt;P&gt;But C# and Visual Studio and (most important) the incredible community around them is making the task of sitting down and pounding code a non-dreaded occupation anymore. I have some people to thank for this so, in perfect Academy Awards style, here they are in no particular order:&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www.testdriven.net/"&gt;Jamie Cansdale&lt;/A&gt;, &lt;A href="http://www.peterprovost.org/weblog/"&gt;Peter Provost&lt;/A&gt;, &lt;A href="http://www.bristowe.com/blog/"&gt;John Bristowe&lt;/A&gt;, &lt;A href="http://weblogs.asp.net/ericjsmith/"&gt;Eric J. Smith&lt;/A&gt;, &lt;A href="http://www.netcrucible.com/blog/"&gt;Joshua Allen&lt;/A&gt;, &lt;A href="http://blogs.msdn.com/jasmo/"&gt;Jason Moore&lt;/A&gt;, Dominic Pease, Kurt Mackey, Paul Hill, Peter Dampier and all the other people I don't know personally but are doing an great job of pushing forward with the community.&lt;/P&gt;
&lt;P&gt;Oh, and thanks to &lt;A href="http://scoble.weblogs.com/"&gt;Robert Scoble&lt;/A&gt; to bring most of these people at PDC03. That was mondo fun :)&lt;/P&gt;
&lt;DIV&gt;
&lt;P&gt;[Now Playing: - Promised You A Miracle - Simple Minds]&lt;/P&gt;&lt;/DIV&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=63990" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/pmarcucci/archive/tags/.NET+Development/default.aspx">.NET Development</category><category domain="http://weblogs.asp.net/pmarcucci/archive/tags/NFFTI/default.aspx">NFFTI</category></item><item><title>WS POLICY SI TEH WIN!!111</title><link>http://weblogs.asp.net/pmarcucci/archive/2004/01/22/61504.aspx</link><pubDate>Thu, 22 Jan 2004 13:40:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:61504</guid><dc:creator>Pmarcucci</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/pmarcucci/rsscomments.aspx?PostID=61504</wfw:commentRss><comments>http://weblogs.asp.net/pmarcucci/archive/2004/01/22/61504.aspx#comments</comments><description>&lt;DIV&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;SPAN class=543123406-22012004&gt;In the &lt;A title=http://weblogs.asp.net/pmarcucci/archive/2004/01/21/61249.aspx#FeedBack href="/pmarcucci/archive/2004/01/21/61249.aspx#FeedBack"&gt;comments&lt;/A&gt; on my previous post, &lt;A title=http://bristowe.com/blog/ href="http://bristowe.com/blog/"&gt;John Bristowe&lt;/A&gt; gently offered his help to guide me across the Dead^H^H^H^H WSE 2.0 Marshes... &lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;SPAN class=543123406-22012004&gt;Fool! He didn't know what was expecting him! But in the end, he provided me with invaluable knowledge, tips and simply buckets of code big enough to drive into my thick skull a faint glimmer of comprehension about this whole new way to deal with web services.&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;SPAN class=543123406-22012004&gt;So, what was my initial take, based on a cursory reading of the few web pages I was able to find? A procedural based, hardcoded approach to the authentication/signature/authorization/encryption problem. Plenty of code (to be tested) and lots of possible failure points. Plus, it wasn't really working anyways...&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;SPAN class=543123406-22012004&gt;So John introduced me to the marvels of Policies. A declarative approach, how novel! Basically this removed all the ugly plumbing code from my web methods and put all the business knowledge about, say, authorization into a series of XML files that can be edited at runtime.&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;SPAN class=543123406-22012004&gt;So, what about some samples? Sure thing! After having enabled WSE 2.0 on both Nfftiws (the web service) and Test Harness (the, duh, test harness), I modified Test Harness' app.config file thusly (sorry, I always wanted to use this word...):&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana color=#808080 size=2&gt;&lt;SPAN class=543123406-22012004&gt;&amp;lt;?xml version="1.0" encoding="utf-8"?&amp;gt;&lt;BR&gt;&amp;lt;configuration&amp;gt;&lt;BR&gt;&amp;nbsp; &amp;lt;configSections&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;section name="microsoft.web.services" type="Microsoft.Web.Services.Configuration.WebServicesConfiguration, Microsoft.Web.Services, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" /&amp;gt;&lt;BR&gt;&amp;nbsp; &amp;lt;/configSections&amp;gt;&lt;BR&gt;&amp;nbsp; &amp;lt;microsoft.web.services&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;policy&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;send&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;cache name="policyCache.xml" /&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/send&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/policy&amp;gt;&lt;BR&gt;&amp;nbsp; &amp;lt;/microsoft.web.services&amp;gt;&lt;BR&gt;&amp;lt;/configuration&amp;gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;SPAN class=543123406-22012004&gt;The section "microsoft.web.services" enables WSE 2.0 for this project and the element named the same way defines a send policy to be defined in the policyCache.xml file. That, by the way, is filled by these characters:&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;SPAN class=543123406-22012004&gt;&lt;FONT color=#808080&gt;&amp;lt;?xml version="1.0" encoding="utf-8"?&amp;gt;&lt;BR&gt;&amp;lt;policyDocument xmlns="&lt;/FONT&gt;&lt;A title=http://schemas.microsoft.com/wse/2003/06/Policy href="http://schemas.microsoft.com/wse/2003/06/Policy"&gt;&lt;FONT title=http://schemas.microsoft.com/wse/2003/06/Policy color=#808080&gt;http://schemas.microsoft.com/wse/2003/06/Policy&lt;/FONT&gt;&lt;/A&gt;&lt;FONT color=#808080&gt;"&amp;gt;&lt;BR&gt;&amp;nbsp; &amp;lt;mappings xmlns:wse="&lt;/FONT&gt;&lt;A title=http://schemas.microsoft.com/wse/2003/06/Policy href="http://schemas.microsoft.com/wse/2003/06/Policy"&gt;&lt;FONT title=http://schemas.microsoft.com/wse/2003/06/Policy color=#808080&gt;http://schemas.microsoft.com/wse/2003/06/Policy&lt;/FONT&gt;&lt;/A&gt;&lt;FONT color=#808080&gt;"&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;mapDefault policy="#policy-b298142f-0c50-446b-8938-079b27891512" /&amp;gt;&lt;BR&gt;&amp;nbsp; &amp;lt;/mappings&amp;gt;&lt;BR&gt;&amp;nbsp; &amp;lt;policies xmlns:wsu="&lt;/FONT&gt;&lt;A title=http://schemas.xmlsoap.org/ws/2002/07/utility href="http://schemas.xmlsoap.org/ws/2002/07/utility"&gt;&lt;FONT title=http://schemas.xmlsoap.org/ws/2002/07/utility color=#808080&gt;http://schemas.xmlsoap.org/ws/2002/07/utility&lt;/FONT&gt;&lt;/A&gt;&lt;FONT color=#808080&gt;"&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;wsp:Policy wsu:Id="policy-b298142f-0c50-446b-8938-079b27891512" xmlns:wsp="&lt;/FONT&gt;&lt;A title=http://schemas.xmlsoap.org/ws/2002/12/policy href="http://schemas.xmlsoap.org/ws/2002/12/policy"&gt;&lt;FONT title=http://schemas.xmlsoap.org/ws/2002/12/policy color=#808080&gt;http://schemas.xmlsoap.org/ws/2002/12/policy&lt;/FONT&gt;&lt;/A&gt;&lt;FONT color=#808080&gt;"&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;wsse:Integrity wsp:Usage="wsp:Required" xmlns:wsse="&lt;/FONT&gt;&lt;A title=http://schemas.xmlsoap.org/ws/2002/12/secext href="http://schemas.xmlsoap.org/ws/2002/12/secext"&gt;&lt;FONT title=http://schemas.xmlsoap.org/ws/2002/12/secext color=#808080&gt;http://schemas.xmlsoap.org/ws/2002/12/secext&lt;/FONT&gt;&lt;/A&gt;&lt;FONT color=#808080&gt;"&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;wsse:TokenInfo&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;SecurityToken xmlns="&lt;/FONT&gt;&lt;A title=http://schemas.xmlsoap.org/ws/2002/12/secext href="http://schemas.xmlsoap.org/ws/2002/12/secext"&gt;&lt;FONT title=http://schemas.xmlsoap.org/ws/2002/12/secext color=#808080&gt;http://schemas.xmlsoap.org/ws/2002/12/secext&lt;/FONT&gt;&lt;/A&gt;&lt;FONT color=#808080&gt;"&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;wsse:TokenType&amp;gt;wsse:UsernameToken&amp;lt;/wsse:TokenType&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;/SecurityToken&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/wsse:TokenInfo&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;wsse:MessageParts Dialect="&lt;/FONT&gt;&lt;A title='http://schemas.xmlsoap.org/2002/12/wsse#part"&gt;wsp:Body()&lt;/wsse:MessageParts' href='http://schemas.xmlsoap.org/2002/12/wsse#part"&gt;wsp:Body()&lt;/wsse:MessageParts'&gt;&lt;FONT title='http://schemas.xmlsoap.org/2002/12/wsse#part"&gt;wsp:Body()&lt;/wsse:MessageParts' color=#808080&gt;http://schemas.xmlsoap.org/2002/12/wsse#part"&amp;gt;wsp:Body()&amp;lt;/wsse:MessageParts&lt;/FONT&gt;&lt;/A&gt;&lt;FONT color=#808080&gt;&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/wsse:Integrity&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/wsp:Policy&amp;gt;&lt;BR&gt;&amp;nbsp; &amp;lt;/policies&amp;gt;&lt;BR&gt;&amp;lt;/policyDocument&amp;gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;SPAN class=543123406-22012004&gt;Pretty ugly, eh? Luckily this file was generated automatically by the same property dialog where you enable WSE 2.0, by going to the Policy tab and clicking on the Create/Edit... button in the Sending Side Policy Cache group. When the Wse Security Policy Editor dialog pops up, click on Add Policy, select "default" as the Service Location, select the Require Signature checkbox, enter UserNameToken as the token Type, leave all the other fields untouched and click Ok. The file policyCache will be created and dropped &lt;STRONG&gt;in the wrong place&lt;/STRONG&gt;. You will have to manually copy it from the project top folder to bin/debug for the purpose of development. We'll see in later posts how to deal with deployment.&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;SPAN class=543123406-22012004&gt;Ok, what have we achieved? Now we have a client application that knows how to speak WSE and will make sure to authenticate its method calls to the target web service. &lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;SPAN class=543123406-22012004&gt;Now we have to configure the web service... Again, enable WSE 2.0 for this project. Then modify web.config like this:&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;SPAN class=543123406-22012004&gt;just after &amp;lt;configuration&amp;gt;, before &amp;lt;system.web&amp;gt;, add:&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana color=#808080 size=2&gt;&lt;SPAN class=543123406-22012004&gt;&amp;nbsp; &amp;lt;configSections&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;section name="microsoft.web.services" type="Microsoft.Web.Services.Configuration.WebServicesConfiguration, Microsoft.Web.Services, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" /&amp;gt;&lt;BR&gt;&amp;nbsp; &amp;lt;/configSections&amp;gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana color=#000000 size=2&gt;&lt;SPAN class=543123406-22012004&gt;Just before &amp;lt;/system.web&amp;gt; add:&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana color=#808080 size=2&gt;&lt;SPAN class=543123406-22012004&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;webServices&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;soapExtensionTypes&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;add type="Microsoft.Web.Services.WebServicesExtension, Microsoft.Web.Services, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" priority="1" group="0" /&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/soapExtensionTypes&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/webServices&amp;gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana color=#000000 size=2&gt;&lt;SPAN class=543123406-22012004&gt;Finally, after &amp;lt;/system.web&amp;gt;, add:&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;SPAN class=543123406-22012004&gt;&lt;FONT color=#808080&gt;&amp;nbsp; &amp;lt;microsoft.web.services&amp;gt;&lt;BR&gt;&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;lt;securityTokenManager type="Nfftiws.SecurityPassword, Nfftiws" xmlns:wsse="&lt;/FONT&gt;&lt;A title=http://schemas.xmlsoap.org/ws/2002/12/secext href="http://schemas.xmlsoap.org/ws/2002/12/secext"&gt;&lt;FONT title=http://schemas.xmlsoap.org/ws/2002/12/secext color=#808080&gt;http://schemas.xmlsoap.org/ws/2002/12/secext&lt;/FONT&gt;&lt;/A&gt;&lt;FONT color=#808080&gt;" qname="wsse:UsernameToken" /&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/security&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;policy&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;receive&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;cache name="&lt;EM&gt;path to the project folder&lt;/EM&gt;\NFFTIWS\bin\inboundPolicy.xml" /&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/receive&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/policy&amp;gt;&lt;BR&gt;&amp;nbsp; &amp;lt;/microsoft.web.services&amp;gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana color=#000000 size=2&gt;&lt;SPAN class=543123406-22012004&gt;While the first two pieces of XML are basically boilerplate (I already feel the wrath of the More Competent Developers(tm) out there), the last fragment defines the method that implements the authentication (Nfftiws.SecurityPassword) and points to the file defining the&amp;nbsp;authorization policy that will be applied on the incoming messages. But that's all for web.config, in the next post we'll see what's in inboundPolicy.xml.&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Verdana color=#000000 size=2&gt;&lt;SPAN class=543123406-22012004&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;/DIV&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=61504" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/pmarcucci/archive/tags/.NET+Development/default.aspx">.NET Development</category><category domain="http://weblogs.asp.net/pmarcucci/archive/tags/NFFTI/default.aspx">NFFTI</category></item><item><title>WS-I thinghies</title><link>http://weblogs.asp.net/pmarcucci/archive/2004/01/21/61249.aspx</link><pubDate>Thu, 22 Jan 2004 01:28:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:61249</guid><dc:creator>Pmarcucci</dc:creator><slash:comments>2</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/pmarcucci/rsscomments.aspx?PostID=61249</wfw:commentRss><comments>http://weblogs.asp.net/pmarcucci/archive/2004/01/21/61249.aspx#comments</comments><description>&lt;P&gt;So we have Nfftiws (the web service that deals with Users). We can&amp;nbsp;call the GetUser method by passing email and password and get all the user's info and...&lt;/P&gt;
&lt;P&gt;Now wait a second. &lt;EM&gt;Passing email and password&lt;/EM&gt; to a web service? Using SOAP? On the public internet?&lt;/P&gt;
&lt;P&gt;You have to be quite brave to do that...&lt;/P&gt;
&lt;P&gt;So, what can we do to avoid snooping, spoofing and general bad things happen to our web service? Luckily there's an industry-wide effort going on to attack these issues called WS-I. There are cross platform protocols for security, authentication, encryption, etc... Microsoft's implementation of these set of protocols is provided by WSE 2.0 (now in technical preview stage).&lt;/P&gt;
&lt;P&gt;Once you download and install it, you have a new entry in the pop up menu that comes out when you right click on a project, where you can enable WSE and set a lot of other options.&lt;/P&gt;
&lt;P&gt;There is a big downside. The documentation is... uhm... how can I say this in a nice way... lacking? :)&lt;/P&gt;
&lt;P&gt;So I had to dig deep into Google and finally got a series of pages that, while none of them was complete, gave me a general idea on how to use WSE for my project...&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=61249" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/pmarcucci/archive/tags/.NET+Development/default.aspx">.NET Development</category><category domain="http://weblogs.asp.net/pmarcucci/archive/tags/NFFTI/default.aspx">NFFTI</category></item><item><title>Hashtables and Web Services and .NET. What's up with that?</title><link>http://weblogs.asp.net/pmarcucci/archive/2004/01/21/61232.aspx</link><pubDate>Thu, 22 Jan 2004 00:55:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:61232</guid><dc:creator>Pmarcucci</dc:creator><slash:comments>3</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/pmarcucci/rsscomments.aspx?PostID=61232</wfw:commentRss><comments>http://weblogs.asp.net/pmarcucci/archive/2004/01/21/61232.aspx#comments</comments><description>&lt;p&gt;The UserSet class was supposed to be implemented like this:&lt;/p&gt; &lt;p&gt;&lt;font color="#0000ff"&gt;public class UserSet&lt;br /&gt; {&lt;br /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp; public NFFTI.User user;&lt;br /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp; public NFFTI.GroupCollection groupCollection;&lt;br /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp; public&amp;nbsp;Hashtable propertyCollection;&lt;br /&gt;&lt;/font&gt;&lt;font color="#0000ff"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;br /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/font&gt; &lt;font color="#0000ff"&gt;....&lt;br /&gt; }&lt;/font&gt;&lt;/p&gt; &lt;p&gt;propertyCollection being (quite obviously) a Hashtable member that the Web Service could access by using the name of the property (ex: string fakeID = us.propertyCollection["Fake ID"];). That makes sense, right? Except that Hashtable does not implement IXmlSerializable, thus rendering it useless as a member of a class that's supposed to be returned by a web service method call.&lt;/p&gt; &lt;p&gt;Uhm...&lt;/p&gt; &lt;p&gt;After a bit of discussion with my partners in crime, Dominic Pease and Jamie Cansdale, we found a sample SerializableHashtable class on Usenet that implements both Hastable and IXmlSerializable. That looked perfect and it worked, except for the fact that the unserialized member would come out as a DataSet, and not an Hashtable. I'm sure that it would be possible for a better developer than me to modify SerializableHashtable to output a proper type, but in the end I decided to modify the Reference.cs generated file in the Test Harness project by adding&lt;/p&gt; &lt;p&gt;&lt;font color="#0000ff"&gt;using UserSet as NFFTI.UserSet;&lt;/font&gt;&lt;/p&gt; &lt;p&gt;at the beginning and commenting out the UserSet proxy class in this file. Contrary to popular (and my) belief, it worked fine and now I can access properties by name. The main drawback of this fix is that I have to reference the Business Object project from the Test Harness in order to know about the UserSet class. I'll gladly accept suggestions on how to avoid having to rely on this kludge :)&lt;/p&gt;&lt;div&gt;&lt;p&gt;[Now Playing: Depeche Mode - Wild Boys]&lt;/p&gt;&lt;/div&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=61232" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/pmarcucci/archive/tags/.NET+Development/default.aspx">.NET Development</category><category domain="http://weblogs.asp.net/pmarcucci/archive/tags/NFFTI/default.aspx">NFFTI</category></item><item><title>NFFTI architecture and experiments</title><link>http://weblogs.asp.net/pmarcucci/archive/2004/01/21/61208.aspx</link><pubDate>Thu, 22 Jan 2004 00:24:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:61208</guid><dc:creator>Pmarcucci</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/pmarcucci/rsscomments.aspx?PostID=61208</wfw:commentRss><comments>http://weblogs.asp.net/pmarcucci/archive/2004/01/21/61208.aspx#comments</comments><description>&lt;P&gt;The NFFTI administration engine is composed by a set of web services that will be accessed by a web interface and a rich client application. To start experimenting with the overall architecture, I generated a series of Data Access classes (using &lt;A href="http://www.ericjsmith.net/codesmith/"&gt;CodeSmith &lt;/A&gt;with my OleDbDALC templates, not yet released) for some tables, namely Users, Groups, UserGroups (cross reference), PropertyTypes and UserProperties (another cross reference table). Once these were generated, I put them in a &lt;STRONG&gt;Data Access Layer&lt;/STRONG&gt; project along with a Global class that will deal with the connection strings.&lt;/P&gt;
&lt;P&gt;After verifying that all these classes were working fine, I created a &lt;STRONG&gt;Business Objects&lt;/STRONG&gt; project where I dropped a UserSet class. This class will manage in a single entity user data, properties and the groups to which the user belongs.&lt;/P&gt;
&lt;P&gt;These two projects are simply class libraries. To interface them to the outside world I had to create &lt;EM&gt;another&lt;/EM&gt; project (&lt;STRONG&gt;Nfftiws&lt;/STRONG&gt;). This is a ASP.NET Web Service project that, for the moment, implements a UserManager class that deals with login, logout and retrieving information about a user.&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Test Harness&lt;/STRONG&gt; is a Winforms project that will let me test Nfftiws' implementation.&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=61208" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/pmarcucci/archive/tags/.NET+Development/default.aspx">.NET Development</category><category domain="http://weblogs.asp.net/pmarcucci/archive/tags/NFFTI/default.aspx">NFFTI</category></item><item><title>And just to finish the day...</title><link>http://weblogs.asp.net/pmarcucci/archive/2004/01/16/59276.aspx</link><pubDate>Fri, 16 Jan 2004 11:34:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:59276</guid><dc:creator>Pmarcucci</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/pmarcucci/rsscomments.aspx?PostID=59276</wfw:commentRss><comments>http://weblogs.asp.net/pmarcucci/archive/2004/01/16/59276.aspx#comments</comments><description>The mandatory (temporary) logo: 
&lt;P&gt;&lt;IMG src="http://www.paolomarcucci.com/projects/nffti/logo.gif"&gt;&lt;/P&gt;
&lt;DIV&gt;
&lt;P&gt;[Now Playing: Jamiroquai - Emergency On Planet Earth]&lt;/P&gt;&lt;/DIV&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=59276" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/pmarcucci/archive/tags/NFFTI/default.aspx">NFFTI</category></item><item><title>NFFTI</title><link>http://weblogs.asp.net/pmarcucci/archive/2004/01/16/59275.aspx</link><pubDate>Fri, 16 Jan 2004 11:08:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:59275</guid><dc:creator>Pmarcucci</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/pmarcucci/rsscomments.aspx?PostID=59275</wfw:commentRss><comments>http://weblogs.asp.net/pmarcucci/archive/2004/01/16/59275.aspx#comments</comments><description>&lt;p&gt;By the way, the engine upon which the two websites will be built is going to be called NFFTI. Yes, it's an acronym. No, you are not allowed to know what it means, yet :)&lt;/p&gt;&lt;div&gt;&lt;p&gt;[Now Playing: Duran Duran - Hungry Like a Wolf]&lt;/p&gt;&lt;/div&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=59275" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/pmarcucci/archive/tags/NFFTI/default.aspx">NFFTI</category></item><item><title>New year, new impossible project</title><link>http://weblogs.asp.net/pmarcucci/archive/2004/01/15/59271.aspx</link><pubDate>Fri, 16 Jan 2004 04:53:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:59271</guid><dc:creator>Pmarcucci</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/pmarcucci/rsscomments.aspx?PostID=59271</wfw:commentRss><comments>http://weblogs.asp.net/pmarcucci/archive/2004/01/15/59271.aspx#comments</comments><description>&lt;P&gt;As usual, new year resolutions include -in some way or another- the nebulous objective of making more money. With the objective firm in my mind, I had to start thinking about a way to achieve it. I wouldn't mind getting rid of a chunk of my house mortgage and that requires some serious work to be done. &lt;/P&gt;
&lt;P&gt;After a couple of seconds of consideration, I selected a couple of web projects I had completed three or four years ago and that were in dire need of some technological updates. I contacted the client about it and he sounded quite happy with my proposal, but nothing is yet decided, so I'm in the enviable position to start thinking about the solution without having too much pressure. &lt;/P&gt;
&lt;P&gt;Neat, eh? &lt;/P&gt;
&lt;P&gt;Anyways, the websites are marketing/community tools for a company that deals with the entertainment industry. They have to be able to post articles, stories and news, control the submission workflow, provide downloadables and discussion forums, event calendars, RSS feeds. They have to be able to move the sites easily between hosting companies (so, not too many dependencies on the underlying platforms, albeit I'm putting my foot down at mandating .NET). &lt;/P&gt;
&lt;P&gt;In the following posts I'm going to detail my design process and hope someone will chime in with helpful suggestions. See ya.&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=59271" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/pmarcucci/archive/tags/NFFTI/default.aspx">NFFTI</category></item></channel></rss>