* spawn.cc (span_guts): Retrieve security attributes before setting
psid to NULL.
This commit is contained in:
parent
4c02a6ab9c
commit
ede1fee4ca
|
@ -1,3 +1,8 @@
|
||||||
|
Fri Jul 21 21:33:00 2000 Corinna Vinschen <corinna@vinschen.de>
|
||||||
|
|
||||||
|
* spawn.cc (span_guts): Retrieve security attributes before setting
|
||||||
|
psid to NULL.
|
||||||
|
|
||||||
Fri Jul 21 12:03:00 2000 Corinna Vinschen <corinna@vinschen.de>
|
Fri Jul 21 12:03:00 2000 Corinna Vinschen <corinna@vinschen.de>
|
||||||
|
|
||||||
* security.cc (acl_worker): Use stat_suffixes in call to path_conv
|
* security.cc (acl_worker): Use stat_suffixes in call to path_conv
|
||||||
|
|
|
@ -536,6 +536,12 @@ skip_arg_parsing:
|
||||||
else
|
else
|
||||||
system_printf ("GetTokenInformation: %E");
|
system_printf ("GetTokenInformation: %E");
|
||||||
|
|
||||||
|
/* Retrieve security attributes before setting psid to NULL
|
||||||
|
since it's value is needed by `sec_user'. */
|
||||||
|
PSECURITY_ATTRIBUTES sec_attribs = allow_ntsec && sid
|
||||||
|
? sec_user (sa_buf, sid)
|
||||||
|
: &sec_all_nih;
|
||||||
|
|
||||||
/* Remove impersonation */
|
/* Remove impersonation */
|
||||||
uid_t uid = geteuid();
|
uid_t uid = geteuid();
|
||||||
if (myself->impersonated && myself->token != INVALID_HANDLE_VALUE)
|
if (myself->impersonated && myself->token != INVALID_HANDLE_VALUE)
|
||||||
|
@ -553,12 +559,8 @@ skip_arg_parsing:
|
||||||
rc = CreateProcessAsUser (hToken,
|
rc = CreateProcessAsUser (hToken,
|
||||||
real_path, /* image name - with full path */
|
real_path, /* image name - with full path */
|
||||||
one_line.buf, /* what was passed to exec */
|
one_line.buf, /* what was passed to exec */
|
||||||
/* process security attrs */
|
sec_attribs, /* process security attrs */
|
||||||
allow_ntsec && sid ? sec_user (sa_buf, sid)
|
sec_attribs, /* thread security attrs */
|
||||||
: &sec_all_nih,
|
|
||||||
/* thread security attrs */
|
|
||||||
allow_ntsec && sid ? sec_user (sa_buf, sid)
|
|
||||||
: &sec_all_nih,
|
|
||||||
TRUE, /* inherit handles from parent */
|
TRUE, /* inherit handles from parent */
|
||||||
flags,
|
flags,
|
||||||
envblock,/* environment */
|
envblock,/* environment */
|
||||||
|
|
Loading…
Reference in New Issue