Not planned
Description
Our team has identified msys2.0.dll calling undocumented Windows APIs like ntdll.dll!NtAssignProcessToJobObject - which is included in mingit/Git for Windows.
Code pointer in cygwin: https://github.com/search?q=repo%3Acygwin%2Fcygwin+NtAssignProcessToJobObject&type=code with a caller: cygwin/winsup/cygwin/resource.cc at 21a2c9db6952954608cdf92638b411b15e7606c6 · cygwin/cygwin
We believe the undocumented call should get replaced by the following documented API - AssignProcessToJobObject function (jobapi2.h) - Win32 apps | Microsoft Learn
Here are some other undocumented API calls also identified:
- NtOpenJobObject
- NtCreateJobObject
- NtOpenMutant
- NtQueryInformationJobObject
- NtSetInformationJobObject
Could a change be driven to update the above? We will investigate further to try to propose a change. Thanks!
Activity
dscho commentedon Jan 13, 2025
Mail on the Cygwin mailing list: https://inbox.sourceware.org/cygwin/IA3PR21MB42696BB656E25C4E405BDB3E8C1D2@IA3PR21MB4269.namprd21.prod.outlook.com/T/#u
Asask-sized commentedon Jan 23, 2025
dscho commentedon Mar 14, 2025
The discussion on the Cygwin mailing list stalled, mainly because the approach does not work (the handles need to be created in Cygwin's private NT directory and the Win32 API calls do not allow for that). In any case, this needs to be discussed on the Cygwin mailing list if this should go any further.