HADOOP-11228. Winutils task: unsecure path should not call AddNodeManagerAndUserACEsToObject. Contributed by Remus Rusanu
This commit is contained in:
parent
86ac0d40b8
commit
f7e89bb349
|
@ -339,6 +339,9 @@ Trunk (Unreleased)
|
||||||
HADOOP-11022. User replaced functions get lost 2-3 levels deep (e.g.,
|
HADOOP-11022. User replaced functions get lost 2-3 levels deep (e.g.,
|
||||||
sbin) (aw)
|
sbin) (aw)
|
||||||
|
|
||||||
|
HADOOP-11228. Winutils task: unsecure path should not call
|
||||||
|
AddNodeManagerAndUserACEsToObject. (Remus Rusanu via jianhe)
|
||||||
|
|
||||||
OPTIMIZATIONS
|
OPTIMIZATIONS
|
||||||
|
|
||||||
HADOOP-7761. Improve the performance of raw comparisons. (todd)
|
HADOOP-7761. Improve the performance of raw comparisons. (todd)
|
||||||
|
|
|
@ -627,11 +627,13 @@ DWORD CreateTaskImpl(__in_opt HANDLE logonHandle, __in PCWSTR jobObjName,__in PC
|
||||||
return dwErrorCode;
|
return dwErrorCode;
|
||||||
}
|
}
|
||||||
|
|
||||||
dwErrorCode = AddNodeManagerAndUserACEsToObject(jobObject, userName, JOB_OBJECT_ALL_ACCESS);
|
if (logonHandle != NULL) {
|
||||||
if (dwErrorCode) {
|
dwErrorCode = AddNodeManagerAndUserACEsToObject(jobObject, userName, JOB_OBJECT_ALL_ACCESS);
|
||||||
ReportErrorCode(L"AddNodeManagerAndUserACEsToObject", dwErrorCode);
|
if (dwErrorCode) {
|
||||||
CloseHandle(jobObject);
|
ReportErrorCode(L"AddNodeManagerAndUserACEsToObject", dwErrorCode);
|
||||||
return dwErrorCode;
|
CloseHandle(jobObject);
|
||||||
|
return dwErrorCode;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(AssignProcessToJobObject(jobObject, GetCurrentProcess()) == 0)
|
if(AssignProcessToJobObject(jobObject, GetCurrentProcess()) == 0)
|
||||||
|
@ -706,6 +708,8 @@ DWORD CreateTaskImpl(__in_opt HANDLE logonHandle, __in PCWSTR jobObjName,__in PC
|
||||||
dwErrorCode = GetLastError();
|
dwErrorCode = GetLastError();
|
||||||
ReportErrorCode(L"CreateProcess", dwErrorCode);
|
ReportErrorCode(L"CreateProcess", dwErrorCode);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// task create (w/o createAsUser) does not need the ACEs change on the process
|
||||||
goto create_process_done;
|
goto create_process_done;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue