]> sourceware.org Git - newlib-cygwin.git/blob - winsup/cygwin/include/cygwin/cygserver_transport_pipes.h
* include/cygwin/version.h: Reorganize last two api versions so that btowc and
[newlib-cygwin.git] / winsup / cygwin / include / cygwin / cygserver_transport_pipes.h
1 /* cygserver_transport_pipes.h
2
3 Copyright 2001, 2002 Red Hat Inc.
4
5 Written by Robert Collins <rbtcollins@hotmail.com>
6
7 This file is part of Cygwin.
8
9 This software is a copyrighted work licensed under the terms of the
10 Cygwin license. Please consult the file "CYGWIN_LICENSE" for
11 details. */
12
13 #ifndef _CYGSERVER_TRANSPORT_PIPES_
14 #define _CYGSERVER_TRANSPORT_PIPES_
15
16 /* Named pipes based transport, for security on NT */
17 class transport_layer_pipes : public transport_layer_base
18 {
19 public:
20 #ifndef __INSIDE_CYGWIN__
21 virtual int listen ();
22 virtual class transport_layer_pipes *accept (bool *recoverable);
23 #endif
24
25 virtual void close ();
26 virtual ssize_t read (void *buf, size_t len);
27 virtual ssize_t write (void *buf, size_t len);
28 virtual int connect ();
29
30 #ifndef __INSIDE_CYGWIN__
31 virtual void impersonate_client ();
32 virtual void revert_to_self ();
33 #endif
34
35 transport_layer_pipes ();
36 virtual ~transport_layer_pipes ();
37
38 private:
39 /* for pipe based communications */
40 void init_security ();
41
42 //FIXME: allow inited, sd, all_nih_.. to be static members
43 SECURITY_DESCRIPTOR _sd;
44 SECURITY_ATTRIBUTES _sec_all_nih;
45 const char *const _pipe_name;
46 HANDLE _hPipe;
47 const bool _is_accepted_endpoint;
48 bool _is_listening_endpoint;
49
50 transport_layer_pipes (HANDLE hPipe);
51 };
52
53 #endif /* _CYGSERVER_TRANSPORT_PIPES_ */
This page took 0.036644 seconds and 5 git commands to generate.