Announcement

Collapse
No announcement yet.

Trying to get current logged in "Active Directory" User

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Trying to get current logged in "Active Directory" User

    Hi,

    Ive been googling without much joy, Im trying to get the authenticated username whom has logged into the network via a VPN connection. If I use the query the current user it returns the local current user rather than the AD account which is authenticated via the VPN.

    Can anyone help me please?

    Thanks

  • #2
    Re: Trying to get current logged in "Active Directory" User

    Can you give us more info, ie what the VPN concentrator is and how is that configured to authenticate with AD (ie LDAP or Radius).

    Thanks
    Caesar's cipher - 3

    ZKHQ BRX HYHQWXDOOB GHFLSKHU WKLV BRX ZLOO UHDOLVH LW ZDV D ZDVWH RI WLPH!

    SFX JNRS FC U6 MNGR

    Comment


    • #3
      Re: Trying to get current logged in "Active Directory" User

      The authentication is using ldap\active directory with the client just an automatic vpn connection from within Windows 7.

      From some of the examples I have tested, it only returns the windows username (local) not the AD account which is authenticated onto the VPN network. The reason Im trying to do this is to get access from a shared resource (laptop) to which multiple people will be using to VPN and so static scripts wont work as they need to map a different home drive location.

      Comment


      • #4
        Re: Trying to get current logged in "Active Directory" User

        just a question, why are they using local accounts on their systems?
        Marcel
        Technical Consultant
        Netherlands
        http://www.phetios.com
        http://blog.nessus.nl

        MCITP(EA, SA), MCSA/E 2003:Security, CCNA, SNAF, DCUCI, CCSA/E/E+ (R60), VCP4/5, NCDA, NCIE - SAN, NCIE - BR, EMCPE
        "No matter how secure, there is always the human factor."

        "Enjoy life today, tomorrow may never come."
        "If you're going through hell, keep going. ~Winston Churchill"

        Comment


        • #5
          Re: Trying to get current logged in "Active Directory" User

          Originally posted by Dumber View Post
          just a question, why are they using local accounts on their systems?
          Because they are using the laptops whilst out in the field and not necessarily connected to the internet\vpn all the time. Im not a fan of offline files, it can get messy. Appreciate that the user could save a file on the laptop and then lose the laptop but personaly I think this risk is less so than the troubles Ive experienced with offline file sync.

          Comment


          • #6
            Re: Trying to get current logged in "Active Directory" User

            so your script gives you the name of the LOCAL user logged on to the laptop, but not the name of the user logged on to the VPN, correct ?

            here's an option to consider...
            have your script grab the provided VPN ip address
            then query the RRAS server, and find out which domain account is logged in against that IP address.. ??
            Please do show your appreciation to those who assist you by leaving Rep Point https://www.petri.com/forums/core/im.../icon_beer.gif

            Comment

            Working...
            X