Re: [python-win32] runas analog

2019-03-18 Thread Vernon D. Cole
Perhaps ShellExecuteEx will do what you are wishing for? I found a good formula for starting a process as an administrator and it is packaged in a small module tries to emulate a "sudo" command. You might look at the

[python-win32] runas analog

2019-03-18 Thread Kuree Kafir
Hello, I am trying to implement something similar to the runas /netonly command in python. handle = win32security.LogonUser(userName, domain, password, win32con.LOGON32_LOGON_NEW_CREDENTIALS, win32con.LOGON32_PROVIDER_DEFAULT) win32security.ImpersonateLoggedOnUser(handle) These two commands