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 / General / March 2008

Tip: Looking for answers? Try searching our database.

web service 401 unauthorized

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
kishan.bisht@gmail.com - 19 Mar 2008 03:27 GMT
I am using Avanade ACA web services which I guess uses .net web
services under the wraps. My requirement is use windows authentication
and allow user identity to pass thru to the web service and then to a
database.

I have two websites in the same box - one is the UI and other is the
webservices. It works when I have anonymous clicked on in the
webservices but it does not work when I switch this off and windows
authentication on. It throws the exception - system.net.webexception
401 Unathorrized.

I have tried using
<system.net>
<defaultProxy useDefaultCredentials="true">
<system.net>

in the web services but with no success. I have also given all
permissions to the Network Service (default app pool identity) for the
file system for the web site.

Now this looks like a common problem with .net web services and I am
not sure what else I can try.

Anyone done this before or have some idea?

Thanks in advance

Kishan
Peter Bromberg [C# MVP] - 19 Mar 2008 14:46 GMT
a Webservice method call simply transmits a SOAP envelope; no windows
credentials are included. So using Windows authentication in the IIS without
some sort of mechanism to transmit credentials as one would get with a normal
browser request that knows how to reply to the www-authenticate challenge is
not going to work.
-- Peter
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
Short Urls & more: http://ittyurl.net

> I am using Avanade ACA web services which I guess uses .net web
> services under the wraps. My requirement is use windows authentication
[quoted text clipped - 24 lines]
>
> Kishan
kishan.bisht@gmail.com - 20 Mar 2008 01:32 GMT
> a Webservice method call simply transmits a SOAP envelope; no windows
> credentials are included. So using Windows authentication in the IIS without
[quoted text clipped - 37 lines]
>
> - Show quoted text -

Thanks Peter.

So that means if I need to invoke web services programmatically from
the asp.net I will have to explicitly set user credentials on the SOAP
header.

Is there something built into the framework to do that?

Kishan

Rate this thread:







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.