ReactOS 0.4.16-dev-109-gf4cb10f
rpcserver.c
Go to the documentation of this file.
1/*
2 * ReactOS Services
3 * Copyright (C) 2015 ReactOS Team
4 *
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License along
16 * with this program; if not, write to the Free Software Foundation, Inc.,
17 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18 */
19/*
20 * COPYRIGHT: See COPYING in the top level directory
21 * PROJECT: ReactOS Services
22 * FILE: base/services/wkssvc/rpcserver.c
23 * PURPOSE: Workstation service
24 * PROGRAMMER: Eric Kohl
25 */
26
27/* INCLUDES *****************************************************************/
28
29#include "precomp.h"
30
31#include "lmerr.h"
32
34
35/* FUNCTIONS *****************************************************************/
36
40 LPVOID lpParameter)
41{
43
44 Status = RpcServerUseProtseqEpW(L"ncacn_np", 20, L"\\pipe\\wkssvc", NULL);
45 if (Status != RPC_S_OK)
46 {
47 ERR("RpcServerUseProtseqEpW() failed (Status %lx)\n", Status);
48 return 0;
49 }
50
51 Status = RpcServerRegisterIf(wkssvc_v1_0_s_ifspec, NULL, NULL);
52 if (Status != RPC_S_OK)
53 {
54 ERR("RpcServerRegisterIf() failed (Status %lx)\n", Status);
55 return 0;
56 }
57
59 if (Status != RPC_S_OK)
60 {
61 ERR("RpcServerListen() failed (Status %lx)\n", Status);
62 }
63
64 return 0;
65}
66
67
69{
71}
72
73
75{
77}
78
79
80/* Function 0 */
81unsigned long
84 WKSSVC_IDENTIFY_HANDLE ServerName,
85 unsigned long Level,
86 LPWKSTA_INFO *WkstaInfo)
87{
88 WCHAR szComputerName[MAX_COMPUTERNAME_LENGTH + 1];
89 DWORD dwComputerNameLength;
90 LPCWSTR pszLanRoot = L"";
91 PWKSTA_INFO pWkstaInfo = NULL;
93 LSA_HANDLE PolicyHandle;
95 NTSTATUS NtStatus;
96 DWORD dwResult = NERR_Success;
97
98 TRACE("NetrWkstaGetInfo level %lu\n", Level);
99
100 dwComputerNameLength = MAX_COMPUTERNAME_LENGTH + 1;
101 GetComputerNameW(szComputerName, &dwComputerNameLength);
102 dwComputerNameLength++; /* include NULL terminator */
103
105 NtStatus = LsaOpenPolicy(NULL,
108 &PolicyHandle);
109 if (NtStatus != STATUS_SUCCESS)
110 {
111 WARN("LsaOpenPolicy() failed (Status 0x%08lx)\n", NtStatus);
112 return LsaNtStatusToWinError(NtStatus);
113 }
114
115 NtStatus = LsaQueryInformationPolicy(PolicyHandle,
117 (PVOID*)&DomainInfo);
118
119 LsaClose(PolicyHandle);
120
121 if (NtStatus != STATUS_SUCCESS)
122 {
123 WARN("LsaQueryInformationPolicy() failed (Status 0x%08lx)\n", NtStatus);
124 return LsaNtStatusToWinError(NtStatus);
125 }
126
127 switch (Level)
128 {
129 case 100:
130 pWkstaInfo = midl_user_allocate(sizeof(WKSTA_INFO_100));
131 if (pWkstaInfo == NULL)
132 {
133 dwResult = ERROR_NOT_ENOUGH_MEMORY;
134 break;
135 }
136
138
139 pWkstaInfo->WkstaInfo100.wki100_computername = midl_user_allocate(dwComputerNameLength * sizeof(WCHAR));
140 if (pWkstaInfo->WkstaInfo100.wki100_computername != NULL)
141 wcscpy(pWkstaInfo->WkstaInfo100.wki100_computername, szComputerName);
142
143 pWkstaInfo->WkstaInfo100.wki100_langroup = midl_user_allocate((wcslen(DomainInfo->Name.Buffer) + 1) * sizeof(WCHAR));
144 if (pWkstaInfo->WkstaInfo100.wki100_langroup != NULL)
145 wcscpy(pWkstaInfo->WkstaInfo100.wki100_langroup, DomainInfo->Name.Buffer);
146
149
150 *WkstaInfo = pWkstaInfo;
151 break;
152
153 case 101:
154 pWkstaInfo = midl_user_allocate(sizeof(WKSTA_INFO_101));
155 if (pWkstaInfo == NULL)
156 {
157 dwResult = ERROR_NOT_ENOUGH_MEMORY;
158 break;
159 }
160
162
163 pWkstaInfo->WkstaInfo101.wki101_computername = midl_user_allocate(dwComputerNameLength * sizeof(WCHAR));
164 if (pWkstaInfo->WkstaInfo101.wki101_computername != NULL)
165 wcscpy(pWkstaInfo->WkstaInfo101.wki101_computername, szComputerName);
166
167 pWkstaInfo->WkstaInfo101.wki101_langroup = midl_user_allocate((wcslen(DomainInfo->Name.Buffer) + 1) * sizeof(WCHAR));
168 if (pWkstaInfo->WkstaInfo101.wki101_langroup != NULL)
169 wcscpy(pWkstaInfo->WkstaInfo101.wki101_langroup, DomainInfo->Name.Buffer);
170
173
174 pWkstaInfo->WkstaInfo101.wki101_lanroot = midl_user_allocate((wcslen(pszLanRoot) + 1) * sizeof(WCHAR));
175 if (pWkstaInfo->WkstaInfo101.wki101_lanroot != NULL)
176 wcscpy(pWkstaInfo->WkstaInfo101.wki101_lanroot, pszLanRoot);
177
178 *WkstaInfo = pWkstaInfo;
179 break;
180
181 case 102:
182 pWkstaInfo = midl_user_allocate(sizeof(WKSTA_INFO_102));
183 if (pWkstaInfo == NULL)
184 {
185 dwResult = ERROR_NOT_ENOUGH_MEMORY;
186 break;
187 }
188
190
191 pWkstaInfo->WkstaInfo102.wki102_computername = midl_user_allocate(dwComputerNameLength * sizeof(WCHAR));
192 if (pWkstaInfo->WkstaInfo102.wki102_computername != NULL)
193 wcscpy(pWkstaInfo->WkstaInfo102.wki102_computername, szComputerName);
194
195 pWkstaInfo->WkstaInfo102.wki102_langroup = midl_user_allocate((wcslen(DomainInfo->Name.Buffer) + 1) * sizeof(WCHAR));
196 if (pWkstaInfo->WkstaInfo102.wki102_langroup != NULL)
197 wcscpy(pWkstaInfo->WkstaInfo102.wki102_langroup, DomainInfo->Name.Buffer);
198
201
202 pWkstaInfo->WkstaInfo102.wki102_lanroot = midl_user_allocate((wcslen(pszLanRoot) + 1) * sizeof(WCHAR));
203 if (pWkstaInfo->WkstaInfo102.wki102_lanroot != NULL)
204 wcscpy(pWkstaInfo->WkstaInfo102.wki102_lanroot, pszLanRoot);
205
206 pWkstaInfo->WkstaInfo102.wki102_logged_on_users = 1; /* FIXME */
207
208 *WkstaInfo = pWkstaInfo;
209 break;
210
211 default:
212 FIXME("Level %d unimplemented\n", Level);
213 dwResult = ERROR_INVALID_LEVEL;
214 break;
215 }
216
217 if (DomainInfo != NULL)
218 LsaFreeMemory(DomainInfo);
219
220 return dwResult;
221}
222
223
224/* Function 1 */
225unsigned long
228 WKSSVC_IDENTIFY_HANDLE ServerName,
229 unsigned long Level,
230 LPWKSTA_INFO WkstaInfo,
231 unsigned long *ErrorParameter)
232{
234 return 0;
235}
236
237
238/* Function 2 */
239unsigned long
242 WKSSVC_IDENTIFY_HANDLE ServerName,
244 unsigned long PreferredMaximumLength,
245 unsigned long *TotalEntries,
246 unsigned long *ResumeHandle)
247{
248 ERR("NetrWkstaUserEnum(%p %p 0x%lx %p %p)\n",
249 ServerName, UserInfo, PreferredMaximumLength, TotalEntries, ResumeHandle);
250
251
253 return 0;
254}
255
256
257/* Function 3 */
258unsigned long
262 unsigned long Level,
263 LPWKSTA_USER_INFO UserInfo)
264{
265 FIXME("(%s, %d, %p)\n", debugstr_w(Unused), Level, UserInfo);
266
268 return 0;
269}
270
271
272/* Function 4 */
273unsigned long
277 unsigned long Level,
278 LPWKSTA_USER_INFO UserInfo,
279 unsigned long *ErrorParameter)
280{
282 return 0;
283}
284
285
286/* Function 5 */
287unsigned long
290 WKSSVC_IDENTIFY_HANDLE ServerName,
291 LPWKSTA_TRANSPORT_ENUM_STRUCT TransportInfo,
292 unsigned long PreferredMaximumLength,
293 unsigned long* TotalEntries,
294 unsigned long *ResumeHandle)
295{
297 return 0;
298}
299
300
301/* Function 6 */
302unsigned long
305 WKSSVC_IDENTIFY_HANDLE ServerName,
306 unsigned long Level,
307 LPWKSTA_TRANSPORT_INFO_0 TransportInfo,
308 unsigned long *ErrorParameter)
309{
311 return 0;
312}
313
314
315/* Function 7 */
316unsigned long
319 WKSSVC_IDENTIFY_HANDLE ServerName,
320 wchar_t *TransportName,
321 unsigned long ForceLevel)
322{
324 return 0;
325}
326
327
328/* Function 8 */
329unsigned long
332 WKSSVC_IMPERSONATE_HANDLE ServerName,
333 unsigned long Level,
334 LPUSE_INFO InfoStruct,
335 unsigned long *ErrorParameter)
336{
338 return 0;
339}
340
341
342/* Function 9 */
343unsigned long
346 WKSSVC_IMPERSONATE_HANDLE ServerName,
347 wchar_t *UseName,
348 unsigned long Level,
349 LPUSE_INFO InfoStruct)
350{
352 return 0;
353}
354
355
356/* Function 10 */
357unsigned long
360 WKSSVC_IMPERSONATE_HANDLE ServerName,
361 wchar_t *UseName,
362 unsigned long ForceLevel)
363{
365 return 0;
366}
367
368
369/* Function 11 */
370unsigned long
373 WKSSVC_IDENTIFY_HANDLE ServerName,
374 LPUSE_ENUM_STRUCT InfoStruct,
375 unsigned long PreferredMaximumLength,
376 unsigned long *TotalEntries,
377 unsigned long *ResumeHandle)
378{
380 return 0;
381}
382
383
384/* Function 12 - Not used on wire */
385unsigned long
388{
389 TRACE("NetrMessageBufferSend()\n");
390 return ERROR_NOT_SUPPORTED;
391}
392
393
394/* Function 13 */
395unsigned long
398 WKSSVC_IDENTIFY_HANDLE ServerName,
399 wchar_t *ServiceName,
400 unsigned long Level,
401 unsigned long Options,
403{
404 PSTAT_WORKSTATION_0 pStatBuffer;
405
406 TRACE("NetrWorkstationStatisticsGet(%p %p %lu 0x%lx %p)\n",
407 ServerName, ServiceName, Level, Options, Buffer);
408
409 if (Level != 0)
410 return ERROR_INVALID_LEVEL;
411
412 if (Options != 0)
414
415 pStatBuffer = midl_user_allocate(sizeof(STAT_WORKSTATION_0));
416 if (pStatBuffer == NULL)
418
419 ZeroMemory(pStatBuffer, sizeof(STAT_WORKSTATION_0));
420
421 // FIXME: Return the actual statistcs data!
422
423 *Buffer = pStatBuffer;
424
425 return NERR_Success;
426}
427
428
429/* Function 14 - Not used on wire */
430unsigned long
433 WKSSVC_IDENTIFY_HANDLE DomainName)
434{
435 TRACE("NetrLogonDomainNameAdd(%s)\n",
436 debugstr_w(DomainName));
437 return ERROR_NOT_SUPPORTED;
438}
439
440
441/* Function 15 - Not used on wire */
442unsigned long
445 WKSSVC_IDENTIFY_HANDLE DomainName)
446{
447 TRACE("NetrLogonDomainNameDel(%s)\n",
448 debugstr_w(DomainName));
449 return ERROR_NOT_SUPPORTED;
450}
451
452
453/* Function 16 - Not used on wire */
454unsigned long
457{
458 TRACE("NetrJoinDomain()\n");
459 return ERROR_NOT_SUPPORTED;
460}
461
462
463/* Function 17 - Not used on wire */
464unsigned long
467{
468 TRACE("NetrUnjoinDomain()\n");
469 return ERROR_NOT_SUPPORTED;
470}
471
472
473/* Function 18 - Not used on wire */
474unsigned long
477{
478 TRACE("NetrValidateName()\n");
479 return ERROR_NOT_SUPPORTED;
480}
481
482
483/* Function 19 - Not used on wire */
484unsigned long
487{
488 TRACE("NetrRenameMachineInDomain()\n");
489 return ERROR_NOT_SUPPORTED;
490}
491
492
493/* Function 20 */
494unsigned long
497 WKSSVC_IMPERSONATE_HANDLE ServerName,
498 wchar_t **NameBuffer,
499 PNETSETUP_JOIN_STATUS BufferType)
500{
501 TRACE("NetrGetJoinInformation(%p %p %p)\n",
502 ServerName, NameBuffer, BufferType);
503
504 if (NameBuffer == NULL)
506
507 return NetpGetJoinInformation(NameBuffer,
508 BufferType);
509}
510
511
512/* Function 21 - Not used on wire */
513unsigned long
516{
517 TRACE("NetrGetJoinableOUs()\n");
518 return ERROR_NOT_SUPPORTED;
519}
520
521
522/* Function 22 */
523unsigned long
526 handle_t RpcBindingHandle,
527 wchar_t *ServerName,
528 wchar_t *DomainNameParam,
529 wchar_t *MachineAccountOU,
530 wchar_t *AccountName,
532 unsigned long Options)
533{
535
536 FIXME("NetrJoinDomain2(%p %S %S %S %S %p 0x%lx)\n",
537 RpcBindingHandle, ServerName, DomainNameParam, MachineAccountOU,
538 AccountName, Password, Options);
539
540 if (DomainNameParam == NULL)
542
544 {
545 FIXME("NetrJoinDomain2: NETSETUP_JOIN_DOMAIN is not supported yet!\n");
547 }
548 else
549 {
550 status = NetpJoinWorkgroup(DomainNameParam);
551 }
552
553 return status;
554}
555
556
557/* Function 23 */
558unsigned long
561 handle_t RpcBindingHandle,
562 wchar_t *ServerName,
563 wchar_t *AccountName,
565 unsigned long Options)
566{
568 return 0;
569}
570
571
572/* Function 24 */
573unsigned long
576 handle_t RpcBindingHandle,
577 wchar_t *ServerName,
578 wchar_t *MachineName,
579 wchar_t *AccountName,
581 unsigned long Options)
582{
584 return 0;
585}
586
587
588/* Function 25 */
589unsigned long
592 handle_t RpcBindingHandle,
593 wchar_t *ServerName,
594 wchar_t *NameToValidate,
595 wchar_t *AccountName,
598{
600 return 0;
601}
602
603
604/* Function 26 */
605unsigned long
608 handle_t RpcBindingHandle,
609 wchar_t *ServerName,
610 wchar_t *DomainNameParam,
611 wchar_t *AccountName,
613 unsigned long* OUCount,
614 wchar_t ***OUs)
615{
617 return 0;
618}
619
620
621/* Function 27 */
622unsigned long
625 handle_t RpcBindingHandle,
626 wchar_t *ServerName,
627 wchar_t *AlternateName,
628 wchar_t *DomainAccount,
629 PJOINPR_ENCRYPTED_USER_PASSWORD EncryptedPassword,
630 unsigned long Reserved)
631{
633 return 0;
634}
635
636
637/* Function 28 */
638unsigned long
641 handle_t RpcBindingHandle,
642 wchar_t *ServerName,
643 wchar_t *AlternateName,
644 wchar_t *DomainAccount,
645 PJOINPR_ENCRYPTED_USER_PASSWORD EncryptedPassword,
646 unsigned long Reserved)
647{
649 return 0;
650}
651
652
653/* Function 29 */
654unsigned long
657 handle_t RpcBindingHandle,
658 wchar_t *ServerName,
659 wchar_t *PrimaryName,
660 wchar_t *DomainAccount,
661 PJOINPR_ENCRYPTED_USER_PASSWORD EncryptedPassword,
662 unsigned long Reserved)
663{
665 return 0;
666}
667
668
669/* Function 30 */
670unsigned long
673 WKSSVC_IMPERSONATE_HANDLE ServerName,
675 unsigned long Reserved,
676 PNET_COMPUTER_NAME_ARRAY *ComputerNames)
677{
679 return 0;
680}
681
682/* EOF */
ACPI_PHYSICAL_ADDRESS ACPI_SIZE BOOLEAN Warn UINT32 *TableIdx UINT32 ACPI_TABLE_HEADER *OutTableHeader ACPI_TABLE_HEADER **OutTable ACPI_HANDLE UINT32 ACPI_WALK_CALLBACK ACPI_WALK_CALLBACK void void **ReturnValue UINT32 NameType
Definition: acpixf.h:658
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
Definition: precomp.h:23
LONG NTSTATUS
Definition: precomp.h:26
static WCHAR ServiceName[]
Definition: browser.c:19
DWORD WINAPI RpcThreadRoutine(LPVOID lpParameter)
Definition: rpcserver.c:20
NET_API_STATUS NetpGetJoinInformation(LPWSTR *NameBuffer, PNETSETUP_JOIN_STATUS BufferType)
Definition: domain.c:71
NET_API_STATUS NetpJoinWorkgroup(_In_ LPCWSTR lpWorkgroupName)
Definition: domain.c:52
OSVERSIONINFOW VersionInfo
Definition: wkssvc.c:40
unsigned long __stdcall NetrUseDel(WKSSVC_IMPERSONATE_HANDLE ServerName, wchar_t *UseName, unsigned long ForceLevel)
Definition: rpcserver.c:359
unsigned long __stdcall NetrUseAdd(WKSSVC_IMPERSONATE_HANDLE ServerName, unsigned long Level, LPUSE_INFO InfoStruct, unsigned long *ErrorParameter)
Definition: rpcserver.c:331
unsigned long __stdcall NetrWkstaTransportAdd(WKSSVC_IDENTIFY_HANDLE ServerName, unsigned long Level, LPWKSTA_TRANSPORT_INFO_0 TransportInfo, unsigned long *ErrorParameter)
Definition: rpcserver.c:304
unsigned long __stdcall NetrGetJoinInformation(WKSSVC_IMPERSONATE_HANDLE ServerName, wchar_t **NameBuffer, PNETSETUP_JOIN_STATUS BufferType)
Definition: rpcserver.c:496
unsigned long __stdcall NetrRemoveAlternateComputerName(handle_t RpcBindingHandle, wchar_t *ServerName, wchar_t *AlternateName, wchar_t *DomainAccount, PJOINPR_ENCRYPTED_USER_PASSWORD EncryptedPassword, unsigned long Reserved)
Definition: rpcserver.c:640
unsigned long __stdcall NetrRenameMachineInDomain2(handle_t RpcBindingHandle, wchar_t *ServerName, wchar_t *MachineName, wchar_t *AccountName, PJOINPR_ENCRYPTED_USER_PASSWORD Password, unsigned long Options)
Definition: rpcserver.c:575
unsigned long __stdcall NetrWkstaTransportEnum(WKSSVC_IDENTIFY_HANDLE ServerName, LPWKSTA_TRANSPORT_ENUM_STRUCT TransportInfo, unsigned long PreferredMaximumLength, unsigned long *TotalEntries, unsigned long *ResumeHandle)
Definition: rpcserver.c:289
unsigned long __stdcall NetrJoinDomain(void)
Definition: rpcserver.c:456
unsigned long __stdcall NetrMessageBufferSend(void)
Definition: rpcserver.c:387
unsigned long __stdcall NetrWkstaUserEnum(WKSSVC_IDENTIFY_HANDLE ServerName, LPWKSTA_USER_ENUM_STRUCT UserInfo, unsigned long PreferredMaximumLength, unsigned long *TotalEntries, unsigned long *ResumeHandle)
Definition: rpcserver.c:241
unsigned long __stdcall NetrGetJoinableOUs(void)
Definition: rpcserver.c:515
unsigned long __stdcall NetrWkstaGetInfo(WKSSVC_IDENTIFY_HANDLE ServerName, unsigned long Level, LPWKSTA_INFO *WkstaInfo)
Definition: rpcserver.c:83
unsigned long __stdcall NetrGetJoinableOUs2(handle_t RpcBindingHandle, wchar_t *ServerName, wchar_t *DomainNameParam, wchar_t *AccountName, PJOINPR_ENCRYPTED_USER_PASSWORD Password, unsigned long *OUCount, wchar_t ***OUs)
Definition: rpcserver.c:607
unsigned long __stdcall NetrValidateName2(handle_t RpcBindingHandle, wchar_t *ServerName, wchar_t *NameToValidate, wchar_t *AccountName, PJOINPR_ENCRYPTED_USER_PASSWORD Password, NETSETUP_NAME_TYPE NameType)
Definition: rpcserver.c:591
unsigned long __stdcall NetrWkstaSetInfo(WKSSVC_IDENTIFY_HANDLE ServerName, unsigned long Level, LPWKSTA_INFO WkstaInfo, unsigned long *ErrorParameter)
Definition: rpcserver.c:227
unsigned long __stdcall NetrEnumerateComputerNames(WKSSVC_IMPERSONATE_HANDLE ServerName, NET_COMPUTER_NAME_TYPE NameType, unsigned long Reserved, PNET_COMPUTER_NAME_ARRAY *ComputerNames)
Definition: rpcserver.c:672
unsigned long __stdcall NetrWorkstationStatisticsGet(WKSSVC_IDENTIFY_HANDLE ServerName, wchar_t *ServiceName, unsigned long Level, unsigned long Options, LPSTAT_WORKSTATION_0 *Buffer)
Definition: rpcserver.c:397
unsigned long __stdcall NetrWkstaTransportDel(WKSSVC_IDENTIFY_HANDLE ServerName, wchar_t *TransportName, unsigned long ForceLevel)
Definition: rpcserver.c:318
unsigned long __stdcall NetrValidateName(void)
Definition: rpcserver.c:476
unsigned long __stdcall NetrLogonDomainNameDel(WKSSVC_IDENTIFY_HANDLE DomainName)
Definition: rpcserver.c:444
unsigned long __stdcall NetrLogonDomainNameAdd(WKSSVC_IDENTIFY_HANDLE DomainName)
Definition: rpcserver.c:432
unsigned long __stdcall NetrRenameMachineInDomain(void)
Definition: rpcserver.c:486
unsigned long __stdcall NetrSetPrimaryComputerName(handle_t RpcBindingHandle, wchar_t *ServerName, wchar_t *PrimaryName, wchar_t *DomainAccount, PJOINPR_ENCRYPTED_USER_PASSWORD EncryptedPassword, unsigned long Reserved)
Definition: rpcserver.c:656
unsigned long __stdcall NetrWkstaUserSetInfo(WKSSVC_IDENTIFY_HANDLE Unused, unsigned long Level, LPWKSTA_USER_INFO UserInfo, unsigned long *ErrorParameter)
Definition: rpcserver.c:275
unsigned long __stdcall NetrUnjoinDomain(void)
Definition: rpcserver.c:466
unsigned long __stdcall NetrUnjoinDomain2(handle_t RpcBindingHandle, wchar_t *ServerName, wchar_t *AccountName, PJOINPR_ENCRYPTED_USER_PASSWORD Password, unsigned long Options)
Definition: rpcserver.c:560
unsigned long __stdcall NetrAddAlternateComputerName(handle_t RpcBindingHandle, wchar_t *ServerName, wchar_t *AlternateName, wchar_t *DomainAccount, PJOINPR_ENCRYPTED_USER_PASSWORD EncryptedPassword, unsigned long Reserved)
Definition: rpcserver.c:624
unsigned long __stdcall NetrJoinDomain2(handle_t RpcBindingHandle, wchar_t *ServerName, wchar_t *DomainNameParam, wchar_t *MachineAccountOU, wchar_t *AccountName, PJOINPR_ENCRYPTED_USER_PASSWORD Password, unsigned long Options)
Definition: rpcserver.c:525
unsigned long __stdcall NetrUseEnum(WKSSVC_IDENTIFY_HANDLE ServerName, LPUSE_ENUM_STRUCT InfoStruct, unsigned long PreferredMaximumLength, unsigned long *TotalEntries, unsigned long *ResumeHandle)
Definition: rpcserver.c:372
unsigned long __stdcall NetrUseGetInfo(WKSSVC_IMPERSONATE_HANDLE ServerName, wchar_t *UseName, unsigned long Level, LPUSE_INFO InfoStruct)
Definition: rpcserver.c:345
unsigned long __stdcall NetrWkstaUserGetInfo(WKSSVC_IDENTIFY_HANDLE Unused, unsigned long Level, LPWKSTA_USER_INFO UserInfo)
Definition: rpcserver.c:260
#define FIXME(fmt,...)
Definition: precomp.h:53
#define WARN(fmt,...)
Definition: precomp.h:61
#define ERR(fmt,...)
Definition: precomp.h:57
#define UNIMPLEMENTED
Definition: debug.h:118
Definition: bufpool.h:45
BOOL WINAPI GetComputerNameW(LPWSTR lpBuffer, LPDWORD lpnSize)
Definition: compname.c:446
IN PUNICODE_STRING IN POBJECT_ATTRIBUTES ObjectAttributes
Definition: conport.c:36
#define ERROR_NOT_ENOUGH_MEMORY
Definition: dderror.h:7
#define NULL
Definition: types.h:112
#define FALSE
Definition: types.h:117
NTSTATUS WINAPI LsaOpenPolicy(IN PLSA_UNICODE_STRING SystemName OPTIONAL, IN PLSA_OBJECT_ATTRIBUTES ObjectAttributes, IN ACCESS_MASK DesiredAccess, OUT PLSA_HANDLE PolicyHandle)
Definition: lsa.c:1183
ULONG WINAPI LsaNtStatusToWinError(IN NTSTATUS Status)
Definition: lsa.c:1131
NTSTATUS WINAPI LsaQueryInformationPolicy(IN LSA_HANDLE PolicyHandle, IN POLICY_INFORMATION_CLASS InformationClass, OUT PVOID *Buffer)
Definition: lsa.c:1473
NTSTATUS WINAPI LsaFreeMemory(IN PVOID Buffer)
Definition: lsa.c:701
NTSTATUS WINAPI LsaClose(IN LSA_HANDLE ObjectHandle)
Definition: lsa.c:194
#define GetProcessHeap()
Definition: compat.h:736
#define ERROR_CALL_NOT_IMPLEMENTED
Definition: compat.h:102
#define ERROR_INVALID_PARAMETER
Definition: compat.h:101
#define HeapAlloc
Definition: compat.h:733
#define ERROR_NOT_SUPPORTED
Definition: compat.h:100
#define HeapFree(x, y, z)
Definition: compat.h:735
#define HEAP_ZERO_MEMORY
Definition: compat.h:134
unsigned long DWORD
Definition: ntddk_ex.h:95
Status
Definition: gdiplustypes.h:25
GLenum GLsizei len
Definition: glext.h:6722
_CRTIMP size_t __cdecl wcslen(_In_z_ const wchar_t *_Str)
#define debugstr_w
Definition: kernel32.h:32
#define Unused(x)
Definition: atlwin.h:28
#define PLATFORM_ID_NT
Definition: lmcons.h:60
#define NERR_Success
Definition: lmerr.h:5
enum _NETSETUP_JOIN_STATUS * PNETSETUP_JOIN_STATUS
#define NETSETUP_JOIN_DOMAIN
Definition: lmjoin.h:16
static PVOID ptr
Definition: dispmode.c:27
DWORD NET_API_STATUS
Definition: ms-dtyp.idl:91
@ PolicyPrimaryDomainInformation
Definition: ntsecapi.h:245
#define POLICY_VIEW_LOCAL_INFORMATION
Definition: ntsecapi.h:61
#define L(x)
Definition: ntvdm.h:50
RPC_STATUS WINAPI RpcServerListen(UINT MinimumCallThreads, UINT MaxCalls, UINT DontWait)
Definition: rpc_server.c:1520
RPC_STATUS WINAPI RpcServerRegisterIf(RPC_IF_HANDLE IfSpec, UUID *MgrTypeUuid, RPC_MGR_EPV *MgrEpv)
Definition: rpc_server.c:1116
RPC_STATUS WINAPI RpcServerUseProtseqEpW(RPC_WSTR Protseq, UINT MaxCalls, RPC_WSTR Endpoint, LPVOID SecurityDescriptor)
Definition: rpc_server.c:927
#define RPC_C_LISTEN_MAX_CALLS_DEFAULT
Definition: rpcdce.h:122
#define RPC_S_OK
Definition: rpcnterr.h:22
_CRTIMP wchar_t *__cdecl wcscpy(_Out_writes_z_(_String_length_(_Source)+1) wchar_t *_Dest, _In_z_ const wchar_t *_Source)
#define midl_user_free
Definition: rpc.h:45
#define __RPC_FAR
Definition: rpc.h:56
long RPC_STATUS
Definition: rpc.h:52
#define __RPC_USER
Definition: rpc.h:65
#define midl_user_allocate
Definition: rpc.h:44
_In_ DWORD _Out_ PDWORD _In_opt_ PCSTR MachineName
Definition: setupapi.h:1293
#define STATUS_SUCCESS
Definition: shellext.h:65
#define TRACE(s)
Definition: solgame.cpp:4
ULONG dwMinorVersion
Definition: rtltypes.h:248
ULONG dwMajorVersion
Definition: rtltypes.h:247
LSA_UNICODE_STRING Name
Definition: ntsecapi.h:570
DWORD wki100_ver_major
Definition: lmwksta.h:68
LPWSTR wki100_langroup
Definition: lmwksta.h:67
DWORD wki100_ver_minor
Definition: lmwksta.h:69
LPWSTR wki100_computername
Definition: lmwksta.h:66
DWORD wki100_platform_id
Definition: lmwksta.h:65
DWORD wki101_ver_minor
Definition: lmwksta.h:76
DWORD wki101_platform_id
Definition: lmwksta.h:72
LPWSTR wki101_lanroot
Definition: lmwksta.h:77
LPWSTR wki101_computername
Definition: lmwksta.h:73
LPWSTR wki101_langroup
Definition: lmwksta.h:74
DWORD wki101_ver_major
Definition: lmwksta.h:75
LPWSTR wki102_lanroot
Definition: lmwksta.h:85
DWORD wki102_ver_minor
Definition: lmwksta.h:84
DWORD wki102_logged_on_users
Definition: lmwksta.h:86
LPWSTR wki102_langroup
Definition: lmwksta.h:82
DWORD wki102_platform_id
Definition: lmwksta.h:80
DWORD wki102_ver_major
Definition: lmwksta.h:83
LPWSTR wki102_computername
Definition: lmwksta.h:81
Definition: ps.c:97
@ Password
Definition: telnetd.h:65
ULONG_PTR SIZE_T
Definition: typedefs.h:80
#define __stdcall
Definition: typedefs.h:25
WKSTA_INFO_102 WkstaInfo102
Definition: wkssvc.idl:218
WKSTA_INFO_101 WkstaInfo101
Definition: wkssvc.idl:217
WKSTA_INFO_100 WkstaInfo100
Definition: wkssvc.idl:216
_In_ PWDFDEVICE_INIT _In_ PWDF_REMOVE_LOCK_OPTIONS Options
Definition: wdfdevice.h:3534
#define ZeroMemory
Definition: winbase.h:1712
#define MAX_COMPUTERNAME_LENGTH
Definition: winbase.h:243
_Reserved_ PVOID Reserved
Definition: winddi.h:3974
#define WINAPI
Definition: msvc.h:6
#define ERROR_INVALID_LEVEL
Definition: winerror.h:196
enum _NET_COMPUTER_NAME_TYPE NET_COMPUTER_NAME_TYPE
enum _NETSETUP_NAME_TYPE NETSETUP_NAME_TYPE
wchar_t * WKSSVC_IMPERSONATE_HANDLE
Definition: wkssvc.idl:8
wchar_t * WKSSVC_IDENTIFY_HANDLE
Definition: wkssvc.idl:7
_IRQL_requires_same_ typedef _In_ ULONG _In_ UCHAR Level
Definition: wmitypes.h:56
__wchar_t WCHAR
Definition: xmlstorage.h:180
const WCHAR * LPCWSTR
Definition: xmlstorage.h:185