Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / Web Services / March 2006

Tip: Looking for answers? Try searching our database.

WSE-Security with Windows Service hosted web service

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Matt C - 14 Mar 2006 20:40 GMT
I have WSE3 working well in the samples and in a test project I enabled for
WSE3. But these all used IIS to host the web service.

I am trying to apply a "ServicePolicy" I defined in the WSE3 property pages
and I have some questions:

1) When a web service is hosted in a Windows service, do I apply the policy
to the web service or the windows service or both?

2) I cannot get the web service-side to require security as defined in the
policy.

When I turn off client-side security by not calling the SetPolicy API, all
web method calls succeed, but I expect some SOAP exceptions due to
service-side security requirements (like when the web service is hosted in
IIS and I disable policy for the web service but not for the client project)
but I don't get those.

My current test project is based on the help sample topic "How to: Host an
ASP.NET Web Service Outside of IIS", but it doesn't implement any security.
Matt C - 14 Mar 2006 20:58 GMT
Ok, solved my own problem.

Two things:
1) Use the Policy attribute on the class to specify the security policy to
use.
2) Make sure the app.config (former web.config file) and the wse3 config
file are in the directory with the windows service binary.

I now have the equivalent functionality I had when hosting the web service
vis IIS.

> I have WSE3 working well in the samples and in a test project I enabled for
> WSE3. But these all used IIS to host the web service.
[quoted text clipped - 16 lines]
> My current test project is based on the help sample topic "How to: Host an
> ASP.NET Web Service Outside of IIS", but it doesn't implement any security.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.