| 1 | /*
|
|---|
| 2 | * Unix SMB/CIFS implementation.
|
|---|
| 3 | * server auto-generated by pidl. DO NOT MODIFY!
|
|---|
| 4 | */
|
|---|
| 5 |
|
|---|
| 6 | #include "includes.h"
|
|---|
| 7 | #include "librpc/gen_ndr/srv_wkssvc.h"
|
|---|
| 8 |
|
|---|
| 9 | static BOOL api_wkssvc_NetWkstaGetInfo(pipes_struct *p)
|
|---|
| 10 | {
|
|---|
| 11 | struct ndr_pull *pull;
|
|---|
| 12 | struct ndr_push *push;
|
|---|
| 13 | NTSTATUS status;
|
|---|
| 14 | DATA_BLOB blob;
|
|---|
| 15 | struct wkssvc_NetWkstaGetInfo r;
|
|---|
| 16 | TALLOC_CTX *mem_ctx = talloc_init("api_wkssvc_NetWkstaGetInfo");
|
|---|
| 17 |
|
|---|
| 18 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 19 | talloc_free(mem_ctx);
|
|---|
| 20 | return False;
|
|---|
| 21 | }
|
|---|
| 22 |
|
|---|
| 23 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 24 | if (pull == NULL) {
|
|---|
| 25 | talloc_free(mem_ctx);
|
|---|
| 26 | return False;
|
|---|
| 27 | }
|
|---|
| 28 |
|
|---|
| 29 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 30 | status = ndr_pull_wkssvc_NetWkstaGetInfo(pull, NDR_IN, &r);
|
|---|
| 31 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 32 | talloc_free(mem_ctx);
|
|---|
| 33 | return False;
|
|---|
| 34 | }
|
|---|
| 35 |
|
|---|
| 36 | if (DEBUGLEVEL >= 10)
|
|---|
| 37 | NDR_PRINT_IN_DEBUG(wkssvc_NetWkstaGetInfo, &r);
|
|---|
| 38 |
|
|---|
| 39 | ZERO_STRUCT(r.out);
|
|---|
| 40 | r.out.info = talloc_zero(mem_ctx, union wkssvc_NetWkstaInfo);
|
|---|
| 41 | if (r.out.info == NULL) {
|
|---|
| 42 | talloc_free(mem_ctx);
|
|---|
| 43 | return False;
|
|---|
| 44 | }
|
|---|
| 45 |
|
|---|
| 46 | r.out.result = _wkssvc_NetWkstaGetInfo(p, &r);
|
|---|
| 47 |
|
|---|
| 48 | if (p->rng_fault_state) {
|
|---|
| 49 | talloc_free(mem_ctx);
|
|---|
| 50 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 51 | return True;
|
|---|
| 52 | }
|
|---|
| 53 |
|
|---|
| 54 | if (DEBUGLEVEL >= 10)
|
|---|
| 55 | NDR_PRINT_OUT_DEBUG(wkssvc_NetWkstaGetInfo, &r);
|
|---|
| 56 |
|
|---|
| 57 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 58 | if (push == NULL) {
|
|---|
| 59 | talloc_free(mem_ctx);
|
|---|
| 60 | return False;
|
|---|
| 61 | }
|
|---|
| 62 |
|
|---|
| 63 | status = ndr_push_wkssvc_NetWkstaGetInfo(push, NDR_OUT, &r);
|
|---|
| 64 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 65 | talloc_free(mem_ctx);
|
|---|
| 66 | return False;
|
|---|
| 67 | }
|
|---|
| 68 |
|
|---|
| 69 | blob = ndr_push_blob(push);
|
|---|
| 70 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 71 | talloc_free(mem_ctx);
|
|---|
| 72 | return False;
|
|---|
| 73 | }
|
|---|
| 74 |
|
|---|
| 75 | talloc_free(mem_ctx);
|
|---|
| 76 |
|
|---|
| 77 | return True;
|
|---|
| 78 | }
|
|---|
| 79 |
|
|---|
| 80 | static BOOL api_wkssvc_NetWkstaSetInfo(pipes_struct *p)
|
|---|
| 81 | {
|
|---|
| 82 | struct ndr_pull *pull;
|
|---|
| 83 | struct ndr_push *push;
|
|---|
| 84 | NTSTATUS status;
|
|---|
| 85 | DATA_BLOB blob;
|
|---|
| 86 | struct wkssvc_NetWkstaSetInfo r;
|
|---|
| 87 | TALLOC_CTX *mem_ctx = talloc_init("api_wkssvc_NetWkstaSetInfo");
|
|---|
| 88 |
|
|---|
| 89 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 90 | talloc_free(mem_ctx);
|
|---|
| 91 | return False;
|
|---|
| 92 | }
|
|---|
| 93 |
|
|---|
| 94 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 95 | if (pull == NULL) {
|
|---|
| 96 | talloc_free(mem_ctx);
|
|---|
| 97 | return False;
|
|---|
| 98 | }
|
|---|
| 99 |
|
|---|
| 100 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 101 | status = ndr_pull_wkssvc_NetWkstaSetInfo(pull, NDR_IN, &r);
|
|---|
| 102 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 103 | talloc_free(mem_ctx);
|
|---|
| 104 | return False;
|
|---|
| 105 | }
|
|---|
| 106 |
|
|---|
| 107 | if (DEBUGLEVEL >= 10)
|
|---|
| 108 | NDR_PRINT_IN_DEBUG(wkssvc_NetWkstaSetInfo, &r);
|
|---|
| 109 |
|
|---|
| 110 | ZERO_STRUCT(r.out);
|
|---|
| 111 | r.out.parm_error = r.in.parm_error;
|
|---|
| 112 | r.out.result = _wkssvc_NetWkstaSetInfo(p, &r);
|
|---|
| 113 |
|
|---|
| 114 | if (p->rng_fault_state) {
|
|---|
| 115 | talloc_free(mem_ctx);
|
|---|
| 116 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 117 | return True;
|
|---|
| 118 | }
|
|---|
| 119 |
|
|---|
| 120 | if (DEBUGLEVEL >= 10)
|
|---|
| 121 | NDR_PRINT_OUT_DEBUG(wkssvc_NetWkstaSetInfo, &r);
|
|---|
| 122 |
|
|---|
| 123 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 124 | if (push == NULL) {
|
|---|
| 125 | talloc_free(mem_ctx);
|
|---|
| 126 | return False;
|
|---|
| 127 | }
|
|---|
| 128 |
|
|---|
| 129 | status = ndr_push_wkssvc_NetWkstaSetInfo(push, NDR_OUT, &r);
|
|---|
| 130 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 131 | talloc_free(mem_ctx);
|
|---|
| 132 | return False;
|
|---|
| 133 | }
|
|---|
| 134 |
|
|---|
| 135 | blob = ndr_push_blob(push);
|
|---|
| 136 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 137 | talloc_free(mem_ctx);
|
|---|
| 138 | return False;
|
|---|
| 139 | }
|
|---|
| 140 |
|
|---|
| 141 | talloc_free(mem_ctx);
|
|---|
| 142 |
|
|---|
| 143 | return True;
|
|---|
| 144 | }
|
|---|
| 145 |
|
|---|
| 146 | static BOOL api_wkssvc_NetWkstaEnumUsers(pipes_struct *p)
|
|---|
| 147 | {
|
|---|
| 148 | struct ndr_pull *pull;
|
|---|
| 149 | struct ndr_push *push;
|
|---|
| 150 | NTSTATUS status;
|
|---|
| 151 | DATA_BLOB blob;
|
|---|
| 152 | struct wkssvc_NetWkstaEnumUsers r;
|
|---|
| 153 | TALLOC_CTX *mem_ctx = talloc_init("api_wkssvc_NetWkstaEnumUsers");
|
|---|
| 154 |
|
|---|
| 155 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 156 | talloc_free(mem_ctx);
|
|---|
| 157 | return False;
|
|---|
| 158 | }
|
|---|
| 159 |
|
|---|
| 160 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 161 | if (pull == NULL) {
|
|---|
| 162 | talloc_free(mem_ctx);
|
|---|
| 163 | return False;
|
|---|
| 164 | }
|
|---|
| 165 |
|
|---|
| 166 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 167 | status = ndr_pull_wkssvc_NetWkstaEnumUsers(pull, NDR_IN, &r);
|
|---|
| 168 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 169 | talloc_free(mem_ctx);
|
|---|
| 170 | return False;
|
|---|
| 171 | }
|
|---|
| 172 |
|
|---|
| 173 | if (DEBUGLEVEL >= 10)
|
|---|
| 174 | NDR_PRINT_IN_DEBUG(wkssvc_NetWkstaEnumUsers, &r);
|
|---|
| 175 |
|
|---|
| 176 | ZERO_STRUCT(r.out);
|
|---|
| 177 | r.out.users = r.in.users;
|
|---|
| 178 | r.out.entriesread = talloc_zero(mem_ctx, uint32_t);
|
|---|
| 179 | if (r.out.entriesread == NULL) {
|
|---|
| 180 | talloc_free(mem_ctx);
|
|---|
| 181 | return False;
|
|---|
| 182 | }
|
|---|
| 183 |
|
|---|
| 184 | r.out.totalentries = talloc_zero(mem_ctx, uint32_t);
|
|---|
| 185 | if (r.out.totalentries == NULL) {
|
|---|
| 186 | talloc_free(mem_ctx);
|
|---|
| 187 | return False;
|
|---|
| 188 | }
|
|---|
| 189 |
|
|---|
| 190 | r.out.resumehandle = r.in.resumehandle;
|
|---|
| 191 | r.out.result = _wkssvc_NetWkstaEnumUsers(p, &r);
|
|---|
| 192 |
|
|---|
| 193 | if (p->rng_fault_state) {
|
|---|
| 194 | talloc_free(mem_ctx);
|
|---|
| 195 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 196 | return True;
|
|---|
| 197 | }
|
|---|
| 198 |
|
|---|
| 199 | if (DEBUGLEVEL >= 10)
|
|---|
| 200 | NDR_PRINT_OUT_DEBUG(wkssvc_NetWkstaEnumUsers, &r);
|
|---|
| 201 |
|
|---|
| 202 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 203 | if (push == NULL) {
|
|---|
| 204 | talloc_free(mem_ctx);
|
|---|
| 205 | return False;
|
|---|
| 206 | }
|
|---|
| 207 |
|
|---|
| 208 | status = ndr_push_wkssvc_NetWkstaEnumUsers(push, NDR_OUT, &r);
|
|---|
| 209 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 210 | talloc_free(mem_ctx);
|
|---|
| 211 | return False;
|
|---|
| 212 | }
|
|---|
| 213 |
|
|---|
| 214 | blob = ndr_push_blob(push);
|
|---|
| 215 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 216 | talloc_free(mem_ctx);
|
|---|
| 217 | return False;
|
|---|
| 218 | }
|
|---|
| 219 |
|
|---|
| 220 | talloc_free(mem_ctx);
|
|---|
| 221 |
|
|---|
| 222 | return True;
|
|---|
| 223 | }
|
|---|
| 224 |
|
|---|
| 225 | static BOOL api_WKSSVC_NETRWKSTAUSERGETINFO(pipes_struct *p)
|
|---|
| 226 | {
|
|---|
| 227 | struct ndr_pull *pull;
|
|---|
| 228 | struct ndr_push *push;
|
|---|
| 229 | NTSTATUS status;
|
|---|
| 230 | DATA_BLOB blob;
|
|---|
| 231 | struct WKSSVC_NETRWKSTAUSERGETINFO r;
|
|---|
| 232 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRWKSTAUSERGETINFO");
|
|---|
| 233 |
|
|---|
| 234 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 235 | talloc_free(mem_ctx);
|
|---|
| 236 | return False;
|
|---|
| 237 | }
|
|---|
| 238 |
|
|---|
| 239 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 240 | if (pull == NULL) {
|
|---|
| 241 | talloc_free(mem_ctx);
|
|---|
| 242 | return False;
|
|---|
| 243 | }
|
|---|
| 244 |
|
|---|
| 245 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 246 | status = ndr_pull_WKSSVC_NETRWKSTAUSERGETINFO(pull, NDR_IN, &r);
|
|---|
| 247 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 248 | talloc_free(mem_ctx);
|
|---|
| 249 | return False;
|
|---|
| 250 | }
|
|---|
| 251 |
|
|---|
| 252 | if (DEBUGLEVEL >= 10)
|
|---|
| 253 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRWKSTAUSERGETINFO, &r);
|
|---|
| 254 |
|
|---|
| 255 | r.out.result = _WKSSVC_NETRWKSTAUSERGETINFO(p, &r);
|
|---|
| 256 |
|
|---|
| 257 | if (p->rng_fault_state) {
|
|---|
| 258 | talloc_free(mem_ctx);
|
|---|
| 259 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 260 | return True;
|
|---|
| 261 | }
|
|---|
| 262 |
|
|---|
| 263 | if (DEBUGLEVEL >= 10)
|
|---|
| 264 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRWKSTAUSERGETINFO, &r);
|
|---|
| 265 |
|
|---|
| 266 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 267 | if (push == NULL) {
|
|---|
| 268 | talloc_free(mem_ctx);
|
|---|
| 269 | return False;
|
|---|
| 270 | }
|
|---|
| 271 |
|
|---|
| 272 | status = ndr_push_WKSSVC_NETRWKSTAUSERGETINFO(push, NDR_OUT, &r);
|
|---|
| 273 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 274 | talloc_free(mem_ctx);
|
|---|
| 275 | return False;
|
|---|
| 276 | }
|
|---|
| 277 |
|
|---|
| 278 | blob = ndr_push_blob(push);
|
|---|
| 279 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 280 | talloc_free(mem_ctx);
|
|---|
| 281 | return False;
|
|---|
| 282 | }
|
|---|
| 283 |
|
|---|
| 284 | talloc_free(mem_ctx);
|
|---|
| 285 |
|
|---|
| 286 | return True;
|
|---|
| 287 | }
|
|---|
| 288 |
|
|---|
| 289 | static BOOL api_WKSSVC_NETRWKSTAUSERSETINFO(pipes_struct *p)
|
|---|
| 290 | {
|
|---|
| 291 | struct ndr_pull *pull;
|
|---|
| 292 | struct ndr_push *push;
|
|---|
| 293 | NTSTATUS status;
|
|---|
| 294 | DATA_BLOB blob;
|
|---|
| 295 | struct WKSSVC_NETRWKSTAUSERSETINFO r;
|
|---|
| 296 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRWKSTAUSERSETINFO");
|
|---|
| 297 |
|
|---|
| 298 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 299 | talloc_free(mem_ctx);
|
|---|
| 300 | return False;
|
|---|
| 301 | }
|
|---|
| 302 |
|
|---|
| 303 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 304 | if (pull == NULL) {
|
|---|
| 305 | talloc_free(mem_ctx);
|
|---|
| 306 | return False;
|
|---|
| 307 | }
|
|---|
| 308 |
|
|---|
| 309 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 310 | status = ndr_pull_WKSSVC_NETRWKSTAUSERSETINFO(pull, NDR_IN, &r);
|
|---|
| 311 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 312 | talloc_free(mem_ctx);
|
|---|
| 313 | return False;
|
|---|
| 314 | }
|
|---|
| 315 |
|
|---|
| 316 | if (DEBUGLEVEL >= 10)
|
|---|
| 317 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRWKSTAUSERSETINFO, &r);
|
|---|
| 318 |
|
|---|
| 319 | r.out.result = _WKSSVC_NETRWKSTAUSERSETINFO(p, &r);
|
|---|
| 320 |
|
|---|
| 321 | if (p->rng_fault_state) {
|
|---|
| 322 | talloc_free(mem_ctx);
|
|---|
| 323 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 324 | return True;
|
|---|
| 325 | }
|
|---|
| 326 |
|
|---|
| 327 | if (DEBUGLEVEL >= 10)
|
|---|
| 328 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRWKSTAUSERSETINFO, &r);
|
|---|
| 329 |
|
|---|
| 330 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 331 | if (push == NULL) {
|
|---|
| 332 | talloc_free(mem_ctx);
|
|---|
| 333 | return False;
|
|---|
| 334 | }
|
|---|
| 335 |
|
|---|
| 336 | status = ndr_push_WKSSVC_NETRWKSTAUSERSETINFO(push, NDR_OUT, &r);
|
|---|
| 337 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 338 | talloc_free(mem_ctx);
|
|---|
| 339 | return False;
|
|---|
| 340 | }
|
|---|
| 341 |
|
|---|
| 342 | blob = ndr_push_blob(push);
|
|---|
| 343 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 344 | talloc_free(mem_ctx);
|
|---|
| 345 | return False;
|
|---|
| 346 | }
|
|---|
| 347 |
|
|---|
| 348 | talloc_free(mem_ctx);
|
|---|
| 349 |
|
|---|
| 350 | return True;
|
|---|
| 351 | }
|
|---|
| 352 |
|
|---|
| 353 | static BOOL api_wkssvc_NetWkstaTransportEnum(pipes_struct *p)
|
|---|
| 354 | {
|
|---|
| 355 | struct ndr_pull *pull;
|
|---|
| 356 | struct ndr_push *push;
|
|---|
| 357 | NTSTATUS status;
|
|---|
| 358 | DATA_BLOB blob;
|
|---|
| 359 | struct wkssvc_NetWkstaTransportEnum r;
|
|---|
| 360 | TALLOC_CTX *mem_ctx = talloc_init("api_wkssvc_NetWkstaTransportEnum");
|
|---|
| 361 |
|
|---|
| 362 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 363 | talloc_free(mem_ctx);
|
|---|
| 364 | return False;
|
|---|
| 365 | }
|
|---|
| 366 |
|
|---|
| 367 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 368 | if (pull == NULL) {
|
|---|
| 369 | talloc_free(mem_ctx);
|
|---|
| 370 | return False;
|
|---|
| 371 | }
|
|---|
| 372 |
|
|---|
| 373 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 374 | status = ndr_pull_wkssvc_NetWkstaTransportEnum(pull, NDR_IN, &r);
|
|---|
| 375 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 376 | talloc_free(mem_ctx);
|
|---|
| 377 | return False;
|
|---|
| 378 | }
|
|---|
| 379 |
|
|---|
| 380 | if (DEBUGLEVEL >= 10)
|
|---|
| 381 | NDR_PRINT_IN_DEBUG(wkssvc_NetWkstaTransportEnum, &r);
|
|---|
| 382 |
|
|---|
| 383 | ZERO_STRUCT(r.out);
|
|---|
| 384 | r.out.level = r.in.level;
|
|---|
| 385 | r.out.ctr = r.in.ctr;
|
|---|
| 386 | r.out.totalentries = talloc_zero(mem_ctx, uint32_t);
|
|---|
| 387 | if (r.out.totalentries == NULL) {
|
|---|
| 388 | talloc_free(mem_ctx);
|
|---|
| 389 | return False;
|
|---|
| 390 | }
|
|---|
| 391 |
|
|---|
| 392 | r.out.resume_handle = r.in.resume_handle;
|
|---|
| 393 | r.out.result = _wkssvc_NetWkstaTransportEnum(p, &r);
|
|---|
| 394 |
|
|---|
| 395 | if (p->rng_fault_state) {
|
|---|
| 396 | talloc_free(mem_ctx);
|
|---|
| 397 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 398 | return True;
|
|---|
| 399 | }
|
|---|
| 400 |
|
|---|
| 401 | if (DEBUGLEVEL >= 10)
|
|---|
| 402 | NDR_PRINT_OUT_DEBUG(wkssvc_NetWkstaTransportEnum, &r);
|
|---|
| 403 |
|
|---|
| 404 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 405 | if (push == NULL) {
|
|---|
| 406 | talloc_free(mem_ctx);
|
|---|
| 407 | return False;
|
|---|
| 408 | }
|
|---|
| 409 |
|
|---|
| 410 | status = ndr_push_wkssvc_NetWkstaTransportEnum(push, NDR_OUT, &r);
|
|---|
| 411 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 412 | talloc_free(mem_ctx);
|
|---|
| 413 | return False;
|
|---|
| 414 | }
|
|---|
| 415 |
|
|---|
| 416 | blob = ndr_push_blob(push);
|
|---|
| 417 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 418 | talloc_free(mem_ctx);
|
|---|
| 419 | return False;
|
|---|
| 420 | }
|
|---|
| 421 |
|
|---|
| 422 | talloc_free(mem_ctx);
|
|---|
| 423 |
|
|---|
| 424 | return True;
|
|---|
| 425 | }
|
|---|
| 426 |
|
|---|
| 427 | static BOOL api_WKSSVC_NETRWKSTATRANSPORTADD(pipes_struct *p)
|
|---|
| 428 | {
|
|---|
| 429 | struct ndr_pull *pull;
|
|---|
| 430 | struct ndr_push *push;
|
|---|
| 431 | NTSTATUS status;
|
|---|
| 432 | DATA_BLOB blob;
|
|---|
| 433 | struct WKSSVC_NETRWKSTATRANSPORTADD r;
|
|---|
| 434 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRWKSTATRANSPORTADD");
|
|---|
| 435 |
|
|---|
| 436 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 437 | talloc_free(mem_ctx);
|
|---|
| 438 | return False;
|
|---|
| 439 | }
|
|---|
| 440 |
|
|---|
| 441 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 442 | if (pull == NULL) {
|
|---|
| 443 | talloc_free(mem_ctx);
|
|---|
| 444 | return False;
|
|---|
| 445 | }
|
|---|
| 446 |
|
|---|
| 447 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 448 | status = ndr_pull_WKSSVC_NETRWKSTATRANSPORTADD(pull, NDR_IN, &r);
|
|---|
| 449 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 450 | talloc_free(mem_ctx);
|
|---|
| 451 | return False;
|
|---|
| 452 | }
|
|---|
| 453 |
|
|---|
| 454 | if (DEBUGLEVEL >= 10)
|
|---|
| 455 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRWKSTATRANSPORTADD, &r);
|
|---|
| 456 |
|
|---|
| 457 | r.out.result = _WKSSVC_NETRWKSTATRANSPORTADD(p, &r);
|
|---|
| 458 |
|
|---|
| 459 | if (p->rng_fault_state) {
|
|---|
| 460 | talloc_free(mem_ctx);
|
|---|
| 461 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 462 | return True;
|
|---|
| 463 | }
|
|---|
| 464 |
|
|---|
| 465 | if (DEBUGLEVEL >= 10)
|
|---|
| 466 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRWKSTATRANSPORTADD, &r);
|
|---|
| 467 |
|
|---|
| 468 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 469 | if (push == NULL) {
|
|---|
| 470 | talloc_free(mem_ctx);
|
|---|
| 471 | return False;
|
|---|
| 472 | }
|
|---|
| 473 |
|
|---|
| 474 | status = ndr_push_WKSSVC_NETRWKSTATRANSPORTADD(push, NDR_OUT, &r);
|
|---|
| 475 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 476 | talloc_free(mem_ctx);
|
|---|
| 477 | return False;
|
|---|
| 478 | }
|
|---|
| 479 |
|
|---|
| 480 | blob = ndr_push_blob(push);
|
|---|
| 481 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 482 | talloc_free(mem_ctx);
|
|---|
| 483 | return False;
|
|---|
| 484 | }
|
|---|
| 485 |
|
|---|
| 486 | talloc_free(mem_ctx);
|
|---|
| 487 |
|
|---|
| 488 | return True;
|
|---|
| 489 | }
|
|---|
| 490 |
|
|---|
| 491 | static BOOL api_WKSSVC_NETRWKSTATRANSPORTDEL(pipes_struct *p)
|
|---|
| 492 | {
|
|---|
| 493 | struct ndr_pull *pull;
|
|---|
| 494 | struct ndr_push *push;
|
|---|
| 495 | NTSTATUS status;
|
|---|
| 496 | DATA_BLOB blob;
|
|---|
| 497 | struct WKSSVC_NETRWKSTATRANSPORTDEL r;
|
|---|
| 498 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRWKSTATRANSPORTDEL");
|
|---|
| 499 |
|
|---|
| 500 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 501 | talloc_free(mem_ctx);
|
|---|
| 502 | return False;
|
|---|
| 503 | }
|
|---|
| 504 |
|
|---|
| 505 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 506 | if (pull == NULL) {
|
|---|
| 507 | talloc_free(mem_ctx);
|
|---|
| 508 | return False;
|
|---|
| 509 | }
|
|---|
| 510 |
|
|---|
| 511 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 512 | status = ndr_pull_WKSSVC_NETRWKSTATRANSPORTDEL(pull, NDR_IN, &r);
|
|---|
| 513 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 514 | talloc_free(mem_ctx);
|
|---|
| 515 | return False;
|
|---|
| 516 | }
|
|---|
| 517 |
|
|---|
| 518 | if (DEBUGLEVEL >= 10)
|
|---|
| 519 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRWKSTATRANSPORTDEL, &r);
|
|---|
| 520 |
|
|---|
| 521 | r.out.result = _WKSSVC_NETRWKSTATRANSPORTDEL(p, &r);
|
|---|
| 522 |
|
|---|
| 523 | if (p->rng_fault_state) {
|
|---|
| 524 | talloc_free(mem_ctx);
|
|---|
| 525 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 526 | return True;
|
|---|
| 527 | }
|
|---|
| 528 |
|
|---|
| 529 | if (DEBUGLEVEL >= 10)
|
|---|
| 530 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRWKSTATRANSPORTDEL, &r);
|
|---|
| 531 |
|
|---|
| 532 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 533 | if (push == NULL) {
|
|---|
| 534 | talloc_free(mem_ctx);
|
|---|
| 535 | return False;
|
|---|
| 536 | }
|
|---|
| 537 |
|
|---|
| 538 | status = ndr_push_WKSSVC_NETRWKSTATRANSPORTDEL(push, NDR_OUT, &r);
|
|---|
| 539 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 540 | talloc_free(mem_ctx);
|
|---|
| 541 | return False;
|
|---|
| 542 | }
|
|---|
| 543 |
|
|---|
| 544 | blob = ndr_push_blob(push);
|
|---|
| 545 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 546 | talloc_free(mem_ctx);
|
|---|
| 547 | return False;
|
|---|
| 548 | }
|
|---|
| 549 |
|
|---|
| 550 | talloc_free(mem_ctx);
|
|---|
| 551 |
|
|---|
| 552 | return True;
|
|---|
| 553 | }
|
|---|
| 554 |
|
|---|
| 555 | static BOOL api_WKSSVC_NETRUSEADD(pipes_struct *p)
|
|---|
| 556 | {
|
|---|
| 557 | struct ndr_pull *pull;
|
|---|
| 558 | struct ndr_push *push;
|
|---|
| 559 | NTSTATUS status;
|
|---|
| 560 | DATA_BLOB blob;
|
|---|
| 561 | struct WKSSVC_NETRUSEADD r;
|
|---|
| 562 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRUSEADD");
|
|---|
| 563 |
|
|---|
| 564 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 565 | talloc_free(mem_ctx);
|
|---|
| 566 | return False;
|
|---|
| 567 | }
|
|---|
| 568 |
|
|---|
| 569 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 570 | if (pull == NULL) {
|
|---|
| 571 | talloc_free(mem_ctx);
|
|---|
| 572 | return False;
|
|---|
| 573 | }
|
|---|
| 574 |
|
|---|
| 575 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 576 | status = ndr_pull_WKSSVC_NETRUSEADD(pull, NDR_IN, &r);
|
|---|
| 577 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 578 | talloc_free(mem_ctx);
|
|---|
| 579 | return False;
|
|---|
| 580 | }
|
|---|
| 581 |
|
|---|
| 582 | if (DEBUGLEVEL >= 10)
|
|---|
| 583 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRUSEADD, &r);
|
|---|
| 584 |
|
|---|
| 585 | r.out.result = _WKSSVC_NETRUSEADD(p, &r);
|
|---|
| 586 |
|
|---|
| 587 | if (p->rng_fault_state) {
|
|---|
| 588 | talloc_free(mem_ctx);
|
|---|
| 589 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 590 | return True;
|
|---|
| 591 | }
|
|---|
| 592 |
|
|---|
| 593 | if (DEBUGLEVEL >= 10)
|
|---|
| 594 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRUSEADD, &r);
|
|---|
| 595 |
|
|---|
| 596 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 597 | if (push == NULL) {
|
|---|
| 598 | talloc_free(mem_ctx);
|
|---|
| 599 | return False;
|
|---|
| 600 | }
|
|---|
| 601 |
|
|---|
| 602 | status = ndr_push_WKSSVC_NETRUSEADD(push, NDR_OUT, &r);
|
|---|
| 603 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 604 | talloc_free(mem_ctx);
|
|---|
| 605 | return False;
|
|---|
| 606 | }
|
|---|
| 607 |
|
|---|
| 608 | blob = ndr_push_blob(push);
|
|---|
| 609 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 610 | talloc_free(mem_ctx);
|
|---|
| 611 | return False;
|
|---|
| 612 | }
|
|---|
| 613 |
|
|---|
| 614 | talloc_free(mem_ctx);
|
|---|
| 615 |
|
|---|
| 616 | return True;
|
|---|
| 617 | }
|
|---|
| 618 |
|
|---|
| 619 | static BOOL api_WKSSVC_NETRUSEGETINFO(pipes_struct *p)
|
|---|
| 620 | {
|
|---|
| 621 | struct ndr_pull *pull;
|
|---|
| 622 | struct ndr_push *push;
|
|---|
| 623 | NTSTATUS status;
|
|---|
| 624 | DATA_BLOB blob;
|
|---|
| 625 | struct WKSSVC_NETRUSEGETINFO r;
|
|---|
| 626 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRUSEGETINFO");
|
|---|
| 627 |
|
|---|
| 628 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 629 | talloc_free(mem_ctx);
|
|---|
| 630 | return False;
|
|---|
| 631 | }
|
|---|
| 632 |
|
|---|
| 633 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 634 | if (pull == NULL) {
|
|---|
| 635 | talloc_free(mem_ctx);
|
|---|
| 636 | return False;
|
|---|
| 637 | }
|
|---|
| 638 |
|
|---|
| 639 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 640 | status = ndr_pull_WKSSVC_NETRUSEGETINFO(pull, NDR_IN, &r);
|
|---|
| 641 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 642 | talloc_free(mem_ctx);
|
|---|
| 643 | return False;
|
|---|
| 644 | }
|
|---|
| 645 |
|
|---|
| 646 | if (DEBUGLEVEL >= 10)
|
|---|
| 647 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRUSEGETINFO, &r);
|
|---|
| 648 |
|
|---|
| 649 | r.out.result = _WKSSVC_NETRUSEGETINFO(p, &r);
|
|---|
| 650 |
|
|---|
| 651 | if (p->rng_fault_state) {
|
|---|
| 652 | talloc_free(mem_ctx);
|
|---|
| 653 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 654 | return True;
|
|---|
| 655 | }
|
|---|
| 656 |
|
|---|
| 657 | if (DEBUGLEVEL >= 10)
|
|---|
| 658 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRUSEGETINFO, &r);
|
|---|
| 659 |
|
|---|
| 660 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 661 | if (push == NULL) {
|
|---|
| 662 | talloc_free(mem_ctx);
|
|---|
| 663 | return False;
|
|---|
| 664 | }
|
|---|
| 665 |
|
|---|
| 666 | status = ndr_push_WKSSVC_NETRUSEGETINFO(push, NDR_OUT, &r);
|
|---|
| 667 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 668 | talloc_free(mem_ctx);
|
|---|
| 669 | return False;
|
|---|
| 670 | }
|
|---|
| 671 |
|
|---|
| 672 | blob = ndr_push_blob(push);
|
|---|
| 673 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 674 | talloc_free(mem_ctx);
|
|---|
| 675 | return False;
|
|---|
| 676 | }
|
|---|
| 677 |
|
|---|
| 678 | talloc_free(mem_ctx);
|
|---|
| 679 |
|
|---|
| 680 | return True;
|
|---|
| 681 | }
|
|---|
| 682 |
|
|---|
| 683 | static BOOL api_WKSSVC_NETRUSEDEL(pipes_struct *p)
|
|---|
| 684 | {
|
|---|
| 685 | struct ndr_pull *pull;
|
|---|
| 686 | struct ndr_push *push;
|
|---|
| 687 | NTSTATUS status;
|
|---|
| 688 | DATA_BLOB blob;
|
|---|
| 689 | struct WKSSVC_NETRUSEDEL r;
|
|---|
| 690 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRUSEDEL");
|
|---|
| 691 |
|
|---|
| 692 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 693 | talloc_free(mem_ctx);
|
|---|
| 694 | return False;
|
|---|
| 695 | }
|
|---|
| 696 |
|
|---|
| 697 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 698 | if (pull == NULL) {
|
|---|
| 699 | talloc_free(mem_ctx);
|
|---|
| 700 | return False;
|
|---|
| 701 | }
|
|---|
| 702 |
|
|---|
| 703 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 704 | status = ndr_pull_WKSSVC_NETRUSEDEL(pull, NDR_IN, &r);
|
|---|
| 705 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 706 | talloc_free(mem_ctx);
|
|---|
| 707 | return False;
|
|---|
| 708 | }
|
|---|
| 709 |
|
|---|
| 710 | if (DEBUGLEVEL >= 10)
|
|---|
| 711 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRUSEDEL, &r);
|
|---|
| 712 |
|
|---|
| 713 | r.out.result = _WKSSVC_NETRUSEDEL(p, &r);
|
|---|
| 714 |
|
|---|
| 715 | if (p->rng_fault_state) {
|
|---|
| 716 | talloc_free(mem_ctx);
|
|---|
| 717 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 718 | return True;
|
|---|
| 719 | }
|
|---|
| 720 |
|
|---|
| 721 | if (DEBUGLEVEL >= 10)
|
|---|
| 722 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRUSEDEL, &r);
|
|---|
| 723 |
|
|---|
| 724 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 725 | if (push == NULL) {
|
|---|
| 726 | talloc_free(mem_ctx);
|
|---|
| 727 | return False;
|
|---|
| 728 | }
|
|---|
| 729 |
|
|---|
| 730 | status = ndr_push_WKSSVC_NETRUSEDEL(push, NDR_OUT, &r);
|
|---|
| 731 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 732 | talloc_free(mem_ctx);
|
|---|
| 733 | return False;
|
|---|
| 734 | }
|
|---|
| 735 |
|
|---|
| 736 | blob = ndr_push_blob(push);
|
|---|
| 737 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 738 | talloc_free(mem_ctx);
|
|---|
| 739 | return False;
|
|---|
| 740 | }
|
|---|
| 741 |
|
|---|
| 742 | talloc_free(mem_ctx);
|
|---|
| 743 |
|
|---|
| 744 | return True;
|
|---|
| 745 | }
|
|---|
| 746 |
|
|---|
| 747 | static BOOL api_WKSSVC_NETRUSEENUM(pipes_struct *p)
|
|---|
| 748 | {
|
|---|
| 749 | struct ndr_pull *pull;
|
|---|
| 750 | struct ndr_push *push;
|
|---|
| 751 | NTSTATUS status;
|
|---|
| 752 | DATA_BLOB blob;
|
|---|
| 753 | struct WKSSVC_NETRUSEENUM r;
|
|---|
| 754 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRUSEENUM");
|
|---|
| 755 |
|
|---|
| 756 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 757 | talloc_free(mem_ctx);
|
|---|
| 758 | return False;
|
|---|
| 759 | }
|
|---|
| 760 |
|
|---|
| 761 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 762 | if (pull == NULL) {
|
|---|
| 763 | talloc_free(mem_ctx);
|
|---|
| 764 | return False;
|
|---|
| 765 | }
|
|---|
| 766 |
|
|---|
| 767 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 768 | status = ndr_pull_WKSSVC_NETRUSEENUM(pull, NDR_IN, &r);
|
|---|
| 769 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 770 | talloc_free(mem_ctx);
|
|---|
| 771 | return False;
|
|---|
| 772 | }
|
|---|
| 773 |
|
|---|
| 774 | if (DEBUGLEVEL >= 10)
|
|---|
| 775 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRUSEENUM, &r);
|
|---|
| 776 |
|
|---|
| 777 | r.out.result = _WKSSVC_NETRUSEENUM(p, &r);
|
|---|
| 778 |
|
|---|
| 779 | if (p->rng_fault_state) {
|
|---|
| 780 | talloc_free(mem_ctx);
|
|---|
| 781 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 782 | return True;
|
|---|
| 783 | }
|
|---|
| 784 |
|
|---|
| 785 | if (DEBUGLEVEL >= 10)
|
|---|
| 786 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRUSEENUM, &r);
|
|---|
| 787 |
|
|---|
| 788 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 789 | if (push == NULL) {
|
|---|
| 790 | talloc_free(mem_ctx);
|
|---|
| 791 | return False;
|
|---|
| 792 | }
|
|---|
| 793 |
|
|---|
| 794 | status = ndr_push_WKSSVC_NETRUSEENUM(push, NDR_OUT, &r);
|
|---|
| 795 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 796 | talloc_free(mem_ctx);
|
|---|
| 797 | return False;
|
|---|
| 798 | }
|
|---|
| 799 |
|
|---|
| 800 | blob = ndr_push_blob(push);
|
|---|
| 801 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 802 | talloc_free(mem_ctx);
|
|---|
| 803 | return False;
|
|---|
| 804 | }
|
|---|
| 805 |
|
|---|
| 806 | talloc_free(mem_ctx);
|
|---|
| 807 |
|
|---|
| 808 | return True;
|
|---|
| 809 | }
|
|---|
| 810 |
|
|---|
| 811 | static BOOL api_WKSSVC_NETRMESSAGEBUFFERSEND(pipes_struct *p)
|
|---|
| 812 | {
|
|---|
| 813 | struct ndr_pull *pull;
|
|---|
| 814 | struct ndr_push *push;
|
|---|
| 815 | NTSTATUS status;
|
|---|
| 816 | DATA_BLOB blob;
|
|---|
| 817 | struct WKSSVC_NETRMESSAGEBUFFERSEND r;
|
|---|
| 818 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRMESSAGEBUFFERSEND");
|
|---|
| 819 |
|
|---|
| 820 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 821 | talloc_free(mem_ctx);
|
|---|
| 822 | return False;
|
|---|
| 823 | }
|
|---|
| 824 |
|
|---|
| 825 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 826 | if (pull == NULL) {
|
|---|
| 827 | talloc_free(mem_ctx);
|
|---|
| 828 | return False;
|
|---|
| 829 | }
|
|---|
| 830 |
|
|---|
| 831 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 832 | status = ndr_pull_WKSSVC_NETRMESSAGEBUFFERSEND(pull, NDR_IN, &r);
|
|---|
| 833 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 834 | talloc_free(mem_ctx);
|
|---|
| 835 | return False;
|
|---|
| 836 | }
|
|---|
| 837 |
|
|---|
| 838 | if (DEBUGLEVEL >= 10)
|
|---|
| 839 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRMESSAGEBUFFERSEND, &r);
|
|---|
| 840 |
|
|---|
| 841 | r.out.result = _WKSSVC_NETRMESSAGEBUFFERSEND(p, &r);
|
|---|
| 842 |
|
|---|
| 843 | if (p->rng_fault_state) {
|
|---|
| 844 | talloc_free(mem_ctx);
|
|---|
| 845 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 846 | return True;
|
|---|
| 847 | }
|
|---|
| 848 |
|
|---|
| 849 | if (DEBUGLEVEL >= 10)
|
|---|
| 850 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRMESSAGEBUFFERSEND, &r);
|
|---|
| 851 |
|
|---|
| 852 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 853 | if (push == NULL) {
|
|---|
| 854 | talloc_free(mem_ctx);
|
|---|
| 855 | return False;
|
|---|
| 856 | }
|
|---|
| 857 |
|
|---|
| 858 | status = ndr_push_WKSSVC_NETRMESSAGEBUFFERSEND(push, NDR_OUT, &r);
|
|---|
| 859 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 860 | talloc_free(mem_ctx);
|
|---|
| 861 | return False;
|
|---|
| 862 | }
|
|---|
| 863 |
|
|---|
| 864 | blob = ndr_push_blob(push);
|
|---|
| 865 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 866 | talloc_free(mem_ctx);
|
|---|
| 867 | return False;
|
|---|
| 868 | }
|
|---|
| 869 |
|
|---|
| 870 | talloc_free(mem_ctx);
|
|---|
| 871 |
|
|---|
| 872 | return True;
|
|---|
| 873 | }
|
|---|
| 874 |
|
|---|
| 875 | static BOOL api_WKSSVC_NETRWORKSTATIONSTATISTICSGET(pipes_struct *p)
|
|---|
| 876 | {
|
|---|
| 877 | struct ndr_pull *pull;
|
|---|
| 878 | struct ndr_push *push;
|
|---|
| 879 | NTSTATUS status;
|
|---|
| 880 | DATA_BLOB blob;
|
|---|
| 881 | struct WKSSVC_NETRWORKSTATIONSTATISTICSGET r;
|
|---|
| 882 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRWORKSTATIONSTATISTICSGET");
|
|---|
| 883 |
|
|---|
| 884 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 885 | talloc_free(mem_ctx);
|
|---|
| 886 | return False;
|
|---|
| 887 | }
|
|---|
| 888 |
|
|---|
| 889 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 890 | if (pull == NULL) {
|
|---|
| 891 | talloc_free(mem_ctx);
|
|---|
| 892 | return False;
|
|---|
| 893 | }
|
|---|
| 894 |
|
|---|
| 895 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 896 | status = ndr_pull_WKSSVC_NETRWORKSTATIONSTATISTICSGET(pull, NDR_IN, &r);
|
|---|
| 897 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 898 | talloc_free(mem_ctx);
|
|---|
| 899 | return False;
|
|---|
| 900 | }
|
|---|
| 901 |
|
|---|
| 902 | if (DEBUGLEVEL >= 10)
|
|---|
| 903 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRWORKSTATIONSTATISTICSGET, &r);
|
|---|
| 904 |
|
|---|
| 905 | r.out.result = _WKSSVC_NETRWORKSTATIONSTATISTICSGET(p, &r);
|
|---|
| 906 |
|
|---|
| 907 | if (p->rng_fault_state) {
|
|---|
| 908 | talloc_free(mem_ctx);
|
|---|
| 909 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 910 | return True;
|
|---|
| 911 | }
|
|---|
| 912 |
|
|---|
| 913 | if (DEBUGLEVEL >= 10)
|
|---|
| 914 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRWORKSTATIONSTATISTICSGET, &r);
|
|---|
| 915 |
|
|---|
| 916 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 917 | if (push == NULL) {
|
|---|
| 918 | talloc_free(mem_ctx);
|
|---|
| 919 | return False;
|
|---|
| 920 | }
|
|---|
| 921 |
|
|---|
| 922 | status = ndr_push_WKSSVC_NETRWORKSTATIONSTATISTICSGET(push, NDR_OUT, &r);
|
|---|
| 923 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 924 | talloc_free(mem_ctx);
|
|---|
| 925 | return False;
|
|---|
| 926 | }
|
|---|
| 927 |
|
|---|
| 928 | blob = ndr_push_blob(push);
|
|---|
| 929 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 930 | talloc_free(mem_ctx);
|
|---|
| 931 | return False;
|
|---|
| 932 | }
|
|---|
| 933 |
|
|---|
| 934 | talloc_free(mem_ctx);
|
|---|
| 935 |
|
|---|
| 936 | return True;
|
|---|
| 937 | }
|
|---|
| 938 |
|
|---|
| 939 | static BOOL api_WKSSVC_NETRLOGONDOMAINNAMEADD(pipes_struct *p)
|
|---|
| 940 | {
|
|---|
| 941 | struct ndr_pull *pull;
|
|---|
| 942 | struct ndr_push *push;
|
|---|
| 943 | NTSTATUS status;
|
|---|
| 944 | DATA_BLOB blob;
|
|---|
| 945 | struct WKSSVC_NETRLOGONDOMAINNAMEADD r;
|
|---|
| 946 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRLOGONDOMAINNAMEADD");
|
|---|
| 947 |
|
|---|
| 948 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 949 | talloc_free(mem_ctx);
|
|---|
| 950 | return False;
|
|---|
| 951 | }
|
|---|
| 952 |
|
|---|
| 953 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 954 | if (pull == NULL) {
|
|---|
| 955 | talloc_free(mem_ctx);
|
|---|
| 956 | return False;
|
|---|
| 957 | }
|
|---|
| 958 |
|
|---|
| 959 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 960 | status = ndr_pull_WKSSVC_NETRLOGONDOMAINNAMEADD(pull, NDR_IN, &r);
|
|---|
| 961 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 962 | talloc_free(mem_ctx);
|
|---|
| 963 | return False;
|
|---|
| 964 | }
|
|---|
| 965 |
|
|---|
| 966 | if (DEBUGLEVEL >= 10)
|
|---|
| 967 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRLOGONDOMAINNAMEADD, &r);
|
|---|
| 968 |
|
|---|
| 969 | r.out.result = _WKSSVC_NETRLOGONDOMAINNAMEADD(p, &r);
|
|---|
| 970 |
|
|---|
| 971 | if (p->rng_fault_state) {
|
|---|
| 972 | talloc_free(mem_ctx);
|
|---|
| 973 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 974 | return True;
|
|---|
| 975 | }
|
|---|
| 976 |
|
|---|
| 977 | if (DEBUGLEVEL >= 10)
|
|---|
| 978 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRLOGONDOMAINNAMEADD, &r);
|
|---|
| 979 |
|
|---|
| 980 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 981 | if (push == NULL) {
|
|---|
| 982 | talloc_free(mem_ctx);
|
|---|
| 983 | return False;
|
|---|
| 984 | }
|
|---|
| 985 |
|
|---|
| 986 | status = ndr_push_WKSSVC_NETRLOGONDOMAINNAMEADD(push, NDR_OUT, &r);
|
|---|
| 987 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 988 | talloc_free(mem_ctx);
|
|---|
| 989 | return False;
|
|---|
| 990 | }
|
|---|
| 991 |
|
|---|
| 992 | blob = ndr_push_blob(push);
|
|---|
| 993 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 994 | talloc_free(mem_ctx);
|
|---|
| 995 | return False;
|
|---|
| 996 | }
|
|---|
| 997 |
|
|---|
| 998 | talloc_free(mem_ctx);
|
|---|
| 999 |
|
|---|
| 1000 | return True;
|
|---|
| 1001 | }
|
|---|
| 1002 |
|
|---|
| 1003 | static BOOL api_WKSSVC_NETRLOGONDOMAINNAMEDEL(pipes_struct *p)
|
|---|
| 1004 | {
|
|---|
| 1005 | struct ndr_pull *pull;
|
|---|
| 1006 | struct ndr_push *push;
|
|---|
| 1007 | NTSTATUS status;
|
|---|
| 1008 | DATA_BLOB blob;
|
|---|
| 1009 | struct WKSSVC_NETRLOGONDOMAINNAMEDEL r;
|
|---|
| 1010 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRLOGONDOMAINNAMEDEL");
|
|---|
| 1011 |
|
|---|
| 1012 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 1013 | talloc_free(mem_ctx);
|
|---|
| 1014 | return False;
|
|---|
| 1015 | }
|
|---|
| 1016 |
|
|---|
| 1017 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 1018 | if (pull == NULL) {
|
|---|
| 1019 | talloc_free(mem_ctx);
|
|---|
| 1020 | return False;
|
|---|
| 1021 | }
|
|---|
| 1022 |
|
|---|
| 1023 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 1024 | status = ndr_pull_WKSSVC_NETRLOGONDOMAINNAMEDEL(pull, NDR_IN, &r);
|
|---|
| 1025 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1026 | talloc_free(mem_ctx);
|
|---|
| 1027 | return False;
|
|---|
| 1028 | }
|
|---|
| 1029 |
|
|---|
| 1030 | if (DEBUGLEVEL >= 10)
|
|---|
| 1031 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRLOGONDOMAINNAMEDEL, &r);
|
|---|
| 1032 |
|
|---|
| 1033 | r.out.result = _WKSSVC_NETRLOGONDOMAINNAMEDEL(p, &r);
|
|---|
| 1034 |
|
|---|
| 1035 | if (p->rng_fault_state) {
|
|---|
| 1036 | talloc_free(mem_ctx);
|
|---|
| 1037 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 1038 | return True;
|
|---|
| 1039 | }
|
|---|
| 1040 |
|
|---|
| 1041 | if (DEBUGLEVEL >= 10)
|
|---|
| 1042 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRLOGONDOMAINNAMEDEL, &r);
|
|---|
| 1043 |
|
|---|
| 1044 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 1045 | if (push == NULL) {
|
|---|
| 1046 | talloc_free(mem_ctx);
|
|---|
| 1047 | return False;
|
|---|
| 1048 | }
|
|---|
| 1049 |
|
|---|
| 1050 | status = ndr_push_WKSSVC_NETRLOGONDOMAINNAMEDEL(push, NDR_OUT, &r);
|
|---|
| 1051 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1052 | talloc_free(mem_ctx);
|
|---|
| 1053 | return False;
|
|---|
| 1054 | }
|
|---|
| 1055 |
|
|---|
| 1056 | blob = ndr_push_blob(push);
|
|---|
| 1057 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 1058 | talloc_free(mem_ctx);
|
|---|
| 1059 | return False;
|
|---|
| 1060 | }
|
|---|
| 1061 |
|
|---|
| 1062 | talloc_free(mem_ctx);
|
|---|
| 1063 |
|
|---|
| 1064 | return True;
|
|---|
| 1065 | }
|
|---|
| 1066 |
|
|---|
| 1067 | static BOOL api_WKSSVC_NETRJOINDOMAIN(pipes_struct *p)
|
|---|
| 1068 | {
|
|---|
| 1069 | struct ndr_pull *pull;
|
|---|
| 1070 | struct ndr_push *push;
|
|---|
| 1071 | NTSTATUS status;
|
|---|
| 1072 | DATA_BLOB blob;
|
|---|
| 1073 | struct WKSSVC_NETRJOINDOMAIN r;
|
|---|
| 1074 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRJOINDOMAIN");
|
|---|
| 1075 |
|
|---|
| 1076 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 1077 | talloc_free(mem_ctx);
|
|---|
| 1078 | return False;
|
|---|
| 1079 | }
|
|---|
| 1080 |
|
|---|
| 1081 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 1082 | if (pull == NULL) {
|
|---|
| 1083 | talloc_free(mem_ctx);
|
|---|
| 1084 | return False;
|
|---|
| 1085 | }
|
|---|
| 1086 |
|
|---|
| 1087 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 1088 | status = ndr_pull_WKSSVC_NETRJOINDOMAIN(pull, NDR_IN, &r);
|
|---|
| 1089 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1090 | talloc_free(mem_ctx);
|
|---|
| 1091 | return False;
|
|---|
| 1092 | }
|
|---|
| 1093 |
|
|---|
| 1094 | if (DEBUGLEVEL >= 10)
|
|---|
| 1095 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRJOINDOMAIN, &r);
|
|---|
| 1096 |
|
|---|
| 1097 | r.out.result = _WKSSVC_NETRJOINDOMAIN(p, &r);
|
|---|
| 1098 |
|
|---|
| 1099 | if (p->rng_fault_state) {
|
|---|
| 1100 | talloc_free(mem_ctx);
|
|---|
| 1101 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 1102 | return True;
|
|---|
| 1103 | }
|
|---|
| 1104 |
|
|---|
| 1105 | if (DEBUGLEVEL >= 10)
|
|---|
| 1106 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRJOINDOMAIN, &r);
|
|---|
| 1107 |
|
|---|
| 1108 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 1109 | if (push == NULL) {
|
|---|
| 1110 | talloc_free(mem_ctx);
|
|---|
| 1111 | return False;
|
|---|
| 1112 | }
|
|---|
| 1113 |
|
|---|
| 1114 | status = ndr_push_WKSSVC_NETRJOINDOMAIN(push, NDR_OUT, &r);
|
|---|
| 1115 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1116 | talloc_free(mem_ctx);
|
|---|
| 1117 | return False;
|
|---|
| 1118 | }
|
|---|
| 1119 |
|
|---|
| 1120 | blob = ndr_push_blob(push);
|
|---|
| 1121 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 1122 | talloc_free(mem_ctx);
|
|---|
| 1123 | return False;
|
|---|
| 1124 | }
|
|---|
| 1125 |
|
|---|
| 1126 | talloc_free(mem_ctx);
|
|---|
| 1127 |
|
|---|
| 1128 | return True;
|
|---|
| 1129 | }
|
|---|
| 1130 |
|
|---|
| 1131 | static BOOL api_WKSSVC_NETRUNJOINDOMAIN(pipes_struct *p)
|
|---|
| 1132 | {
|
|---|
| 1133 | struct ndr_pull *pull;
|
|---|
| 1134 | struct ndr_push *push;
|
|---|
| 1135 | NTSTATUS status;
|
|---|
| 1136 | DATA_BLOB blob;
|
|---|
| 1137 | struct WKSSVC_NETRUNJOINDOMAIN r;
|
|---|
| 1138 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRUNJOINDOMAIN");
|
|---|
| 1139 |
|
|---|
| 1140 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 1141 | talloc_free(mem_ctx);
|
|---|
| 1142 | return False;
|
|---|
| 1143 | }
|
|---|
| 1144 |
|
|---|
| 1145 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 1146 | if (pull == NULL) {
|
|---|
| 1147 | talloc_free(mem_ctx);
|
|---|
| 1148 | return False;
|
|---|
| 1149 | }
|
|---|
| 1150 |
|
|---|
| 1151 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 1152 | status = ndr_pull_WKSSVC_NETRUNJOINDOMAIN(pull, NDR_IN, &r);
|
|---|
| 1153 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1154 | talloc_free(mem_ctx);
|
|---|
| 1155 | return False;
|
|---|
| 1156 | }
|
|---|
| 1157 |
|
|---|
| 1158 | if (DEBUGLEVEL >= 10)
|
|---|
| 1159 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRUNJOINDOMAIN, &r);
|
|---|
| 1160 |
|
|---|
| 1161 | r.out.result = _WKSSVC_NETRUNJOINDOMAIN(p, &r);
|
|---|
| 1162 |
|
|---|
| 1163 | if (p->rng_fault_state) {
|
|---|
| 1164 | talloc_free(mem_ctx);
|
|---|
| 1165 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 1166 | return True;
|
|---|
| 1167 | }
|
|---|
| 1168 |
|
|---|
| 1169 | if (DEBUGLEVEL >= 10)
|
|---|
| 1170 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRUNJOINDOMAIN, &r);
|
|---|
| 1171 |
|
|---|
| 1172 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 1173 | if (push == NULL) {
|
|---|
| 1174 | talloc_free(mem_ctx);
|
|---|
| 1175 | return False;
|
|---|
| 1176 | }
|
|---|
| 1177 |
|
|---|
| 1178 | status = ndr_push_WKSSVC_NETRUNJOINDOMAIN(push, NDR_OUT, &r);
|
|---|
| 1179 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1180 | talloc_free(mem_ctx);
|
|---|
| 1181 | return False;
|
|---|
| 1182 | }
|
|---|
| 1183 |
|
|---|
| 1184 | blob = ndr_push_blob(push);
|
|---|
| 1185 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 1186 | talloc_free(mem_ctx);
|
|---|
| 1187 | return False;
|
|---|
| 1188 | }
|
|---|
| 1189 |
|
|---|
| 1190 | talloc_free(mem_ctx);
|
|---|
| 1191 |
|
|---|
| 1192 | return True;
|
|---|
| 1193 | }
|
|---|
| 1194 |
|
|---|
| 1195 | static BOOL api_WKSSVC_NETRRENAMEMACHINEINDOMAIN(pipes_struct *p)
|
|---|
| 1196 | {
|
|---|
| 1197 | struct ndr_pull *pull;
|
|---|
| 1198 | struct ndr_push *push;
|
|---|
| 1199 | NTSTATUS status;
|
|---|
| 1200 | DATA_BLOB blob;
|
|---|
| 1201 | struct WKSSVC_NETRRENAMEMACHINEINDOMAIN r;
|
|---|
| 1202 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRRENAMEMACHINEINDOMAIN");
|
|---|
| 1203 |
|
|---|
| 1204 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 1205 | talloc_free(mem_ctx);
|
|---|
| 1206 | return False;
|
|---|
| 1207 | }
|
|---|
| 1208 |
|
|---|
| 1209 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 1210 | if (pull == NULL) {
|
|---|
| 1211 | talloc_free(mem_ctx);
|
|---|
| 1212 | return False;
|
|---|
| 1213 | }
|
|---|
| 1214 |
|
|---|
| 1215 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 1216 | status = ndr_pull_WKSSVC_NETRRENAMEMACHINEINDOMAIN(pull, NDR_IN, &r);
|
|---|
| 1217 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1218 | talloc_free(mem_ctx);
|
|---|
| 1219 | return False;
|
|---|
| 1220 | }
|
|---|
| 1221 |
|
|---|
| 1222 | if (DEBUGLEVEL >= 10)
|
|---|
| 1223 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRRENAMEMACHINEINDOMAIN, &r);
|
|---|
| 1224 |
|
|---|
| 1225 | r.out.result = _WKSSVC_NETRRENAMEMACHINEINDOMAIN(p, &r);
|
|---|
| 1226 |
|
|---|
| 1227 | if (p->rng_fault_state) {
|
|---|
| 1228 | talloc_free(mem_ctx);
|
|---|
| 1229 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 1230 | return True;
|
|---|
| 1231 | }
|
|---|
| 1232 |
|
|---|
| 1233 | if (DEBUGLEVEL >= 10)
|
|---|
| 1234 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRRENAMEMACHINEINDOMAIN, &r);
|
|---|
| 1235 |
|
|---|
| 1236 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 1237 | if (push == NULL) {
|
|---|
| 1238 | talloc_free(mem_ctx);
|
|---|
| 1239 | return False;
|
|---|
| 1240 | }
|
|---|
| 1241 |
|
|---|
| 1242 | status = ndr_push_WKSSVC_NETRRENAMEMACHINEINDOMAIN(push, NDR_OUT, &r);
|
|---|
| 1243 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1244 | talloc_free(mem_ctx);
|
|---|
| 1245 | return False;
|
|---|
| 1246 | }
|
|---|
| 1247 |
|
|---|
| 1248 | blob = ndr_push_blob(push);
|
|---|
| 1249 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 1250 | talloc_free(mem_ctx);
|
|---|
| 1251 | return False;
|
|---|
| 1252 | }
|
|---|
| 1253 |
|
|---|
| 1254 | talloc_free(mem_ctx);
|
|---|
| 1255 |
|
|---|
| 1256 | return True;
|
|---|
| 1257 | }
|
|---|
| 1258 |
|
|---|
| 1259 | static BOOL api_WKSSVC_NETRVALIDATENAME(pipes_struct *p)
|
|---|
| 1260 | {
|
|---|
| 1261 | struct ndr_pull *pull;
|
|---|
| 1262 | struct ndr_push *push;
|
|---|
| 1263 | NTSTATUS status;
|
|---|
| 1264 | DATA_BLOB blob;
|
|---|
| 1265 | struct WKSSVC_NETRVALIDATENAME r;
|
|---|
| 1266 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRVALIDATENAME");
|
|---|
| 1267 |
|
|---|
| 1268 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 1269 | talloc_free(mem_ctx);
|
|---|
| 1270 | return False;
|
|---|
| 1271 | }
|
|---|
| 1272 |
|
|---|
| 1273 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 1274 | if (pull == NULL) {
|
|---|
| 1275 | talloc_free(mem_ctx);
|
|---|
| 1276 | return False;
|
|---|
| 1277 | }
|
|---|
| 1278 |
|
|---|
| 1279 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 1280 | status = ndr_pull_WKSSVC_NETRVALIDATENAME(pull, NDR_IN, &r);
|
|---|
| 1281 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1282 | talloc_free(mem_ctx);
|
|---|
| 1283 | return False;
|
|---|
| 1284 | }
|
|---|
| 1285 |
|
|---|
| 1286 | if (DEBUGLEVEL >= 10)
|
|---|
| 1287 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRVALIDATENAME, &r);
|
|---|
| 1288 |
|
|---|
| 1289 | r.out.result = _WKSSVC_NETRVALIDATENAME(p, &r);
|
|---|
| 1290 |
|
|---|
| 1291 | if (p->rng_fault_state) {
|
|---|
| 1292 | talloc_free(mem_ctx);
|
|---|
| 1293 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 1294 | return True;
|
|---|
| 1295 | }
|
|---|
| 1296 |
|
|---|
| 1297 | if (DEBUGLEVEL >= 10)
|
|---|
| 1298 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRVALIDATENAME, &r);
|
|---|
| 1299 |
|
|---|
| 1300 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 1301 | if (push == NULL) {
|
|---|
| 1302 | talloc_free(mem_ctx);
|
|---|
| 1303 | return False;
|
|---|
| 1304 | }
|
|---|
| 1305 |
|
|---|
| 1306 | status = ndr_push_WKSSVC_NETRVALIDATENAME(push, NDR_OUT, &r);
|
|---|
| 1307 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1308 | talloc_free(mem_ctx);
|
|---|
| 1309 | return False;
|
|---|
| 1310 | }
|
|---|
| 1311 |
|
|---|
| 1312 | blob = ndr_push_blob(push);
|
|---|
| 1313 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 1314 | talloc_free(mem_ctx);
|
|---|
| 1315 | return False;
|
|---|
| 1316 | }
|
|---|
| 1317 |
|
|---|
| 1318 | talloc_free(mem_ctx);
|
|---|
| 1319 |
|
|---|
| 1320 | return True;
|
|---|
| 1321 | }
|
|---|
| 1322 |
|
|---|
| 1323 | static BOOL api_WKSSVC_NETRGETJOININFORMATION(pipes_struct *p)
|
|---|
| 1324 | {
|
|---|
| 1325 | struct ndr_pull *pull;
|
|---|
| 1326 | struct ndr_push *push;
|
|---|
| 1327 | NTSTATUS status;
|
|---|
| 1328 | DATA_BLOB blob;
|
|---|
| 1329 | struct WKSSVC_NETRGETJOININFORMATION r;
|
|---|
| 1330 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRGETJOININFORMATION");
|
|---|
| 1331 |
|
|---|
| 1332 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 1333 | talloc_free(mem_ctx);
|
|---|
| 1334 | return False;
|
|---|
| 1335 | }
|
|---|
| 1336 |
|
|---|
| 1337 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 1338 | if (pull == NULL) {
|
|---|
| 1339 | talloc_free(mem_ctx);
|
|---|
| 1340 | return False;
|
|---|
| 1341 | }
|
|---|
| 1342 |
|
|---|
| 1343 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 1344 | status = ndr_pull_WKSSVC_NETRGETJOININFORMATION(pull, NDR_IN, &r);
|
|---|
| 1345 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1346 | talloc_free(mem_ctx);
|
|---|
| 1347 | return False;
|
|---|
| 1348 | }
|
|---|
| 1349 |
|
|---|
| 1350 | if (DEBUGLEVEL >= 10)
|
|---|
| 1351 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRGETJOININFORMATION, &r);
|
|---|
| 1352 |
|
|---|
| 1353 | r.out.result = _WKSSVC_NETRGETJOININFORMATION(p, &r);
|
|---|
| 1354 |
|
|---|
| 1355 | if (p->rng_fault_state) {
|
|---|
| 1356 | talloc_free(mem_ctx);
|
|---|
| 1357 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 1358 | return True;
|
|---|
| 1359 | }
|
|---|
| 1360 |
|
|---|
| 1361 | if (DEBUGLEVEL >= 10)
|
|---|
| 1362 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRGETJOININFORMATION, &r);
|
|---|
| 1363 |
|
|---|
| 1364 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 1365 | if (push == NULL) {
|
|---|
| 1366 | talloc_free(mem_ctx);
|
|---|
| 1367 | return False;
|
|---|
| 1368 | }
|
|---|
| 1369 |
|
|---|
| 1370 | status = ndr_push_WKSSVC_NETRGETJOININFORMATION(push, NDR_OUT, &r);
|
|---|
| 1371 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1372 | talloc_free(mem_ctx);
|
|---|
| 1373 | return False;
|
|---|
| 1374 | }
|
|---|
| 1375 |
|
|---|
| 1376 | blob = ndr_push_blob(push);
|
|---|
| 1377 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 1378 | talloc_free(mem_ctx);
|
|---|
| 1379 | return False;
|
|---|
| 1380 | }
|
|---|
| 1381 |
|
|---|
| 1382 | talloc_free(mem_ctx);
|
|---|
| 1383 |
|
|---|
| 1384 | return True;
|
|---|
| 1385 | }
|
|---|
| 1386 |
|
|---|
| 1387 | static BOOL api_WKSSVC_NETRGETJOINABLEOUS(pipes_struct *p)
|
|---|
| 1388 | {
|
|---|
| 1389 | struct ndr_pull *pull;
|
|---|
| 1390 | struct ndr_push *push;
|
|---|
| 1391 | NTSTATUS status;
|
|---|
| 1392 | DATA_BLOB blob;
|
|---|
| 1393 | struct WKSSVC_NETRGETJOINABLEOUS r;
|
|---|
| 1394 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRGETJOINABLEOUS");
|
|---|
| 1395 |
|
|---|
| 1396 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 1397 | talloc_free(mem_ctx);
|
|---|
| 1398 | return False;
|
|---|
| 1399 | }
|
|---|
| 1400 |
|
|---|
| 1401 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 1402 | if (pull == NULL) {
|
|---|
| 1403 | talloc_free(mem_ctx);
|
|---|
| 1404 | return False;
|
|---|
| 1405 | }
|
|---|
| 1406 |
|
|---|
| 1407 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 1408 | status = ndr_pull_WKSSVC_NETRGETJOINABLEOUS(pull, NDR_IN, &r);
|
|---|
| 1409 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1410 | talloc_free(mem_ctx);
|
|---|
| 1411 | return False;
|
|---|
| 1412 | }
|
|---|
| 1413 |
|
|---|
| 1414 | if (DEBUGLEVEL >= 10)
|
|---|
| 1415 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRGETJOINABLEOUS, &r);
|
|---|
| 1416 |
|
|---|
| 1417 | r.out.result = _WKSSVC_NETRGETJOINABLEOUS(p, &r);
|
|---|
| 1418 |
|
|---|
| 1419 | if (p->rng_fault_state) {
|
|---|
| 1420 | talloc_free(mem_ctx);
|
|---|
| 1421 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 1422 | return True;
|
|---|
| 1423 | }
|
|---|
| 1424 |
|
|---|
| 1425 | if (DEBUGLEVEL >= 10)
|
|---|
| 1426 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRGETJOINABLEOUS, &r);
|
|---|
| 1427 |
|
|---|
| 1428 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 1429 | if (push == NULL) {
|
|---|
| 1430 | talloc_free(mem_ctx);
|
|---|
| 1431 | return False;
|
|---|
| 1432 | }
|
|---|
| 1433 |
|
|---|
| 1434 | status = ndr_push_WKSSVC_NETRGETJOINABLEOUS(push, NDR_OUT, &r);
|
|---|
| 1435 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1436 | talloc_free(mem_ctx);
|
|---|
| 1437 | return False;
|
|---|
| 1438 | }
|
|---|
| 1439 |
|
|---|
| 1440 | blob = ndr_push_blob(push);
|
|---|
| 1441 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 1442 | talloc_free(mem_ctx);
|
|---|
| 1443 | return False;
|
|---|
| 1444 | }
|
|---|
| 1445 |
|
|---|
| 1446 | talloc_free(mem_ctx);
|
|---|
| 1447 |
|
|---|
| 1448 | return True;
|
|---|
| 1449 | }
|
|---|
| 1450 |
|
|---|
| 1451 | static BOOL api_wkssvc_NetrJoinDomain2(pipes_struct *p)
|
|---|
| 1452 | {
|
|---|
| 1453 | struct ndr_pull *pull;
|
|---|
| 1454 | struct ndr_push *push;
|
|---|
| 1455 | NTSTATUS status;
|
|---|
| 1456 | DATA_BLOB blob;
|
|---|
| 1457 | struct wkssvc_NetrJoinDomain2 r;
|
|---|
| 1458 | TALLOC_CTX *mem_ctx = talloc_init("api_wkssvc_NetrJoinDomain2");
|
|---|
| 1459 |
|
|---|
| 1460 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 1461 | talloc_free(mem_ctx);
|
|---|
| 1462 | return False;
|
|---|
| 1463 | }
|
|---|
| 1464 |
|
|---|
| 1465 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 1466 | if (pull == NULL) {
|
|---|
| 1467 | talloc_free(mem_ctx);
|
|---|
| 1468 | return False;
|
|---|
| 1469 | }
|
|---|
| 1470 |
|
|---|
| 1471 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 1472 | status = ndr_pull_wkssvc_NetrJoinDomain2(pull, NDR_IN, &r);
|
|---|
| 1473 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1474 | talloc_free(mem_ctx);
|
|---|
| 1475 | return False;
|
|---|
| 1476 | }
|
|---|
| 1477 |
|
|---|
| 1478 | if (DEBUGLEVEL >= 10)
|
|---|
| 1479 | NDR_PRINT_IN_DEBUG(wkssvc_NetrJoinDomain2, &r);
|
|---|
| 1480 |
|
|---|
| 1481 | r.out.result = _wkssvc_NetrJoinDomain2(p, &r);
|
|---|
| 1482 |
|
|---|
| 1483 | if (p->rng_fault_state) {
|
|---|
| 1484 | talloc_free(mem_ctx);
|
|---|
| 1485 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 1486 | return True;
|
|---|
| 1487 | }
|
|---|
| 1488 |
|
|---|
| 1489 | if (DEBUGLEVEL >= 10)
|
|---|
| 1490 | NDR_PRINT_OUT_DEBUG(wkssvc_NetrJoinDomain2, &r);
|
|---|
| 1491 |
|
|---|
| 1492 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 1493 | if (push == NULL) {
|
|---|
| 1494 | talloc_free(mem_ctx);
|
|---|
| 1495 | return False;
|
|---|
| 1496 | }
|
|---|
| 1497 |
|
|---|
| 1498 | status = ndr_push_wkssvc_NetrJoinDomain2(push, NDR_OUT, &r);
|
|---|
| 1499 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1500 | talloc_free(mem_ctx);
|
|---|
| 1501 | return False;
|
|---|
| 1502 | }
|
|---|
| 1503 |
|
|---|
| 1504 | blob = ndr_push_blob(push);
|
|---|
| 1505 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 1506 | talloc_free(mem_ctx);
|
|---|
| 1507 | return False;
|
|---|
| 1508 | }
|
|---|
| 1509 |
|
|---|
| 1510 | talloc_free(mem_ctx);
|
|---|
| 1511 |
|
|---|
| 1512 | return True;
|
|---|
| 1513 | }
|
|---|
| 1514 |
|
|---|
| 1515 | static BOOL api_wkssvc_NetrUnjoinDomain2(pipes_struct *p)
|
|---|
| 1516 | {
|
|---|
| 1517 | struct ndr_pull *pull;
|
|---|
| 1518 | struct ndr_push *push;
|
|---|
| 1519 | NTSTATUS status;
|
|---|
| 1520 | DATA_BLOB blob;
|
|---|
| 1521 | struct wkssvc_NetrUnjoinDomain2 r;
|
|---|
| 1522 | TALLOC_CTX *mem_ctx = talloc_init("api_wkssvc_NetrUnjoinDomain2");
|
|---|
| 1523 |
|
|---|
| 1524 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 1525 | talloc_free(mem_ctx);
|
|---|
| 1526 | return False;
|
|---|
| 1527 | }
|
|---|
| 1528 |
|
|---|
| 1529 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 1530 | if (pull == NULL) {
|
|---|
| 1531 | talloc_free(mem_ctx);
|
|---|
| 1532 | return False;
|
|---|
| 1533 | }
|
|---|
| 1534 |
|
|---|
| 1535 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 1536 | status = ndr_pull_wkssvc_NetrUnjoinDomain2(pull, NDR_IN, &r);
|
|---|
| 1537 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1538 | talloc_free(mem_ctx);
|
|---|
| 1539 | return False;
|
|---|
| 1540 | }
|
|---|
| 1541 |
|
|---|
| 1542 | if (DEBUGLEVEL >= 10)
|
|---|
| 1543 | NDR_PRINT_IN_DEBUG(wkssvc_NetrUnjoinDomain2, &r);
|
|---|
| 1544 |
|
|---|
| 1545 | r.out.result = _wkssvc_NetrUnjoinDomain2(p, &r);
|
|---|
| 1546 |
|
|---|
| 1547 | if (p->rng_fault_state) {
|
|---|
| 1548 | talloc_free(mem_ctx);
|
|---|
| 1549 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 1550 | return True;
|
|---|
| 1551 | }
|
|---|
| 1552 |
|
|---|
| 1553 | if (DEBUGLEVEL >= 10)
|
|---|
| 1554 | NDR_PRINT_OUT_DEBUG(wkssvc_NetrUnjoinDomain2, &r);
|
|---|
| 1555 |
|
|---|
| 1556 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 1557 | if (push == NULL) {
|
|---|
| 1558 | talloc_free(mem_ctx);
|
|---|
| 1559 | return False;
|
|---|
| 1560 | }
|
|---|
| 1561 |
|
|---|
| 1562 | status = ndr_push_wkssvc_NetrUnjoinDomain2(push, NDR_OUT, &r);
|
|---|
| 1563 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1564 | talloc_free(mem_ctx);
|
|---|
| 1565 | return False;
|
|---|
| 1566 | }
|
|---|
| 1567 |
|
|---|
| 1568 | blob = ndr_push_blob(push);
|
|---|
| 1569 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 1570 | talloc_free(mem_ctx);
|
|---|
| 1571 | return False;
|
|---|
| 1572 | }
|
|---|
| 1573 |
|
|---|
| 1574 | talloc_free(mem_ctx);
|
|---|
| 1575 |
|
|---|
| 1576 | return True;
|
|---|
| 1577 | }
|
|---|
| 1578 |
|
|---|
| 1579 | static BOOL api_wkssvc_NetrRenameMachineInDomain2(pipes_struct *p)
|
|---|
| 1580 | {
|
|---|
| 1581 | struct ndr_pull *pull;
|
|---|
| 1582 | struct ndr_push *push;
|
|---|
| 1583 | NTSTATUS status;
|
|---|
| 1584 | DATA_BLOB blob;
|
|---|
| 1585 | struct wkssvc_NetrRenameMachineInDomain2 r;
|
|---|
| 1586 | TALLOC_CTX *mem_ctx = talloc_init("api_wkssvc_NetrRenameMachineInDomain2");
|
|---|
| 1587 |
|
|---|
| 1588 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 1589 | talloc_free(mem_ctx);
|
|---|
| 1590 | return False;
|
|---|
| 1591 | }
|
|---|
| 1592 |
|
|---|
| 1593 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 1594 | if (pull == NULL) {
|
|---|
| 1595 | talloc_free(mem_ctx);
|
|---|
| 1596 | return False;
|
|---|
| 1597 | }
|
|---|
| 1598 |
|
|---|
| 1599 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 1600 | status = ndr_pull_wkssvc_NetrRenameMachineInDomain2(pull, NDR_IN, &r);
|
|---|
| 1601 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1602 | talloc_free(mem_ctx);
|
|---|
| 1603 | return False;
|
|---|
| 1604 | }
|
|---|
| 1605 |
|
|---|
| 1606 | if (DEBUGLEVEL >= 10)
|
|---|
| 1607 | NDR_PRINT_IN_DEBUG(wkssvc_NetrRenameMachineInDomain2, &r);
|
|---|
| 1608 |
|
|---|
| 1609 | r.out.result = _wkssvc_NetrRenameMachineInDomain2(p, &r);
|
|---|
| 1610 |
|
|---|
| 1611 | if (p->rng_fault_state) {
|
|---|
| 1612 | talloc_free(mem_ctx);
|
|---|
| 1613 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 1614 | return True;
|
|---|
| 1615 | }
|
|---|
| 1616 |
|
|---|
| 1617 | if (DEBUGLEVEL >= 10)
|
|---|
| 1618 | NDR_PRINT_OUT_DEBUG(wkssvc_NetrRenameMachineInDomain2, &r);
|
|---|
| 1619 |
|
|---|
| 1620 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 1621 | if (push == NULL) {
|
|---|
| 1622 | talloc_free(mem_ctx);
|
|---|
| 1623 | return False;
|
|---|
| 1624 | }
|
|---|
| 1625 |
|
|---|
| 1626 | status = ndr_push_wkssvc_NetrRenameMachineInDomain2(push, NDR_OUT, &r);
|
|---|
| 1627 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1628 | talloc_free(mem_ctx);
|
|---|
| 1629 | return False;
|
|---|
| 1630 | }
|
|---|
| 1631 |
|
|---|
| 1632 | blob = ndr_push_blob(push);
|
|---|
| 1633 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 1634 | talloc_free(mem_ctx);
|
|---|
| 1635 | return False;
|
|---|
| 1636 | }
|
|---|
| 1637 |
|
|---|
| 1638 | talloc_free(mem_ctx);
|
|---|
| 1639 |
|
|---|
| 1640 | return True;
|
|---|
| 1641 | }
|
|---|
| 1642 |
|
|---|
| 1643 | static BOOL api_WKSSVC_NETRVALIDATENAME2(pipes_struct *p)
|
|---|
| 1644 | {
|
|---|
| 1645 | struct ndr_pull *pull;
|
|---|
| 1646 | struct ndr_push *push;
|
|---|
| 1647 | NTSTATUS status;
|
|---|
| 1648 | DATA_BLOB blob;
|
|---|
| 1649 | struct WKSSVC_NETRVALIDATENAME2 r;
|
|---|
| 1650 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRVALIDATENAME2");
|
|---|
| 1651 |
|
|---|
| 1652 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 1653 | talloc_free(mem_ctx);
|
|---|
| 1654 | return False;
|
|---|
| 1655 | }
|
|---|
| 1656 |
|
|---|
| 1657 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 1658 | if (pull == NULL) {
|
|---|
| 1659 | talloc_free(mem_ctx);
|
|---|
| 1660 | return False;
|
|---|
| 1661 | }
|
|---|
| 1662 |
|
|---|
| 1663 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 1664 | status = ndr_pull_WKSSVC_NETRVALIDATENAME2(pull, NDR_IN, &r);
|
|---|
| 1665 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1666 | talloc_free(mem_ctx);
|
|---|
| 1667 | return False;
|
|---|
| 1668 | }
|
|---|
| 1669 |
|
|---|
| 1670 | if (DEBUGLEVEL >= 10)
|
|---|
| 1671 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRVALIDATENAME2, &r);
|
|---|
| 1672 |
|
|---|
| 1673 | r.out.result = _WKSSVC_NETRVALIDATENAME2(p, &r);
|
|---|
| 1674 |
|
|---|
| 1675 | if (p->rng_fault_state) {
|
|---|
| 1676 | talloc_free(mem_ctx);
|
|---|
| 1677 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 1678 | return True;
|
|---|
| 1679 | }
|
|---|
| 1680 |
|
|---|
| 1681 | if (DEBUGLEVEL >= 10)
|
|---|
| 1682 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRVALIDATENAME2, &r);
|
|---|
| 1683 |
|
|---|
| 1684 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 1685 | if (push == NULL) {
|
|---|
| 1686 | talloc_free(mem_ctx);
|
|---|
| 1687 | return False;
|
|---|
| 1688 | }
|
|---|
| 1689 |
|
|---|
| 1690 | status = ndr_push_WKSSVC_NETRVALIDATENAME2(push, NDR_OUT, &r);
|
|---|
| 1691 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1692 | talloc_free(mem_ctx);
|
|---|
| 1693 | return False;
|
|---|
| 1694 | }
|
|---|
| 1695 |
|
|---|
| 1696 | blob = ndr_push_blob(push);
|
|---|
| 1697 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 1698 | talloc_free(mem_ctx);
|
|---|
| 1699 | return False;
|
|---|
| 1700 | }
|
|---|
| 1701 |
|
|---|
| 1702 | talloc_free(mem_ctx);
|
|---|
| 1703 |
|
|---|
| 1704 | return True;
|
|---|
| 1705 | }
|
|---|
| 1706 |
|
|---|
| 1707 | static BOOL api_WKSSVC_NETRGETJOINABLEOUS2(pipes_struct *p)
|
|---|
| 1708 | {
|
|---|
| 1709 | struct ndr_pull *pull;
|
|---|
| 1710 | struct ndr_push *push;
|
|---|
| 1711 | NTSTATUS status;
|
|---|
| 1712 | DATA_BLOB blob;
|
|---|
| 1713 | struct WKSSVC_NETRGETJOINABLEOUS2 r;
|
|---|
| 1714 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRGETJOINABLEOUS2");
|
|---|
| 1715 |
|
|---|
| 1716 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 1717 | talloc_free(mem_ctx);
|
|---|
| 1718 | return False;
|
|---|
| 1719 | }
|
|---|
| 1720 |
|
|---|
| 1721 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 1722 | if (pull == NULL) {
|
|---|
| 1723 | talloc_free(mem_ctx);
|
|---|
| 1724 | return False;
|
|---|
| 1725 | }
|
|---|
| 1726 |
|
|---|
| 1727 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 1728 | status = ndr_pull_WKSSVC_NETRGETJOINABLEOUS2(pull, NDR_IN, &r);
|
|---|
| 1729 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1730 | talloc_free(mem_ctx);
|
|---|
| 1731 | return False;
|
|---|
| 1732 | }
|
|---|
| 1733 |
|
|---|
| 1734 | if (DEBUGLEVEL >= 10)
|
|---|
| 1735 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRGETJOINABLEOUS2, &r);
|
|---|
| 1736 |
|
|---|
| 1737 | r.out.result = _WKSSVC_NETRGETJOINABLEOUS2(p, &r);
|
|---|
| 1738 |
|
|---|
| 1739 | if (p->rng_fault_state) {
|
|---|
| 1740 | talloc_free(mem_ctx);
|
|---|
| 1741 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 1742 | return True;
|
|---|
| 1743 | }
|
|---|
| 1744 |
|
|---|
| 1745 | if (DEBUGLEVEL >= 10)
|
|---|
| 1746 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRGETJOINABLEOUS2, &r);
|
|---|
| 1747 |
|
|---|
| 1748 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 1749 | if (push == NULL) {
|
|---|
| 1750 | talloc_free(mem_ctx);
|
|---|
| 1751 | return False;
|
|---|
| 1752 | }
|
|---|
| 1753 |
|
|---|
| 1754 | status = ndr_push_WKSSVC_NETRGETJOINABLEOUS2(push, NDR_OUT, &r);
|
|---|
| 1755 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1756 | talloc_free(mem_ctx);
|
|---|
| 1757 | return False;
|
|---|
| 1758 | }
|
|---|
| 1759 |
|
|---|
| 1760 | blob = ndr_push_blob(push);
|
|---|
| 1761 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 1762 | talloc_free(mem_ctx);
|
|---|
| 1763 | return False;
|
|---|
| 1764 | }
|
|---|
| 1765 |
|
|---|
| 1766 | talloc_free(mem_ctx);
|
|---|
| 1767 |
|
|---|
| 1768 | return True;
|
|---|
| 1769 | }
|
|---|
| 1770 |
|
|---|
| 1771 | static BOOL api_wkssvc_NetrAddAlternateComputerName(pipes_struct *p)
|
|---|
| 1772 | {
|
|---|
| 1773 | struct ndr_pull *pull;
|
|---|
| 1774 | struct ndr_push *push;
|
|---|
| 1775 | NTSTATUS status;
|
|---|
| 1776 | DATA_BLOB blob;
|
|---|
| 1777 | struct wkssvc_NetrAddAlternateComputerName r;
|
|---|
| 1778 | TALLOC_CTX *mem_ctx = talloc_init("api_wkssvc_NetrAddAlternateComputerName");
|
|---|
| 1779 |
|
|---|
| 1780 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 1781 | talloc_free(mem_ctx);
|
|---|
| 1782 | return False;
|
|---|
| 1783 | }
|
|---|
| 1784 |
|
|---|
| 1785 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 1786 | if (pull == NULL) {
|
|---|
| 1787 | talloc_free(mem_ctx);
|
|---|
| 1788 | return False;
|
|---|
| 1789 | }
|
|---|
| 1790 |
|
|---|
| 1791 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 1792 | status = ndr_pull_wkssvc_NetrAddAlternateComputerName(pull, NDR_IN, &r);
|
|---|
| 1793 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1794 | talloc_free(mem_ctx);
|
|---|
| 1795 | return False;
|
|---|
| 1796 | }
|
|---|
| 1797 |
|
|---|
| 1798 | if (DEBUGLEVEL >= 10)
|
|---|
| 1799 | NDR_PRINT_IN_DEBUG(wkssvc_NetrAddAlternateComputerName, &r);
|
|---|
| 1800 |
|
|---|
| 1801 | r.out.result = _wkssvc_NetrAddAlternateComputerName(p, &r);
|
|---|
| 1802 |
|
|---|
| 1803 | if (p->rng_fault_state) {
|
|---|
| 1804 | talloc_free(mem_ctx);
|
|---|
| 1805 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 1806 | return True;
|
|---|
| 1807 | }
|
|---|
| 1808 |
|
|---|
| 1809 | if (DEBUGLEVEL >= 10)
|
|---|
| 1810 | NDR_PRINT_OUT_DEBUG(wkssvc_NetrAddAlternateComputerName, &r);
|
|---|
| 1811 |
|
|---|
| 1812 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 1813 | if (push == NULL) {
|
|---|
| 1814 | talloc_free(mem_ctx);
|
|---|
| 1815 | return False;
|
|---|
| 1816 | }
|
|---|
| 1817 |
|
|---|
| 1818 | status = ndr_push_wkssvc_NetrAddAlternateComputerName(push, NDR_OUT, &r);
|
|---|
| 1819 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1820 | talloc_free(mem_ctx);
|
|---|
| 1821 | return False;
|
|---|
| 1822 | }
|
|---|
| 1823 |
|
|---|
| 1824 | blob = ndr_push_blob(push);
|
|---|
| 1825 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 1826 | talloc_free(mem_ctx);
|
|---|
| 1827 | return False;
|
|---|
| 1828 | }
|
|---|
| 1829 |
|
|---|
| 1830 | talloc_free(mem_ctx);
|
|---|
| 1831 |
|
|---|
| 1832 | return True;
|
|---|
| 1833 | }
|
|---|
| 1834 |
|
|---|
| 1835 | static BOOL api_wkssvc_NetrRemoveAlternateComputerName(pipes_struct *p)
|
|---|
| 1836 | {
|
|---|
| 1837 | struct ndr_pull *pull;
|
|---|
| 1838 | struct ndr_push *push;
|
|---|
| 1839 | NTSTATUS status;
|
|---|
| 1840 | DATA_BLOB blob;
|
|---|
| 1841 | struct wkssvc_NetrRemoveAlternateComputerName r;
|
|---|
| 1842 | TALLOC_CTX *mem_ctx = talloc_init("api_wkssvc_NetrRemoveAlternateComputerName");
|
|---|
| 1843 |
|
|---|
| 1844 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 1845 | talloc_free(mem_ctx);
|
|---|
| 1846 | return False;
|
|---|
| 1847 | }
|
|---|
| 1848 |
|
|---|
| 1849 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 1850 | if (pull == NULL) {
|
|---|
| 1851 | talloc_free(mem_ctx);
|
|---|
| 1852 | return False;
|
|---|
| 1853 | }
|
|---|
| 1854 |
|
|---|
| 1855 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 1856 | status = ndr_pull_wkssvc_NetrRemoveAlternateComputerName(pull, NDR_IN, &r);
|
|---|
| 1857 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1858 | talloc_free(mem_ctx);
|
|---|
| 1859 | return False;
|
|---|
| 1860 | }
|
|---|
| 1861 |
|
|---|
| 1862 | if (DEBUGLEVEL >= 10)
|
|---|
| 1863 | NDR_PRINT_IN_DEBUG(wkssvc_NetrRemoveAlternateComputerName, &r);
|
|---|
| 1864 |
|
|---|
| 1865 | r.out.result = _wkssvc_NetrRemoveAlternateComputerName(p, &r);
|
|---|
| 1866 |
|
|---|
| 1867 | if (p->rng_fault_state) {
|
|---|
| 1868 | talloc_free(mem_ctx);
|
|---|
| 1869 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 1870 | return True;
|
|---|
| 1871 | }
|
|---|
| 1872 |
|
|---|
| 1873 | if (DEBUGLEVEL >= 10)
|
|---|
| 1874 | NDR_PRINT_OUT_DEBUG(wkssvc_NetrRemoveAlternateComputerName, &r);
|
|---|
| 1875 |
|
|---|
| 1876 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 1877 | if (push == NULL) {
|
|---|
| 1878 | talloc_free(mem_ctx);
|
|---|
| 1879 | return False;
|
|---|
| 1880 | }
|
|---|
| 1881 |
|
|---|
| 1882 | status = ndr_push_wkssvc_NetrRemoveAlternateComputerName(push, NDR_OUT, &r);
|
|---|
| 1883 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1884 | talloc_free(mem_ctx);
|
|---|
| 1885 | return False;
|
|---|
| 1886 | }
|
|---|
| 1887 |
|
|---|
| 1888 | blob = ndr_push_blob(push);
|
|---|
| 1889 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 1890 | talloc_free(mem_ctx);
|
|---|
| 1891 | return False;
|
|---|
| 1892 | }
|
|---|
| 1893 |
|
|---|
| 1894 | talloc_free(mem_ctx);
|
|---|
| 1895 |
|
|---|
| 1896 | return True;
|
|---|
| 1897 | }
|
|---|
| 1898 |
|
|---|
| 1899 | static BOOL api_WKSSVC_NETRSETPRIMARYCOMPUTERNAME(pipes_struct *p)
|
|---|
| 1900 | {
|
|---|
| 1901 | struct ndr_pull *pull;
|
|---|
| 1902 | struct ndr_push *push;
|
|---|
| 1903 | NTSTATUS status;
|
|---|
| 1904 | DATA_BLOB blob;
|
|---|
| 1905 | struct WKSSVC_NETRSETPRIMARYCOMPUTERNAME r;
|
|---|
| 1906 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRSETPRIMARYCOMPUTERNAME");
|
|---|
| 1907 |
|
|---|
| 1908 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 1909 | talloc_free(mem_ctx);
|
|---|
| 1910 | return False;
|
|---|
| 1911 | }
|
|---|
| 1912 |
|
|---|
| 1913 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 1914 | if (pull == NULL) {
|
|---|
| 1915 | talloc_free(mem_ctx);
|
|---|
| 1916 | return False;
|
|---|
| 1917 | }
|
|---|
| 1918 |
|
|---|
| 1919 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 1920 | status = ndr_pull_WKSSVC_NETRSETPRIMARYCOMPUTERNAME(pull, NDR_IN, &r);
|
|---|
| 1921 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1922 | talloc_free(mem_ctx);
|
|---|
| 1923 | return False;
|
|---|
| 1924 | }
|
|---|
| 1925 |
|
|---|
| 1926 | if (DEBUGLEVEL >= 10)
|
|---|
| 1927 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRSETPRIMARYCOMPUTERNAME, &r);
|
|---|
| 1928 |
|
|---|
| 1929 | r.out.result = _WKSSVC_NETRSETPRIMARYCOMPUTERNAME(p, &r);
|
|---|
| 1930 |
|
|---|
| 1931 | if (p->rng_fault_state) {
|
|---|
| 1932 | talloc_free(mem_ctx);
|
|---|
| 1933 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 1934 | return True;
|
|---|
| 1935 | }
|
|---|
| 1936 |
|
|---|
| 1937 | if (DEBUGLEVEL >= 10)
|
|---|
| 1938 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRSETPRIMARYCOMPUTERNAME, &r);
|
|---|
| 1939 |
|
|---|
| 1940 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 1941 | if (push == NULL) {
|
|---|
| 1942 | talloc_free(mem_ctx);
|
|---|
| 1943 | return False;
|
|---|
| 1944 | }
|
|---|
| 1945 |
|
|---|
| 1946 | status = ndr_push_WKSSVC_NETRSETPRIMARYCOMPUTERNAME(push, NDR_OUT, &r);
|
|---|
| 1947 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1948 | talloc_free(mem_ctx);
|
|---|
| 1949 | return False;
|
|---|
| 1950 | }
|
|---|
| 1951 |
|
|---|
| 1952 | blob = ndr_push_blob(push);
|
|---|
| 1953 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 1954 | talloc_free(mem_ctx);
|
|---|
| 1955 | return False;
|
|---|
| 1956 | }
|
|---|
| 1957 |
|
|---|
| 1958 | talloc_free(mem_ctx);
|
|---|
| 1959 |
|
|---|
| 1960 | return True;
|
|---|
| 1961 | }
|
|---|
| 1962 |
|
|---|
| 1963 | static BOOL api_WKSSVC_NETRENUMERATECOMPUTERNAMES(pipes_struct *p)
|
|---|
| 1964 | {
|
|---|
| 1965 | struct ndr_pull *pull;
|
|---|
| 1966 | struct ndr_push *push;
|
|---|
| 1967 | NTSTATUS status;
|
|---|
| 1968 | DATA_BLOB blob;
|
|---|
| 1969 | struct WKSSVC_NETRENUMERATECOMPUTERNAMES r;
|
|---|
| 1970 | TALLOC_CTX *mem_ctx = talloc_init("api_WKSSVC_NETRENUMERATECOMPUTERNAMES");
|
|---|
| 1971 |
|
|---|
| 1972 | if (!prs_data_blob(&p->in_data.data, &blob, mem_ctx)) {
|
|---|
| 1973 | talloc_free(mem_ctx);
|
|---|
| 1974 | return False;
|
|---|
| 1975 | }
|
|---|
| 1976 |
|
|---|
| 1977 | pull = ndr_pull_init_blob(&blob, mem_ctx);
|
|---|
| 1978 | if (pull == NULL) {
|
|---|
| 1979 | talloc_free(mem_ctx);
|
|---|
| 1980 | return False;
|
|---|
| 1981 | }
|
|---|
| 1982 |
|
|---|
| 1983 | pull->flags |= LIBNDR_FLAG_REF_ALLOC;
|
|---|
| 1984 | status = ndr_pull_WKSSVC_NETRENUMERATECOMPUTERNAMES(pull, NDR_IN, &r);
|
|---|
| 1985 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 1986 | talloc_free(mem_ctx);
|
|---|
| 1987 | return False;
|
|---|
| 1988 | }
|
|---|
| 1989 |
|
|---|
| 1990 | if (DEBUGLEVEL >= 10)
|
|---|
| 1991 | NDR_PRINT_IN_DEBUG(WKSSVC_NETRENUMERATECOMPUTERNAMES, &r);
|
|---|
| 1992 |
|
|---|
| 1993 | r.out.result = _WKSSVC_NETRENUMERATECOMPUTERNAMES(p, &r);
|
|---|
| 1994 |
|
|---|
| 1995 | if (p->rng_fault_state) {
|
|---|
| 1996 | talloc_free(mem_ctx);
|
|---|
| 1997 | /* Return True here, srv_pipe_hnd.c will take care */
|
|---|
| 1998 | return True;
|
|---|
| 1999 | }
|
|---|
| 2000 |
|
|---|
| 2001 | if (DEBUGLEVEL >= 10)
|
|---|
| 2002 | NDR_PRINT_OUT_DEBUG(WKSSVC_NETRENUMERATECOMPUTERNAMES, &r);
|
|---|
| 2003 |
|
|---|
| 2004 | push = ndr_push_init_ctx(mem_ctx);
|
|---|
| 2005 | if (push == NULL) {
|
|---|
| 2006 | talloc_free(mem_ctx);
|
|---|
| 2007 | return False;
|
|---|
| 2008 | }
|
|---|
| 2009 |
|
|---|
| 2010 | status = ndr_push_WKSSVC_NETRENUMERATECOMPUTERNAMES(push, NDR_OUT, &r);
|
|---|
| 2011 | if (NT_STATUS_IS_ERR(status)) {
|
|---|
| 2012 | talloc_free(mem_ctx);
|
|---|
| 2013 | return False;
|
|---|
| 2014 | }
|
|---|
| 2015 |
|
|---|
| 2016 | blob = ndr_push_blob(push);
|
|---|
| 2017 | if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32)blob.length)) {
|
|---|
| 2018 | talloc_free(mem_ctx);
|
|---|
| 2019 | return False;
|
|---|
| 2020 | }
|
|---|
| 2021 |
|
|---|
| 2022 | talloc_free(mem_ctx);
|
|---|
| 2023 |
|
|---|
| 2024 | return True;
|
|---|
| 2025 | }
|
|---|
| 2026 |
|
|---|
| 2027 |
|
|---|
| 2028 | /* Tables */
|
|---|
| 2029 | static struct api_struct api_wkssvc_cmds[] =
|
|---|
| 2030 | {
|
|---|
| 2031 | {"WKSSVC_NETWKSTAGETINFO", DCERPC_WKSSVC_NETWKSTAGETINFO, api_wkssvc_NetWkstaGetInfo},
|
|---|
| 2032 | {"WKSSVC_NETWKSTASETINFO", DCERPC_WKSSVC_NETWKSTASETINFO, api_wkssvc_NetWkstaSetInfo},
|
|---|
| 2033 | {"WKSSVC_NETWKSTAENUMUSERS", DCERPC_WKSSVC_NETWKSTAENUMUSERS, api_wkssvc_NetWkstaEnumUsers},
|
|---|
| 2034 | {"WKSSVC_NETRWKSTAUSERGETINFO", DCERPC_WKSSVC_NETRWKSTAUSERGETINFO, api_WKSSVC_NETRWKSTAUSERGETINFO},
|
|---|
| 2035 | {"WKSSVC_NETRWKSTAUSERSETINFO", DCERPC_WKSSVC_NETRWKSTAUSERSETINFO, api_WKSSVC_NETRWKSTAUSERSETINFO},
|
|---|
| 2036 | {"WKSSVC_NETWKSTATRANSPORTENUM", DCERPC_WKSSVC_NETWKSTATRANSPORTENUM, api_wkssvc_NetWkstaTransportEnum},
|
|---|
| 2037 | {"WKSSVC_NETRWKSTATRANSPORTADD", DCERPC_WKSSVC_NETRWKSTATRANSPORTADD, api_WKSSVC_NETRWKSTATRANSPORTADD},
|
|---|
| 2038 | {"WKSSVC_NETRWKSTATRANSPORTDEL", DCERPC_WKSSVC_NETRWKSTATRANSPORTDEL, api_WKSSVC_NETRWKSTATRANSPORTDEL},
|
|---|
| 2039 | {"WKSSVC_NETRUSEADD", DCERPC_WKSSVC_NETRUSEADD, api_WKSSVC_NETRUSEADD},
|
|---|
| 2040 | {"WKSSVC_NETRUSEGETINFO", DCERPC_WKSSVC_NETRUSEGETINFO, api_WKSSVC_NETRUSEGETINFO},
|
|---|
| 2041 | {"WKSSVC_NETRUSEDEL", DCERPC_WKSSVC_NETRUSEDEL, api_WKSSVC_NETRUSEDEL},
|
|---|
| 2042 | {"WKSSVC_NETRUSEENUM", DCERPC_WKSSVC_NETRUSEENUM, api_WKSSVC_NETRUSEENUM},
|
|---|
| 2043 | {"WKSSVC_NETRMESSAGEBUFFERSEND", DCERPC_WKSSVC_NETRMESSAGEBUFFERSEND, api_WKSSVC_NETRMESSAGEBUFFERSEND},
|
|---|
| 2044 | {"WKSSVC_NETRWORKSTATIONSTATISTICSGET", DCERPC_WKSSVC_NETRWORKSTATIONSTATISTICSGET, api_WKSSVC_NETRWORKSTATIONSTATISTICSGET},
|
|---|
| 2045 | {"WKSSVC_NETRLOGONDOMAINNAMEADD", DCERPC_WKSSVC_NETRLOGONDOMAINNAMEADD, api_WKSSVC_NETRLOGONDOMAINNAMEADD},
|
|---|
| 2046 | {"WKSSVC_NETRLOGONDOMAINNAMEDEL", DCERPC_WKSSVC_NETRLOGONDOMAINNAMEDEL, api_WKSSVC_NETRLOGONDOMAINNAMEDEL},
|
|---|
| 2047 | {"WKSSVC_NETRJOINDOMAIN", DCERPC_WKSSVC_NETRJOINDOMAIN, api_WKSSVC_NETRJOINDOMAIN},
|
|---|
| 2048 | {"WKSSVC_NETRUNJOINDOMAIN", DCERPC_WKSSVC_NETRUNJOINDOMAIN, api_WKSSVC_NETRUNJOINDOMAIN},
|
|---|
| 2049 | {"WKSSVC_NETRRENAMEMACHINEINDOMAIN", DCERPC_WKSSVC_NETRRENAMEMACHINEINDOMAIN, api_WKSSVC_NETRRENAMEMACHINEINDOMAIN},
|
|---|
| 2050 | {"WKSSVC_NETRVALIDATENAME", DCERPC_WKSSVC_NETRVALIDATENAME, api_WKSSVC_NETRVALIDATENAME},
|
|---|
| 2051 | {"WKSSVC_NETRGETJOININFORMATION", DCERPC_WKSSVC_NETRGETJOININFORMATION, api_WKSSVC_NETRGETJOININFORMATION},
|
|---|
| 2052 | {"WKSSVC_NETRGETJOINABLEOUS", DCERPC_WKSSVC_NETRGETJOINABLEOUS, api_WKSSVC_NETRGETJOINABLEOUS},
|
|---|
| 2053 | {"WKSSVC_NETRJOINDOMAIN2", DCERPC_WKSSVC_NETRJOINDOMAIN2, api_wkssvc_NetrJoinDomain2},
|
|---|
| 2054 | {"WKSSVC_NETRUNJOINDOMAIN2", DCERPC_WKSSVC_NETRUNJOINDOMAIN2, api_wkssvc_NetrUnjoinDomain2},
|
|---|
| 2055 | {"WKSSVC_NETRRENAMEMACHINEINDOMAIN2", DCERPC_WKSSVC_NETRRENAMEMACHINEINDOMAIN2, api_wkssvc_NetrRenameMachineInDomain2},
|
|---|
| 2056 | {"WKSSVC_NETRVALIDATENAME2", DCERPC_WKSSVC_NETRVALIDATENAME2, api_WKSSVC_NETRVALIDATENAME2},
|
|---|
| 2057 | {"WKSSVC_NETRGETJOINABLEOUS2", DCERPC_WKSSVC_NETRGETJOINABLEOUS2, api_WKSSVC_NETRGETJOINABLEOUS2},
|
|---|
| 2058 | {"WKSSVC_NETRADDALTERNATECOMPUTERNAME", DCERPC_WKSSVC_NETRADDALTERNATECOMPUTERNAME, api_wkssvc_NetrAddAlternateComputerName},
|
|---|
| 2059 | {"WKSSVC_NETRREMOVEALTERNATECOMPUTERNAME", DCERPC_WKSSVC_NETRREMOVEALTERNATECOMPUTERNAME, api_wkssvc_NetrRemoveAlternateComputerName},
|
|---|
| 2060 | {"WKSSVC_NETRSETPRIMARYCOMPUTERNAME", DCERPC_WKSSVC_NETRSETPRIMARYCOMPUTERNAME, api_WKSSVC_NETRSETPRIMARYCOMPUTERNAME},
|
|---|
| 2061 | {"WKSSVC_NETRENUMERATECOMPUTERNAMES", DCERPC_WKSSVC_NETRENUMERATECOMPUTERNAMES, api_WKSSVC_NETRENUMERATECOMPUTERNAMES},
|
|---|
| 2062 | };
|
|---|
| 2063 |
|
|---|
| 2064 | void wkssvc_get_pipe_fns(struct api_struct **fns, int *n_fns)
|
|---|
| 2065 | {
|
|---|
| 2066 | *fns = api_wkssvc_cmds;
|
|---|
| 2067 | *n_fns = sizeof(api_wkssvc_cmds) / sizeof(struct api_struct);
|
|---|
| 2068 | }
|
|---|
| 2069 |
|
|---|
| 2070 | NTSTATUS rpc_wkssvc_init(void)
|
|---|
| 2071 | {
|
|---|
| 2072 | return rpc_pipe_register_commands(SMB_RPC_INTERFACE_VERSION, "wkssvc", "wkssvc", api_wkssvc_cmds, sizeof(api_wkssvc_cmds) / sizeof(struct api_struct));
|
|---|
| 2073 | }
|
|---|