MySQL 8.4.3
Source Code Documentation
named_pipe.h
Go to the documentation of this file.
1/* Copyright (c) 2012, 2024, Oracle and/or its affiliates.
2
3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the GNU General Public License, version 2.0,
5 as published by the Free Software Foundation.
6
7 This program is designed to work with certain software (including
8 but not limited to OpenSSL) that is licensed under separate terms,
9 as designated in a particular file or component or in included license
10 documentation. The authors of MySQL hereby grant you an additional
11 permission to link the program and your derivative works with the
12 separately licensed software that they have either included with
13 the program or referenced in the documentation.
14
15 This program is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 GNU General Public License, version 2.0, for more details.
19
20 You should have received a copy of the GNU General Public License
21 along with this program; if not, write to the Free Software
22 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
23
24#ifndef NAMED_PIPE_INCLUDED
25#define NAMED_PIPE_INCLUDED
26
27#include <windows.h>
28
29const DWORD NAMED_PIPE_OWNER_PERMISSIONS = GENERIC_READ | GENERIC_WRITE;
31 FILE_READ_ATTRIBUTES | FILE_READ_DATA | FILE_WRITE_ATTRIBUTES |
32 FILE_WRITE_DATA | SYNCHRONIZE | READ_CONTROL;
34 GENERIC_READ | GENERIC_WRITE;
35
36HANDLE create_server_named_pipe(SECURITY_ATTRIBUTES **ppsec_attr,
37 DWORD buffer_size, const char *name,
38 char *name_buf, size_t buflen,
39 const char *full_access_group_name = nullptr);
40
41bool is_valid_named_pipe_full_access_group(const char *group_name);
42bool my_security_attr_add_rights_to_group(SECURITY_ATTRIBUTES *psa,
43 const char *group_name,
44 DWORD group_rights);
45#define DEFAULT_NAMED_PIPE_FULL_ACCESS_GROUP ""
46#define NAMED_PIPE_FULL_ACCESS_GROUP_EVERYONE "*everyone*"
47#endif /* NAMED_PIPE_INCLUDED */
const DWORD NAMED_PIPE_FULL_ACCESS_GROUP_PERMISSIONS
Definition: named_pipe.h:33
HANDLE create_server_named_pipe(SECURITY_ATTRIBUTES **ppsec_attr, DWORD buffer_size, const char *name, char *name_buf, size_t buflen, const char *full_access_group_name=nullptr)
Creates an instance of a named pipe and returns a handle.
Definition: named_pipe.cc:284
bool is_valid_named_pipe_full_access_group(const char *group_name)
Definition: named_pipe.cc:111
const DWORD NAMED_PIPE_OWNER_PERMISSIONS
Definition: named_pipe.h:29
const DWORD NAMED_PIPE_EVERYONE_PERMISSIONS
Definition: named_pipe.h:30
bool my_security_attr_add_rights_to_group(SECURITY_ATTRIBUTES *psa, const char *group_name, DWORD group_rights)
Definition: named_pipe.cc:129
size_t buffer_size(const ConstBufferSequence &buffers) noexcept
Definition: buffer.h:313
case opt name
Definition: sslopt-case.h:29
#define HANDLE
Definition: violite.h:159