|
security
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Imperonate Ignored?I have an app that is impersonating an admin user to register COM dlls.
ALl the code is correct by all examples I have seen. The LogonUser function returns trye and a check to the CurrentUser proves that the user is being impersonated. However, I get all bad exit codes from the Processes running the regsvr32 and regasm. Has anyone else seen this? If I log intot he computer as an admin account the code works fine. Thanks //daja Did you use Process.Start when you were impersonating the admin user? If
so, it is worth knowing that it doesn't use the impersonated token to start the process but instead uses the process identity. If you want to start a process as a different user, you need to call CreateProcessAsUser or CreateProcessWithTokenW. -- Show quoteHide quoteJoe Kaplan-MS MVP Directory Services Programming Co-author of "The .NET Developer's Guide to Directory Services Programming" http://www.directoryprogramming.net "daja" <jautov***@cwsl.edu> wrote in message news:uQmyqDOAKHA.3708@TK2MSFTNGP02.phx.gbl... >I have an app that is impersonating an admin user to register COM dlls. > > ALl the code is correct by all examples I have seen. > > The LogonUser function returns trye and a check to the CurrentUser proves > that the user is being impersonated. > > However, I get all bad exit codes from the Processes running the regsvr32 > and regasm. > > Has anyone else seen this? > > If I log intot he computer as an admin account the code works fine. > > Thanks > //daja >
Running .NET exe from a network share
ComputeSignature: The Keyset is not defined .NET Security Failed to access IIS metabase Empty Event Logs from Windows 2003 Server,Win32_NTLogEvent,WMI Form authentication MD5CryptoServiceProvider tied to machine? Firewall Error Messgae RE: .NET CLR Error 800700002 Ofuscar mi aplicación |
|||||||||||||||||||||||