621 lines
18 KiB
Plaintext
621 lines
18 KiB
Plaintext
|
/*++
|
||
|
|
||
|
Copyright (c) 1990 Microsoft Corporation
|
||
|
|
||
|
Module Name:
|
||
|
|
||
|
wkssvc.idl
|
||
|
|
||
|
Abstract:
|
||
|
|
||
|
Contains the Netr (Net Remote) RPC interface specification for the APIs
|
||
|
associated with the Workstation service. This includes APIs from the
|
||
|
following catagories:
|
||
|
NetWksta
|
||
|
NetUse
|
||
|
Also contains the RPC specific data structures for these API.
|
||
|
|
||
|
Author:
|
||
|
|
||
|
Rita Wong (ritaw) 06-May-1991
|
||
|
|
||
|
Environment:
|
||
|
|
||
|
User Mode - Win32 - MIDL
|
||
|
|
||
|
Revision History:
|
||
|
|
||
|
21-Jan-1992 rfirth
|
||
|
* Removed NET_API_FUNCTION from all interfaces
|
||
|
--*/
|
||
|
|
||
|
//
|
||
|
// Interface Attributes
|
||
|
//
|
||
|
|
||
|
[
|
||
|
uuid(6BFFD098-A112-3610-9833-46C3F87E345A),
|
||
|
version(1.0),
|
||
|
#ifdef __midl
|
||
|
ms_union,
|
||
|
#endif // __midl
|
||
|
pointer_default(unique)
|
||
|
]
|
||
|
|
||
|
|
||
|
//
|
||
|
// Interface Keyword
|
||
|
//
|
||
|
|
||
|
interface wkssvc
|
||
|
|
||
|
|
||
|
//
|
||
|
// Interface Body
|
||
|
//
|
||
|
|
||
|
{
|
||
|
|
||
|
import "imports.idl";
|
||
|
#include <lmcons.h>
|
||
|
|
||
|
//
|
||
|
// BUGBUG - take this definition out when midl understands LPWSTR etc
|
||
|
//
|
||
|
|
||
|
#ifdef UNICODE
|
||
|
#define LPTSTR wchar_t*
|
||
|
#endif
|
||
|
|
||
|
//
|
||
|
// ---------------------------------------------------------------//
|
||
|
//
|
||
|
|
||
|
|
||
|
typedef [handle] LPTSTR WKSSVC_IMPERSONATE_HANDLE;
|
||
|
|
||
|
typedef [handle] LPTSTR WKSSVC_IDENTIFY_HANDLE;
|
||
|
|
||
|
|
||
|
//
|
||
|
// Workstation APIs
|
||
|
//
|
||
|
|
||
|
|
||
|
//
|
||
|
// NetrWkstaGetInfo and NetrWkstaSetInfo
|
||
|
//
|
||
|
typedef [switch_type(unsigned long)] union _WKSTA_INFO {
|
||
|
[case(100)]
|
||
|
LPWKSTA_INFO_100 WkstaInfo100;
|
||
|
[case(101)]
|
||
|
LPWKSTA_INFO_101 WkstaInfo101;
|
||
|
[case(102)]
|
||
|
LPWKSTA_INFO_102 WkstaInfo102;
|
||
|
[case(1010)]
|
||
|
LPWKSTA_INFO_1010 WkstaInfo1010;
|
||
|
[case(1011)]
|
||
|
LPWKSTA_INFO_1011 WkstaInfo1011;
|
||
|
[case(1012)]
|
||
|
LPWKSTA_INFO_1012 WkstaInfo1012;
|
||
|
[case(1013)]
|
||
|
LPWKSTA_INFO_1013 WkstaInfo1013;
|
||
|
[case(1018)]
|
||
|
LPWKSTA_INFO_1018 WkstaInfo1018;
|
||
|
[case(1023)]
|
||
|
LPWKSTA_INFO_1023 WkstaInfo1023;
|
||
|
[case(1033)]
|
||
|
LPWKSTA_INFO_1033 WkstaInfo1033;
|
||
|
[case(1041)]
|
||
|
LPWKSTA_INFO_1041 WkstaInfo1041;
|
||
|
[case(1042)]
|
||
|
LPWKSTA_INFO_1042 WkstaInfo1042;
|
||
|
[case(1043)]
|
||
|
LPWKSTA_INFO_1043 WkstaInfo1043;
|
||
|
[case(1044)]
|
||
|
LPWKSTA_INFO_1044 WkstaInfo1044;
|
||
|
[case(1045)]
|
||
|
LPWKSTA_INFO_1045 WkstaInfo1045;
|
||
|
[case(1046)]
|
||
|
LPWKSTA_INFO_1046 WkstaInfo1046;
|
||
|
[case(1047)]
|
||
|
LPWKSTA_INFO_1047 WkstaInfo1047;
|
||
|
[case(1048)]
|
||
|
LPWKSTA_INFO_1048 WkstaInfo1048;
|
||
|
[case(1049)]
|
||
|
LPWKSTA_INFO_1049 WkstaInfo1049;
|
||
|
[case(1050)]
|
||
|
LPWKSTA_INFO_1050 WkstaInfo1050;
|
||
|
[case(1051)]
|
||
|
LPWKSTA_INFO_1051 WkstaInfo1051;
|
||
|
[case(1052)]
|
||
|
LPWKSTA_INFO_1052 WkstaInfo1052;
|
||
|
[case(1053)]
|
||
|
LPWKSTA_INFO_1053 WkstaInfo1053;
|
||
|
[case(1054)]
|
||
|
LPWKSTA_INFO_1054 WkstaInfo1054;
|
||
|
[case(1055)]
|
||
|
LPWKSTA_INFO_1055 WkstaInfo1055;
|
||
|
[case(1056)]
|
||
|
LPWKSTA_INFO_1056 WkstaInfo1056;
|
||
|
[case(1057)]
|
||
|
LPWKSTA_INFO_1057 WkstaInfo1057;
|
||
|
[case(1058)]
|
||
|
LPWKSTA_INFO_1058 WkstaInfo1058;
|
||
|
[case(1059)]
|
||
|
LPWKSTA_INFO_1059 WkstaInfo1059;
|
||
|
[case(1060)]
|
||
|
LPWKSTA_INFO_1060 WkstaInfo1060;
|
||
|
[case(1061)]
|
||
|
LPWKSTA_INFO_1061 WkstaInfo1061;
|
||
|
[case(1062)]
|
||
|
LPWKSTA_INFO_1062 WkstaInfo1062;
|
||
|
[case(502)]
|
||
|
LPWKSTA_INFO_502 WkstaInfo502;
|
||
|
[default]
|
||
|
;
|
||
|
} WKSTA_INFO, *PWKSTA_INFO, *LPWKSTA_INFO;
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrWkstaGetInfo (
|
||
|
[in,string,unique] WKSSVC_IDENTIFY_HANDLE ServerName,
|
||
|
[in] DWORD Level,
|
||
|
[out, switch_is(Level)] LPWKSTA_INFO WkstaInfo
|
||
|
);
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrWkstaSetInfo (
|
||
|
[in,string,unique] WKSSVC_IDENTIFY_HANDLE ServerName,
|
||
|
[in] DWORD Level,
|
||
|
[in, switch_is(Level)] LPWKSTA_INFO WkstaInfo,
|
||
|
[in,out,unique] LPDWORD ErrorParameter
|
||
|
);
|
||
|
|
||
|
|
||
|
|
||
|
//
|
||
|
// NetrWkstaUserEnum
|
||
|
//
|
||
|
typedef struct _WKSTA_USER_INFO_0_CONTAINER {
|
||
|
DWORD EntriesRead;
|
||
|
[size_is(EntriesRead)] LPWKSTA_USER_INFO_0 Buffer;
|
||
|
} WKSTA_USER_INFO_0_CONTAINER, *PWKSTA_USER_INFO_0_CONTAINER,
|
||
|
*LPWKSTA_USER_INFO_0_CONTAINER;
|
||
|
|
||
|
|
||
|
typedef struct _WKSTA_USER_INFO_1_CONTAINER {
|
||
|
DWORD EntriesRead;
|
||
|
[size_is(EntriesRead)] LPWKSTA_USER_INFO_1 Buffer;
|
||
|
} WKSTA_USER_INFO_1_CONTAINER, *PWKSTA_USER_INFO_1_CONTAINER,
|
||
|
*LPWKSTA_USER_INFO_1_CONTAINER;
|
||
|
|
||
|
typedef struct _WKSTA_USER_ENUM_STRUCT {
|
||
|
DWORD Level;
|
||
|
[switch_is(Level)] union _WKSTA_USER_ENUM_UNION {
|
||
|
[case(0)]
|
||
|
LPWKSTA_USER_INFO_0_CONTAINER Level0;
|
||
|
[case(1)]
|
||
|
LPWKSTA_USER_INFO_1_CONTAINER Level1;
|
||
|
[default]
|
||
|
;
|
||
|
} WkstaUserInfo;
|
||
|
} WKSTA_USER_ENUM_STRUCT, *PWKSTA_USER_ENUM_STRUCT, *LPWKSTA_USER_ENUM_STRUCT;
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrWkstaUserEnum (
|
||
|
[in,string,unique] WKSSVC_IDENTIFY_HANDLE ServerName,
|
||
|
[in,out] LPWKSTA_USER_ENUM_STRUCT UserInfo,
|
||
|
[in] DWORD PreferredMaximumLength,
|
||
|
[out] LPDWORD TotalEntries,
|
||
|
[in,out,unique] LPDWORD ResumeHandle
|
||
|
);
|
||
|
|
||
|
|
||
|
|
||
|
//
|
||
|
// NetrWkstaUserGetInfo and NetrWkstaUserSetInfo
|
||
|
//
|
||
|
typedef [switch_type(unsigned long)] union _WKSTA_USER_INFO {
|
||
|
[case(0)]
|
||
|
LPWKSTA_USER_INFO_0 UserInfo0;
|
||
|
[case(1)]
|
||
|
LPWKSTA_USER_INFO_1 UserInfo1;
|
||
|
[case(1101)]
|
||
|
LPWKSTA_USER_INFO_1101 UserInfo1101;
|
||
|
[default]
|
||
|
;
|
||
|
} WKSTA_USER_INFO, *PWKSTA_USER_INFO, *LPWKSTA_USER_INFO;
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrWkstaUserGetInfo (
|
||
|
[in,string,unique] WKSSVC_IDENTIFY_HANDLE Reserved,
|
||
|
[in] DWORD Level,
|
||
|
[out, switch_is(Level)] LPWKSTA_USER_INFO UserInfo
|
||
|
);
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrWkstaUserSetInfo (
|
||
|
[in,string,unique] WKSSVC_IDENTIFY_HANDLE Reserved,
|
||
|
[in] DWORD Level,
|
||
|
[in, switch_is(Level)] LPWKSTA_USER_INFO UserInfo,
|
||
|
[in,out,unique] LPDWORD ErrorParameter
|
||
|
);
|
||
|
|
||
|
//
|
||
|
// NetrWkstaTransportEnum
|
||
|
//
|
||
|
typedef struct _WKSTA_TRANSPORT_INFO_0_CONTAINER {
|
||
|
DWORD EntriesRead;
|
||
|
[size_is(EntriesRead)] LPWKSTA_TRANSPORT_INFO_0 Buffer;
|
||
|
} WKSTA_TRANSPORT_INFO_0_CONTAINER, *PWKSTA_TRANSPORT_INFO_0_CONTAINER,
|
||
|
*LPWKSTA_TRANSPORT_INFO_0_CONTAINER;
|
||
|
|
||
|
typedef struct _WKSTA_TRANSPORT_ENUM_STRUCT {
|
||
|
DWORD Level;
|
||
|
[switch_is(Level)] union _WKSTA_TRANSPORT_ENUM_UNION {
|
||
|
[case(0)]
|
||
|
LPWKSTA_TRANSPORT_INFO_0_CONTAINER Level0;
|
||
|
[default]
|
||
|
;
|
||
|
} WkstaTransportInfo;
|
||
|
} WKSTA_TRANSPORT_ENUM_STRUCT, *PWKSTA_TRANSPORT_ENUM_STRUCT,
|
||
|
*LPWKSTA_TRANSPORT_ENUM_STRUCT;
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrWkstaTransportEnum (
|
||
|
[in,string,unique] WKSSVC_IDENTIFY_HANDLE ServerName,
|
||
|
[in,out] LPWKSTA_TRANSPORT_ENUM_STRUCT TransportInfo,
|
||
|
[in] DWORD PreferredMaximumLength,
|
||
|
[out] LPDWORD TotalEntries,
|
||
|
[in,out,unique] LPDWORD ResumeHandle
|
||
|
);
|
||
|
|
||
|
//
|
||
|
// NetrWkstaTransportAdd
|
||
|
//
|
||
|
NET_API_STATUS
|
||
|
NetrWkstaTransportAdd (
|
||
|
[in,string,unique] WKSSVC_IDENTIFY_HANDLE ServerName,
|
||
|
[in] DWORD Level,
|
||
|
[in] LPWKSTA_TRANSPORT_INFO_0 TransportInfo,
|
||
|
[in,out,unique] LPDWORD ErrorParameter
|
||
|
);
|
||
|
|
||
|
//
|
||
|
// NetrWkstaTransportDel
|
||
|
//
|
||
|
NET_API_STATUS
|
||
|
NetrWkstaTransportDel (
|
||
|
[in,string,unique] WKSSVC_IDENTIFY_HANDLE ServerName,
|
||
|
[in,string,unique] LPTSTR TransportName,
|
||
|
[in] DWORD ForceLevel
|
||
|
);
|
||
|
|
||
|
|
||
|
|
||
|
//
|
||
|
// NetrUseAdd and NetrUseGetInfo
|
||
|
//
|
||
|
typedef [switch_type(unsigned long)] union _USE_INFO {
|
||
|
[case(0)]
|
||
|
LPUSE_INFO_0 UseInfo0;
|
||
|
[case(1)]
|
||
|
LPUSE_INFO_1 UseInfo1;
|
||
|
[case(2)]
|
||
|
LPUSE_INFO_2 UseInfo2;
|
||
|
[case(3)]
|
||
|
LPUSE_INFO_3 UseInfo3;
|
||
|
[default]
|
||
|
;
|
||
|
} USE_INFO, *PUSE_INFO, *LPUSE_INFO;
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrUseAdd (
|
||
|
[in,string,unique] WKSSVC_IMPERSONATE_HANDLE ServerName,
|
||
|
[in] DWORD Level,
|
||
|
[in, switch_is(Level)] LPUSE_INFO InfoStruct,
|
||
|
[in,out,unique] LPDWORD ErrorParameter
|
||
|
);
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrUseGetInfo (
|
||
|
[in,string,unique] WKSSVC_IMPERSONATE_HANDLE ServerName,
|
||
|
[in,string] LPTSTR UseName,
|
||
|
[in] DWORD Level,
|
||
|
[out, switch_is(Level)] LPUSE_INFO InfoStruct
|
||
|
);
|
||
|
|
||
|
|
||
|
|
||
|
//
|
||
|
// NetrUseDel
|
||
|
//
|
||
|
NET_API_STATUS
|
||
|
NetrUseDel (
|
||
|
[in,string,unique] WKSSVC_IMPERSONATE_HANDLE ServerName,
|
||
|
[in,string] LPTSTR UseName,
|
||
|
[in] DWORD ForceLevel
|
||
|
);
|
||
|
|
||
|
|
||
|
//
|
||
|
// NetrUseEnum
|
||
|
//
|
||
|
typedef struct _USE_INFO_0_CONTAINER {
|
||
|
DWORD EntriesRead;
|
||
|
[size_is(EntriesRead)] LPUSE_INFO_0 Buffer;
|
||
|
} USE_INFO_0_CONTAINER, *PUSE_INFO_0_CONTAINER, *LPUSE_INFO_0_CONTAINER;
|
||
|
|
||
|
typedef struct _USE_INFO_1_CONTAINER {
|
||
|
DWORD EntriesRead;
|
||
|
[size_is(EntriesRead)] LPUSE_INFO_1 Buffer;
|
||
|
} USE_INFO_1_CONTAINER, *PUSE_INFO_1_CONTAINER, *LPUSE_INFO_1_CONTAINER;
|
||
|
|
||
|
typedef struct _USE_INFO_2_CONTAINER {
|
||
|
DWORD EntriesRead;
|
||
|
[size_is(EntriesRead)] LPUSE_INFO_2 Buffer;
|
||
|
} USE_INFO_2_CONTAINER, *PUSE_INFO_2_CONTAINER, *LPUSE_INFO_2_CONTAINER;
|
||
|
|
||
|
typedef struct _USE_ENUM_STRUCT {
|
||
|
DWORD Level;
|
||
|
[switch_is(Level)] union _USE_ENUM_UNION {
|
||
|
[case(0)]
|
||
|
LPUSE_INFO_0_CONTAINER Level0;
|
||
|
[case(1)]
|
||
|
LPUSE_INFO_1_CONTAINER Level1;
|
||
|
[case(2)]
|
||
|
LPUSE_INFO_2_CONTAINER Level2;
|
||
|
[default]
|
||
|
;
|
||
|
} UseInfo;
|
||
|
|
||
|
}USE_ENUM_STRUCT, *PUSE_ENUM_STRUCT, *LPUSE_ENUM_STRUCT;
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrUseEnum (
|
||
|
[in,string,unique] WKSSVC_IDENTIFY_HANDLE ServerName,
|
||
|
[in,out] LPUSE_ENUM_STRUCT InfoStruct,
|
||
|
[in] DWORD PreferedMaximumLength,
|
||
|
[out] LPDWORD TotalEntries,
|
||
|
[in,out,unique] LPDWORD ResumeHandle
|
||
|
);
|
||
|
|
||
|
//
|
||
|
// NetrMessageBufferSend
|
||
|
//
|
||
|
NET_API_STATUS
|
||
|
NetrMessageBufferSend (
|
||
|
[in,string,unique] WKSSVC_IMPERSONATE_HANDLE ServerName,
|
||
|
[in,string] LPTSTR MessageName,
|
||
|
[in,string,unique] LPTSTR FromName,
|
||
|
[in,size_is(MessageSize)] LPBYTE Message,
|
||
|
[in] DWORD MessageSize
|
||
|
);
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrWorkstationStatisticsGet(
|
||
|
[in,string,unique] WKSSVC_IDENTIFY_HANDLE ServerName,
|
||
|
[in,string,unique] LPTSTR ServiceName,
|
||
|
[in] DWORD Level,
|
||
|
[in] DWORD Options,
|
||
|
[out] LPSTAT_WORKSTATION_0* Buffer
|
||
|
);
|
||
|
|
||
|
//
|
||
|
// I_NetrLogonDomainNameAdd
|
||
|
//
|
||
|
NET_API_STATUS
|
||
|
I_NetrLogonDomainNameAdd(
|
||
|
[in,string] WKSSVC_IDENTIFY_HANDLE LogonDomain
|
||
|
);
|
||
|
|
||
|
//
|
||
|
// I_NetrLogonDomainNameDel
|
||
|
//
|
||
|
NET_API_STATUS
|
||
|
I_NetrLogonDomainNameDel(
|
||
|
[in,string] WKSSVC_IDENTIFY_HANDLE LogonDomain
|
||
|
);
|
||
|
|
||
|
//
|
||
|
// Net join apis
|
||
|
//
|
||
|
NET_API_STATUS
|
||
|
NetrJoinDomain(
|
||
|
[in,string,unique] WKSSVC_IMPERSONATE_HANDLE ServerName,
|
||
|
[in,string] LPTSTR DomainName,
|
||
|
[in,string,unique] LPTSTR MachineAccountOU,
|
||
|
[in,string,unique] LPTSTR AccountName,
|
||
|
[in,string,unique] LPTSTR Password,
|
||
|
[in] DWORD Options
|
||
|
);
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrUnjoinDomain(
|
||
|
[in,string,unique] WKSSVC_IMPERSONATE_HANDLE ServerName,
|
||
|
[in,string,unique] LPTSTR AccountName,
|
||
|
[in,string,unique] LPTSTR Password,
|
||
|
[in] DWORD Options
|
||
|
);
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrRenameMachineInDomain(
|
||
|
[in,string,unique] WKSSVC_IMPERSONATE_HANDLE ServerName,
|
||
|
[in,string,unique] LPTSTR MachineName,
|
||
|
[in,string,unique] LPTSTR AccountName,
|
||
|
[in,string,unique] LPTSTR Password,
|
||
|
[in] DWORD Options
|
||
|
);
|
||
|
|
||
|
|
||
|
//
|
||
|
// Determine the validity of a name
|
||
|
//
|
||
|
NET_API_STATUS
|
||
|
NetrValidateName(
|
||
|
[in,string,unique] WKSSVC_IMPERSONATE_HANDLE ServerName,
|
||
|
[in,string] LPTSTR NameToValidate,
|
||
|
[in,string,unique] LPTSTR AccountName,
|
||
|
[in,string,unique] LPTSTR Password,
|
||
|
[in] NETSETUP_NAME_TYPE NameType
|
||
|
);
|
||
|
|
||
|
//
|
||
|
// Determines whether a workstation is joined to a domain or not
|
||
|
//
|
||
|
NET_API_STATUS
|
||
|
NetrGetJoinInformation(
|
||
|
[in,string,unique] WKSSVC_IMPERSONATE_HANDLE ServerName,
|
||
|
[in,out,string] LPTSTR *NameBuffer,
|
||
|
[out] PNETSETUP_JOIN_STATUS BufferType
|
||
|
);
|
||
|
|
||
|
typedef struct _NETSETUPR_MACHINE_ACCOUNT_OUS {
|
||
|
[size_is( OUCount ), string ] LPWSTR *OUs;
|
||
|
DWORD OUCount;
|
||
|
} NETSETUPR_MACHINE_ACCOUNT_OUS, *PNETSETUPR_MACHINE_ACCOUNT_OUS,
|
||
|
*LPNETSETUPR_MACHINE_ACCOUNT_OUS;
|
||
|
|
||
|
typedef [string] LPWSTR OUSTRING;
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrGetJoinableOUs(
|
||
|
[in,string,unique] WKSSVC_IMPERSONATE_HANDLE ServerName,
|
||
|
[in,string] LPWSTR Domain,
|
||
|
[in,string,unique] LPWSTR Account,
|
||
|
[in,string,unique] LPWSTR Password,
|
||
|
[in,out] DWORD *OUCount,
|
||
|
[out,size_is(,*OUCount)] OUSTRING **OUs
|
||
|
);
|
||
|
|
||
|
//
|
||
|
// Join APIs with encrypted passwords
|
||
|
//
|
||
|
|
||
|
//
|
||
|
// Structure to pass an encrypted password over the wire. The Length is the
|
||
|
// length of the password, which should be placed at the end of the buffer.
|
||
|
//
|
||
|
#define JOIN_OBFUSCATOR_LENGTH 8
|
||
|
#define JOIN_MAX_PASSWORD_LENGTH PWLEN
|
||
|
|
||
|
typedef struct _JOINPR_USER_PASSWORD {
|
||
|
UCHAR Obfuscator[JOIN_OBFUSCATOR_LENGTH];
|
||
|
WCHAR Buffer[JOIN_MAX_PASSWORD_LENGTH];
|
||
|
ULONG Length;
|
||
|
} JOINPR_USER_PASSWORD, *PJOINPR_USER_PASSWORD;
|
||
|
|
||
|
//
|
||
|
// Buffer - contains random fill with the password filling up the end
|
||
|
// of the buffer (the last Length bytes).
|
||
|
// Length - Length, in bytes, of the buffer.
|
||
|
//
|
||
|
|
||
|
//
|
||
|
// This is the encrypted version of the above structure, and is passed
|
||
|
// on the wire.
|
||
|
//
|
||
|
|
||
|
typedef struct _JOINPR_ENCRYPTED_USER_PASSWORD {
|
||
|
UCHAR Buffer[ JOIN_OBFUSCATOR_LENGTH + (JOIN_MAX_PASSWORD_LENGTH * sizeof(WCHAR)) + sizeof(ULONG) ];
|
||
|
} JOINPR_ENCRYPTED_USER_PASSWORD, *PJOINPR_ENCRYPTED_USER_PASSWORD;
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrJoinDomain2(
|
||
|
[in] handle_t RpcBindingHandle,
|
||
|
[in,string,unique] LPTSTR ServerName,
|
||
|
[in,string] LPTSTR DomainName,
|
||
|
[in,string,unique] LPTSTR MachineAccountOU,
|
||
|
[in,string,unique] LPTSTR AccountName,
|
||
|
[in,unique] PJOINPR_ENCRYPTED_USER_PASSWORD Password,
|
||
|
[in] DWORD Options
|
||
|
);
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrUnjoinDomain2(
|
||
|
[in] handle_t RpcBindingHandle,
|
||
|
[in,string,unique] LPTSTR ServerName,
|
||
|
[in,string,unique] LPTSTR AccountName,
|
||
|
[in,unique] PJOINPR_ENCRYPTED_USER_PASSWORD Password,
|
||
|
[in] DWORD Options
|
||
|
);
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrRenameMachineInDomain2(
|
||
|
[in] handle_t RpcBindingHandle,
|
||
|
[in,string,unique] LPTSTR ServerName,
|
||
|
[in,string,unique] LPTSTR MachineName,
|
||
|
[in,string,unique] LPTSTR AccountName,
|
||
|
[in,unique] PJOINPR_ENCRYPTED_USER_PASSWORD Password,
|
||
|
[in] DWORD Options
|
||
|
);
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrValidateName2(
|
||
|
[in] handle_t RpcBindingHandle,
|
||
|
[in,string,unique] LPTSTR ServerName,
|
||
|
[in,string] LPTSTR NameToValidate,
|
||
|
[in,string,unique] LPTSTR AccountName,
|
||
|
[in,unique] PJOINPR_ENCRYPTED_USER_PASSWORD Password,
|
||
|
[in] NETSETUP_NAME_TYPE NameType
|
||
|
);
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrGetJoinableOUs2(
|
||
|
[in] handle_t RpcBindingHandle,
|
||
|
[in,string,unique] LPTSTR ServerName,
|
||
|
[in,string] LPWSTR Domain,
|
||
|
[in,string,unique] LPWSTR Account,
|
||
|
[in,unique] PJOINPR_ENCRYPTED_USER_PASSWORD Password,
|
||
|
[in,out] DWORD *OUCount,
|
||
|
[out,size_is(,*OUCount)] OUSTRING **OUs
|
||
|
);
|
||
|
|
||
|
//
|
||
|
// Computer rename preparation API
|
||
|
//
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrAddAlternateComputerName(
|
||
|
[in] handle_t RpcBindingHandle,
|
||
|
[in,string,unique] LPTSTR ServerName,
|
||
|
[in,string,unique] LPTSTR AlternateName,
|
||
|
[in,string,unique] LPTSTR DomainAccount,
|
||
|
[in,unique] PJOINPR_ENCRYPTED_USER_PASSWORD EncryptedPassword,
|
||
|
[in] DWORD Options
|
||
|
);
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrRemoveAlternateComputerName(
|
||
|
[in] handle_t RpcBindingHandle,
|
||
|
[in,string,unique] LPTSTR ServerName,
|
||
|
[in,string,unique] LPTSTR AlternateName,
|
||
|
[in,string,unique] LPTSTR DomainAccount,
|
||
|
[in,unique] PJOINPR_ENCRYPTED_USER_PASSWORD EncryptedPassword,
|
||
|
[in] DWORD Options
|
||
|
);
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrSetPrimaryComputerName(
|
||
|
[in] handle_t RpcBindingHandle,
|
||
|
[in,string,unique] LPTSTR ServerName,
|
||
|
[in,string,unique] LPTSTR PrimaryName,
|
||
|
[in,string,unique] LPTSTR DomainAccount,
|
||
|
[in,unique] PJOINPR_ENCRYPTED_USER_PASSWORD EncryptedPassword,
|
||
|
[in] DWORD Options
|
||
|
);
|
||
|
|
||
|
typedef struct _NET_COMPUTER_NAME_ARRAY {
|
||
|
ULONG EntryCount;
|
||
|
[size_is(EntryCount)] PUNICODE_STRING ComputerNames;
|
||
|
} NET_COMPUTER_NAME_ARRAY, *PNET_COMPUTER_NAME_ARRAY;
|
||
|
|
||
|
NET_API_STATUS
|
||
|
NetrEnumerateComputerNames(
|
||
|
[in,string,unique] WKSSVC_IMPERSONATE_HANDLE ServerName,
|
||
|
[in] NET_COMPUTER_NAME_TYPE NameType,
|
||
|
[in] DWORD Options,
|
||
|
[out] PNET_COMPUTER_NAME_ARRAY *ComputerNames
|
||
|
);
|
||
|
}
|