CYGWIN_SET_IMPERSONATION_TOKEN(3)

NAME
cygwin_set_impersonation_token

SYNOPSIS

#include <sys/cygwin.h>

void cygwin_set_impersonation_token(const HANDLE token);

DESCRIPTION

Use this function to enable the token given as parameter as impersonation token for the next call to setuid or seteuid. Use cygwin_set_impersonation_token together with cygwin_logon_user to impersonate users using password authentication.

SEE ALSO

See also the chapter Switching the user context[1] in the Cygwin User's guide.

See also cygwin_logon_user

COPYRIGHT

Copyright © Cygwin authors

Permission is granted to make and distribute verbatim copies of this documentation provided the copyright notice and this permission notice are preserved on all copies.

Permission is granted to copy and distribute modified versions of this documentation under the conditions for verbatim copying, provided that the entire resulting derived work is distributed under the terms of a permission notice identical to this one.

Permission is granted to copy and distribute translations of this documentation into another language, under the above conditions for modified versions, except that this permission notice may be stated in a translation approved by the Free Software Foundation.

NOTES

1.  Switching the user context
    https://cygwin.com/cygwin-ug-net/../cygwin-ug-net/ntsec.html#ntsec-setuid-overview