Remote logon
-
hi want to hear your opinion about the next: how to logon remotely to the lan computer i use following code: HANDLE hToken = 0; BOOL bRet = LogonUser("user", "domain", "password", LOGON32_LOGON_INTERACTIVE, LOGON32_PROVIDER_DEFAULT, &hToken); the function return 0. hToken is set to NULL. and the getlasterror return 'logon failure: unknown user name or password.' i check all parameters for conveniency twicely. in MSDN writes that "You cannot use LogonUser to log on to a remote computer". i think this statement include the answer. then my qeustion is: how to logon user on a remote machine? any ideas? 4apai There're no impossible tasks. There're tasks that required infinite period of time.
-
hi want to hear your opinion about the next: how to logon remotely to the lan computer i use following code: HANDLE hToken = 0; BOOL bRet = LogonUser("user", "domain", "password", LOGON32_LOGON_INTERACTIVE, LOGON32_PROVIDER_DEFAULT, &hToken); the function return 0. hToken is set to NULL. and the getlasterror return 'logon failure: unknown user name or password.' i check all parameters for conveniency twicely. in MSDN writes that "You cannot use LogonUser to log on to a remote computer". i think this statement include the answer. then my qeustion is: how to logon user on a remote machine? any ideas? 4apai There're no impossible tasks. There're tasks that required infinite period of time.
ok. i'll redescribe u what i exactly need. i've a local station station1. (i've here an administartor account name1) and had a remote station station2. (i've here an administartor account name2) i logon to station1 with name1 then i need to perform some functionality on station1, which require context of administartor account on station2. so i need to log on name2 account on station2 and then using f.e. createprocessasuser with retrieved user token run process which will perform that functionality. a simple sollution is to add name1.dns_name to administartors group on station2. then i dont need any additional tasks to perform. all functionate perfect. but the problem is, that it is not allowed due to restrictions or project. if i dont explain quite clear or u've any ideas then post me. 4apai There're no impossible tasks. There're tasks that required infinite period of execution time.