Home All Groups Group Topic Archive Search About

How to get Windows user name of a 3rd party application in dotnet?

Author
9 Oct 2008 12:18 PM
Vincent Anand
We have 3rd parthy windows application running, which uses windows
username/password  to authenticate through LDAP. This application is not a
..net application. We don't have any interface/ method to get access for this
application.

The Windows OS logon user name and this application logon windows user name
could be different.

This application calls a custom COM dll created in dotnet framework2.0. The
COM has to identify the user, who logged into that application. How to get
this user name in the COM object?

Author
9 Oct 2008 2:14 PM
Joe Kaplan
If the application is authenticating via an LDAP bind, there is no local
Windows logon token for that user that could be impersonated and then picked
up automatically via normal Windows security mechanisms.  As such, the only
way I can think of would be for your COM interface to support a member that
allows callers to "tell" you this info.  That would of course require
changes to both the component and the calling application.

--
Joe Kaplan-MS MVP Directory Services Programming
Co-author of "The .NET Developer's Guide to Directory Services Programming"
http://www.directoryprogramming.net
--
Show quoteHide quote
"Vincent Anand" <Vincent An***@discussions.microsoft.com> wrote in message
news:A59EE6EB-99A2-4A34-B80A-E41D6BBD8062@microsoft.com...
> We have 3rd parthy windows application running, which uses windows
> username/password  to authenticate through LDAP. This application is not a
> .net application. We don't have any interface/ method to get access for
> this
> application.
>
> The Windows OS logon user name and this application logon windows user
> name
> could be different.
>
> This application calls a custom COM dll created in dotnet framework2.0.
> The
> COM has to identify the user, who logged into that application. How to get
> this user name in the COM object?
>
>
>
>
>