How does authentication and logon work on Windows with Kerberos? What I want to achieve is to logon a user on a server and run a process for that user.
As a first step, I create a Kerberos ticket on the client and send it to the server. On the server, I do not know the API to logon the user given its ticket. Of course I can accept the security context using AcceptSecurityContext (SSPI), but that does not initiate a logon.
I think that some SSH implementations for Windows do exactly that. But I want to know how and what API they probably use?
CreateProcessAsUser
, a new process is started running as user. However, it cannot communicate with other services on different servers (e.g. a REST API). It is not possible to create new tickets for other services (usingAquireCredentialsHandle
andInitializeSecurityContext
), I get an error: "No credentials are available in the security package". I can create new tickets (delegation) in the service afterImpersonateSecurityContext
and before I create a new process. But that is not what I want. Is it possible to do it in the new process? – Canaliculus