Can't get logonuser

Discussion in 'ASP .Net Security' started by Little Little, Aug 6, 2003.

  1. I would like to get user logon from server by
    USERLog = Request.ServerVariables("LOGON_USER")
    but it isn't see. i don't know what the problem and how i can
    solve in this. But i try to get other value can see it.

    *** Sent via Developersdex http://www.developersdex.com ***
    Don't just participate in USENET...get rewarded for it!
     
    Little Little, Aug 6, 2003
    #1
    1. Advertising

  2. For this to work.. you need to use Windows Authentication or Basic
    authentication and turn off anonymous acess in IIS.

    --
    Naveen K Kohli
    http://www.netomatix.com
    "Little Little" <> wrote in message
    news:...
    >
    >
    > I would like to get user logon from server by
    > USERLog = Request.ServerVariables("LOGON_USER")
    > but it isn't see. i don't know what the problem and how i can
    > solve in this. But i try to get other value can see it.
    >
    > *** Sent via Developersdex http://www.developersdex.com ***
    > Don't just participate in USENET...get rewarded for it!
     
    Naveen K Kohli, Aug 6, 2003
    #2
    1. Advertising

  3. Little Little

    Dave Clark Guest

    After looking again, I think the WindowsIdentity gets the
    <domain>\<username> instead of what I say below.


    >-----Original Message-----
    >I'm pretty new at ASP.Net, but even when I had Anonymous
    >off and Integrated Windows Authentication on,
    >ServerVariables("LOGON_USER") is still empty. Here's

    what
    >I did to get the logged on user.
    >
    >Dim thisUser As System.Security.Principal.WindowsIdentity
    >
    >Dim UserLog As String
    >
    >UserLog = thisUser.GetCurrent.Name.ToString
    >
    >UserLog will contain the <machineName>/<logged on user>,
    >such as ntsrvr1/ASPNET, if you're running in debug.

    Parse
    >out "ASPNET" for the logged on user.
    >
    >
    >>-----Original Message-----
    >>
    >>
    >>I would like to get user logon from server by
    >> USERLog = Request.ServerVariables("LOGON_USER")
    >>but it isn't see. i don't know what the problem

    and
    >how i can
    >>solve in this. But i try to get other value can see

    it.
    >>
    >>*** Sent via Developersdex http://www.developersdex.com

    >***
    >>Don't just participate in USENET...get rewarded for it!
    >>.
    >>

    >.
    >
     
    Dave Clark, Aug 13, 2003
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Mary Chipman

    Re: Impersonation in ASPNET and LogonUser

    Mary Chipman, Sep 3, 2003, in forum: ASP .Net
    Replies:
    0
    Views:
    461
    Mary Chipman
    Sep 3, 2003
  2. Jason

    impersonating and LogonUser

    Jason, Dec 30, 2003, in forum: ASP .Net
    Replies:
    7
    Views:
    450
    Jim Cheshire [MSFT]
    Jan 5, 2004
  3. Nimi

    LogonUser failed error

    Nimi, Oct 14, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    2,412
    Martin Dechev
    Oct 14, 2004
  4. Rich
    Replies:
    1
    Views:
    8,081
    Scott Allen
    Nov 2, 2004
  5. Darrell

    win32security.LogonUser

    Darrell, Jul 8, 2003, in forum: Python
    Replies:
    1
    Views:
    1,344
    John Abel
    Jul 8, 2003
Loading...

Share This Page