Re: Auth Problem

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance

From: Nikolay Petrov (johntup2_at_mail.bg)
Date: 10/19/04


Date: Tue, 19 Oct 2004 11:28:37 +0300

Also with "Basic" Authentication everything works fine

"Nikolay Petrov" <johntup2@mail.bg> wrote in message
news:%23wNCq4atEHA.3460@TK2MSFTNGP15.phx.gbl...
>I have the following web method:
>
> <WebMethod()> _
> Public Function Test_CurrentCredentials() As String()
> Dim tmpArr(2) As String
> tmpArr(0) = "User: " &
> System.Threading.Thread.CurrentPrincipal.Identity.Name
> tmpArr(1) =
> System.Threading.Thread.CurrentPrincipal.Identity.AuthenticationType.ToString
> tmpArr(2) =
> System.Threading.Thread.CurrentPrincipal.Identity.IsAuthenticated.ToString
> Return tmpArr
> End Function
>
> In my app I call it this way:
> Dim tmpArr() as string
> Dim svc As New WebReference.Service1
> svc.Credentials = System.Net.CredentialCache.DefaultCredentials
> tmpArr = svc.Test_CurrentCredentials
>
> The app is Windows Forms app.
>
> When I run the app I get the following error:
> The request failed with HTTP status 401: Access Denied
>
>
> I have Disabled Anonymous authentication for my Web Service folder. Only
> Integrated Windiows Authentication is active.
> In my Web Service web.config file I have thi line:
> <authentication mode="Windows" />
> When Anonymous is Enabled I can connect to service.
>
> I have auditing turned on and doesn't show nothing.
> What is the problem?
>
> Tia
>



Relevant Pages

  • Re: ADSI Problem
    ... built in mechanisms to support forms-based authentication are the way to go. ... In a .NET web app, you generally discover the identity of the authenticated ... Unfortunately, script and ASP 3.0 are not my things, so I'm not the expert ... Dim strUserName ...
    (microsoft.public.windows.server.active_directory)
  • Re: Auth Problem
    ... > Dim tmpArrAs String ... > Dim tmpArr() as string ... > The app is Windows Forms app. ... > I have Disabled Anonymous authentication for my Web Service folder. ...
    (microsoft.public.dotnet.framework.webservices)
  • Re: Auth Problem
    ... > Dim tmpArrAs String ... > Dim tmpArr() as string ... > The app is Windows Forms app. ... > I have Disabled Anonymous authentication for my Web Service folder. ...
    (microsoft.public.dotnet.languages.vb)
  • Re: Auth Problem
    ... > Dim tmpArrAs String ... > Dim tmpArr() as string ... > The app is Windows Forms app. ... > I have Disabled Anonymous authentication for my Web Service folder. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Auth Problem
    ... > Dim tmpArrAs String ... > Dim tmpArr() as string ... > The app is Windows Forms app. ... > I have Disabled Anonymous authentication for my Web Service folder. ...
    (microsoft.public.dotnet.framework.aspnet.security)