Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2008-06-10 19:16:01 +0400
committerCorinna Vinschen <corinna@vinschen.de>2008-06-10 19:16:01 +0400
commit93e9098f7c0c7cf16776ebd41e373551e6323726 (patch)
treeec08bba194e567c3466d0fb8446f90971ad0a353 /winsup/cygwin/sec_auth.cc
parentbe5937cd97200dcdb78b1b052d1c862f5e70cdb3 (diff)
* sec_auth.cc (lsaauth): Make returned token inheritable.
Diffstat (limited to 'winsup/cygwin/sec_auth.cc')
-rw-r--r--winsup/cygwin/sec_auth.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/winsup/cygwin/sec_auth.cc b/winsup/cygwin/sec_auth.cc
index 8ae2424c3..dca2e18c8 100644
--- a/winsup/cygwin/sec_auth.cc
+++ b/winsup/cygwin/sec_auth.cc
@@ -1118,6 +1118,11 @@ lsaauth (cygsid &usersid, user_groups &new_groups, struct passwd *pw)
}
}
+ /* The token returned by LsaLogonUser is not inheritable. Make it so. */
+ if (!SetHandleInformation (user_token, HANDLE_FLAG_INHERIT,
+ HANDLE_FLAG_INHERIT))
+ system_printf ("SetHandleInformation %E");
+
out:
if (privs)
free (privs);