First round of merging various UUID structures.
[Samba/gebeck_regimport.git] / source / include / rpc_epmapper.h
blobbbca6ac1f28786248895827e9e9aaae3444b41e2
1 /*
2 Unix SMB/CIFS implementation.
3 Endpoint mapper data definitions
4 Copyright (C) Jim McDonough (jmcd@us.ibm.com) 2003
6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2 of the License, or
9 (at your option) any later version.
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
21 #define EPM_HANDLE_LEN 20
23 /* ordinal for the mapping interface */
25 #define EPM_MAP_PIPE_NAME 0x03
27 /* some of the different connection protocols and their IDs from Windows */
29 #define EPM_FLOOR_UUID 0x0d /* floor contains UUID */
30 #define EPM_FLOOR_RPC 0x0b /* tower is for connection-oriented rpc */
31 #define EPM_FLOOR_TCP 0x07 /* floor contains tcp port number */
32 #define EPM_FLOOR_IP 0x09 /* floor contains IP address */
33 #define EPM_FLOOR_NMPIPES 0x0f /* floor contains remote named pipe name */
34 #define EPM_FLOOR_LRPC 0x10 /* floor contains local named pipe name */
35 #define EPM_FLOOR_NETBIOS 0x11 /* floor contains netbios address */
36 #define EPM_FLOOR_NETBEUI 0x12 /* floor contains netbeui address */
37 #define EPM_FLOOR_SOCKET 0x20
39 #define EPM_PIPE_NM "epmapper"
41 #define MAX_TOWERS 1
43 typedef struct
45 uint8 data[EPM_HANDLE_LEN];
46 } EPM_HANDLE;
48 typedef struct
50 struct {
51 uint16 length;
52 uint8 protocol;
53 struct {
54 struct uuid uuid;
55 uint16 version;
56 } uuid;
57 } lhs;
58 struct {
59 uint16 length;
60 uint16 unknown;
61 struct {
62 uint16 port;
63 } tcp;
64 struct {
65 uint8 addr[4];
66 } ip;
67 char string[MAXHOSTNAMELEN+3]; /* hostname + \\ + null term */
68 } rhs;
69 } EPM_FLOOR;
71 typedef struct
73 uint32 max_length;
74 uint32 length;
75 uint16 num_floors;
76 EPM_FLOOR *floors;
77 uint8 unknown;
78 } EPM_TOWER;
80 typedef struct
82 EPM_HANDLE handle;
83 uint32 tower_ref_id;
84 EPM_TOWER *tower;
85 EPM_HANDLE term_handle; /* in/out */
86 uint32 max_towers;
87 } EPM_Q_MAP;
89 typedef struct
91 uint32 max_count;
92 uint32 offset;
93 uint32 count;
94 uint32 *tower_ref_ids;
95 EPM_TOWER *towers;
96 } EPM_TOWER_ARRAY;
98 typedef struct
100 EPM_HANDLE handle;
101 uint32 num_results;
102 EPM_TOWER_ARRAY *results;
103 uint32 status;
104 } EPM_R_MAP;
107 /* port mapping entries to be read */
109 typedef struct _mapper_entries{
110 uint8 protocol ;
111 RPC_IFACE uuid_info ; /* needs to be zeroed if no specific uuid */
112 uint16 port ;
113 char pipe_name[40] ;
114 char srv_name[20] ;
115 uint8 srv_port[4] ;
116 char func_name[16][16]; /* array of up to 16 functions available */
117 } mapper_entries;