From: Steve Dower Date: Wed, 4 Sep 2024 16:02:48 +0000 (+0100) Subject: [3.11] gh-119690: Fixes buffer type confusion in _winapi.CreateNamedPipe audit event... X-Git-Tag: v3.11.10~7 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=697beec04dbbd03508e02df9f0042ce5a8772b46;p=thirdparty%2FPython%2Fcpython.git [3.11] gh-119690: Fixes buffer type confusion in _winapi.CreateNamedPipe audit event (#119734) gh-119690: Fixes buffer type confusion in _winapi.CreateNamedPipe audit event --- diff --git a/Misc/NEWS.d/next/Windows/2024-05-29-17-00-27.gh-issue-119690.tv6Zgs.rst b/Misc/NEWS.d/next/Windows/2024-05-29-17-00-27.gh-issue-119690.tv6Zgs.rst new file mode 100644 index 000000000000..45e644c652b6 --- /dev/null +++ b/Misc/NEWS.d/next/Windows/2024-05-29-17-00-27.gh-issue-119690.tv6Zgs.rst @@ -0,0 +1,2 @@ +Fixes data type confusion in audit event raised by +``_winapi.CreateNamedPipe``. diff --git a/Modules/_winapi.c b/Modules/_winapi.c index 54eee9e8c3f1..0376cc0a26f8 100644 --- a/Modules/_winapi.c +++ b/Modules/_winapi.c @@ -708,7 +708,7 @@ _winapi_CreateNamedPipe_impl(PyObject *module, LPCTSTR name, DWORD open_mode, { HANDLE handle; - if (PySys_Audit("_winapi.CreateNamedPipe", "uII", + if (PySys_Audit("_winapi.CreateNamedPipe", "sII", name, open_mode, pipe_mode) < 0) { return INVALID_HANDLE_VALUE; }