6 Appendix A: Full IDL

For ease of implementation the full IDL is provided below, where "ms-dtyp.idl" refers to the IDL found in [MS-DTYP] Appendix A. The syntax uses the IDL syntax extensions defined in [MS-RPCE] section 2.2.4 and 3.1.1.5.1. For example, as noted in [MS-RPCE] section 2.2.4.9, a pointer_default declaration is not required and pointer_default(unique) is assumed.

The MessageBuffer field in the RESP_ASYNC_NOTIFY structure contains either a RESOURCE_CHANGE or an IPADDR_INFO_LIST structure. See sections 2.2.2.3 and 2.2.2.2 for details.

  
 import "ms-dtyp.idl";
 typedef [context_handle] void * PCONTEXT_HANDLE;
 typedef [context_handle] PCONTEXT_HANDLE PCONTEXT_HANDLE_SHARED;
 typedef [ref] PCONTEXT_HANDLE * PPCONTEXT_HANDLE;
  
 typedef struct _RESP_ASYNC_NOTIFY {
     UINT MessageType;
     UINT Length;
     UINT NumberOfMessages;
     [size_is(Length)] [unique] PBYTE MessageBuffer;
 } RESP_ASYNC_NOTIFY, *PRESP_ASYNC_NOTIFY;
  
 typedef struct _WITNESS_INTERFACE_INFO {
     WCHAR InterfaceGroupName[260];
     ULONG Version;
     USHORT State;
     ULONG IPV4;
     USHORT IPV6[8];
     UINT Flags;
 } WITNESS_INTERFACE_INFO, *PWITNESS_INTERFACE_INFO;
  
 typedef struct _WITNESS_INTERFACE_LIST {
     UINT NumberOfInterfaces;
     [size_is(NumberOfInterfaces)] [unique] PWITNESS_INTERFACE_INFO InterfaceInfo;
 } WITNESS_INTERFACE_LIST, *PWITNESS_INTERFACE_LIST;
  
 [uuid(ccd8c074-d0e5-4a40-92b4-d074faa6ba28)]
 [version(1.1)]
 [pointer_default(unique)]
 interface Witness {
     DWORD WitnessrGetInterfaceList(
         [in] handle_t Handle,
         [out] PWITNESS_INTERFACE_LIST * InterfaceList);
     DWORD WitnessrRegister(
         [in] handle_t Handle,
         [out] PPCONTEXT_HANDLE ppContext,
         [in] ULONG Version,
         [in] [string] [unique] LPWSTR NetName,
         [in] [string] [unique] LPWSTR IpAddress,
         [in] [string] [unique] LPWSTR ClientComputerName);
     DWORD WitnessrUnRegister(
         [in] handle_t Handle,
         [in] PCONTEXT_HANDLE pContext);
     DWORD WitnessrAsyncNotify(
         [in] handle_t Handle,
         [in] PCONTEXT_HANDLE_SHARED pContext,
         [out] PRESP_ASYNC_NOTIFY * pResp);
     DWORD WitnessrRegisterEx(
         [in] handle_t Handle,
         [out] PPCONTEXT_HANDLE ppContext,
         [in] ULONG Version,
         [in] [string] [unique] LPWSTR NetName,
         [in] [string] [unique] LPWSTR ShareName,
         [in] [string] [unique] LPWSTR IpAddress,
         [in] [string] [unique] LPWSTR ClientComputerName,
         [in] ULONG Flags,
         [in] ULONG KeepAliveTimeout);
 };
  
  
Show: