Login | Register   
LinkedIn
Google+
Twitter
RSS Feed
Download our iPhone app
TODAY'S HEADLINES  |   ARTICLE ARCHIVE  |   FORUMS  |   TIP BANK
Browse DevX
Sign up for e-mail newsletters from DevX


advertisement
 

Windows Communication Foundation: The Security Model : Page 2

Securing communications has never been easier. See how to set up the Windows Communication Foundation (WCF) on your system, and use configuration-based security to add or change the security requirements for your applications.


advertisement
Installing WCF
I have found that the best way to get up and running with WCF is to create a development system using one of the following procedures, depending on whether you have the DVD's from Microsoft's Professional Developer's Conference (PDC).

Setup Using PDC DVDs
Follow this procedure only if you're installing from the PDC DVDs.

  1. You need Windows XP SP2 or Windows Vista 5219 (Do not use Windows Vista Beta1!) Start with Disc 4 - WinFx CTP installation. This installs the WinFX runtime including WPF, WCF, and .NET Framework 2.0
  2. Move to Disc 2 - Visual Studio (Beta 2!!!). Note that there is an error with the set up—so you should copy the folder to your HD. You should also install the MSDN help, but you can install that directly from the disc.
  3. Move to Disc 5 (confused yet? You should be). This disc contains the Windows WinFX SDK in the windows SDK folder, and it installs the WinFX SDK but not the samples. It does copy the samples though, which you'll find in a .zip file called AllSamples.zip. You'll see more about this later.
  4. Now, go back to Disc 4 and install the VS Extensions for WinFx. This installs Project Templates and Item Templates for Visual Studio.
Setup Without PDC DVDs
Follow this procedure only if you're not installing from the PDC DVDs.

  1. You need Windows XP SP2 or Windows Vista 5219 (Do not use Windows Vista Beta1!)
  2. Start by downloading the WinFx CTP installation, which installs the WinFX runtime including WPF, WCF, and .NET Framework 2.0
  3. Next, get Visual Studio (Beta 2) or Visual Basic Express (Beta 2), or VC# Express (Beta 2). It supposedly doesn't matter which you use, just make sure you're using a Beta 2 version. I recommend Visual Studio, as that is what I used, and I cannot vouch for the others.
  4. Next, you need to install the Windows WinFX SDK, which installs the WinFX SDK itself, but not the samples. It does copy the samples though, which you'll find in a .zip file called AllSamples.zip. You'll see more about this later.
  5. Finally, install the VS Extensions for WinFx, which installs the Project Templates and Item Templates for Visual Studio.
After you've followed the appropriate procedure above you should be good to go in building and running WCF services. There's just one more thing that you may encounter—sometimes ASP.NET doesn't recognize WCF correctly, and your services won't run. If this happens, you should remove XWS, remove ASPNET, and then reinstall IIS, add ASPNET, and add XWS, in that sequence. So, first issue the following commands from a DOS prompt to remove XWS and ASPNET

XWS_REG --ua ASPNET_REGIIS --ua

Then reinstall IIS from the Add/Remove programs control panel (remove it, then install it again), and issue these commands from a DOS prompt to add ASPNET and XWS:

ASPNET_REGIIS --i XWS_REG --r --v

Finally, if you get an authentication error when trying to debug your WCF applications from Visual Studio.NET, you'll need to configure them for Integrated Windows Authentication. To do this, open the IIS manager, find the virtual directory corresponding to the service, right click it, and select Properties. In the ensuing dialog, select the directory security tab, and click the Edit button in the 'Anonymous access and authentication control' frame. In the next dialog, select 'Integrated Windows Authentication' at the bottom, click OK to close, and click OK again to close the previous dialog. You should now be good to go.



Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

Sitemap