libnetapi: Add IDL for NetQueryDisplayInformation.
[ira/wip.git] / source3 / librpc / idl / libnetapi.idl
1 /*
2   libnetapi interface definition
3 */
4
5 cpp_quote("#define LIBNETAPI_LOCAL_SERVER(x) (!x || is_myname_or_ipaddr(x))")
6
7 [
8         pointer_default(unique)
9 ]
10 interface libnetapi
11 {
12         const int ERROR_MORE_DATA = 234L;
13
14         [public] typedef [v1_enum] enum {
15                 NERR_Success=0
16         } NET_API_STATUS;
17
18         [nopush,nopull] NET_API_STATUS NetJoinDomain(
19                 [in,unique] string *server,
20                 [in,ref] string *domain,
21                 [in,unique] string *account_ou,
22                 [in,unique] string *account,
23                 [in,unique] string *password,
24                 [in] uint32 join_flags
25                 );
26
27         [nopush,nopull] NET_API_STATUS NetUnjoinDomain(
28                 [in,unique] string *server_name,
29                 [in,unique] string *account,
30                 [in,unique] string *password,
31                 [in] uint32 unjoin_flags
32                 );
33
34         [nopush,nopull] NET_API_STATUS NetGetJoinInformation(
35                 [in,unique] string *server_name,
36                 [out] string **name_buffer,
37                 [out] uint16 *name_type
38                 );
39
40         [nopush,nopull] NET_API_STATUS NetGetJoinableOUs(
41                 [in,unique] string *server_name,
42                 [in,ref] string *domain,
43                 [in,unique] string *account,
44                 [in,unique] string *password,
45                 [out] uint32 *ou_count,
46                 [out] string ***ous
47                 );
48
49         [public] typedef struct {
50                 string sv1005_comment;
51         } SERVER_INFO_1005;
52
53         [nopush,nopull] NET_API_STATUS NetServerGetInfo(
54                 [in,unique] string *server_name,
55                 [in] uint32 level,
56                 [out] uint8 **buffer
57                 );
58
59         [nopush,nopull] NET_API_STATUS NetServerSetInfo(
60                 [in,unique] string *server_name,
61                 [in] uint32 level,
62                 [in] uint8 *buffer,
63                 [out] uint32 *parm_error
64                 );
65
66         [nopush,nopull] NET_API_STATUS NetGetDCName(
67                 [in,unique] string *server_name,
68                 [in,unique] string *domain_name,
69                 [out] uint8 **buffer
70                 );
71
72         [nopush,nopull] NET_API_STATUS NetGetAnyDCName(
73                 [in,unique] string *server_name,
74                 [in,unique] string *domain_name,
75                 [out] uint8 **buffer
76                 );
77
78         [public] typedef struct {
79                 string domain_controller_name;
80                 string domain_controller_address;
81                 uint32 domain_controller_address_type;
82                 GUID domain_guid;
83                 string domain_name;
84                 string dns_forest_name;
85                 uint32 flags;
86                 string dc_site_name;
87                 string client_site_name;
88         } DOMAIN_CONTROLLER_INFO;
89
90         [nopush,nopull] NET_API_STATUS DsGetDcName(
91                 [in,unique] string *server_name,
92                 [in,ref] string *domain_name,
93                 [in,unique] GUID *domain_guid,
94                 [in,unique] string *site_name,
95                 [in] uint32 flags,
96                 [out,ref] DOMAIN_CONTROLLER_INFO **dc_info
97                 );
98
99         [public] typedef struct {
100                 string usri0_name;
101         } USER_INFO_0;
102
103         [public] typedef struct {
104                 string usri1_name;
105                 string usri1_password;
106                 uint32 usri1_password_age;
107                 uint32 usri1_priv;
108                 string usri1_home_dir;
109                 string usri1_comment;
110                 uint32 usri1_flags;
111                 string usri1_script_path;
112         } USER_INFO_1;
113
114         [nopush,nopull] NET_API_STATUS NetUserAdd(
115                 [in,unique] string *server_name,
116                 [in] uint32 level,
117                 [in,ref] uint8 *buffer,
118                 [out,ref] uint32 *parm_error
119                 );
120
121         [nopush,nopull] NET_API_STATUS NetUserDel(
122                 [in,unique] string *server_name,
123                 [in,ref] string *user_name
124                 );
125
126         [nopush,nopull] NET_API_STATUS NetUserEnum(
127                 [in,unique] string *server_name,
128                 [in] uint32 level,
129                 [in] uint32 filter,
130                 [out,ref] uint8 **buffer,
131                 [in] uint32 prefmaxlen,
132                 [out,ref] uint32 *entries_read,
133                 [out,ref] uint32 *total_entries,
134                 [in,out,ref] uint32 *resume_handle
135                 );
136
137         [public] typedef struct {
138                 string usri1_name;
139                 string usri1_comment;
140                 uint32 usri1_flags;
141                 string usri1_full_name;
142                 uint32 usri1_user_id;
143                 uint32 usri1_next_index;
144         } NET_DISPLAY_USER;
145
146         [public] typedef struct {
147                 string usri2_name;
148                 string usri2_comment;
149                 uint32 usri2_flags;
150                 uint32 usri2_user_id;
151                 uint32 usri2_next_index;
152         } NET_DISPLAY_MACHINE;
153
154         [public] typedef struct {
155                 string grpi3_name;
156                 string grpi3_comment;
157                 uint32 grpi3_group_id;
158                 uint32 grpi3_attributes;
159                 uint32 grpi3_next_index;
160         } NET_DISPLAY_GROUP;
161
162         [nopush,nopull] NET_API_STATUS NetQueryDisplayInformation(
163                 [in,unique] string *server_name,
164                 [in] uint32 level,
165                 [in] uint32 idx,
166                 [in] uint32 entries_requested,
167                 [in] uint32 prefmaxlen,
168                 [out,ref] uint32 *entries_read,
169                 [out,ref,noprint] void **buffer
170                 );
171 }