Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

105 lines
4.5 KiB

  1. /*******************************************************************************
  2. * utildll.h
  3. *
  4. * UTILDLL WinStation utility support functions header file (export stuff)
  5. *
  6. * Copyright (C) 1997, Citrix Systems Inc.
  7. * Copyright (C) 1997-1999 Microsoft Corp.
  8. *
  9. * $Author: butchd $ Butch Davis
  10. *******************************************************************************/
  11. #ifdef __cplusplus
  12. extern "C" {
  13. #endif
  14. /*
  15. * UTILDLL defines and typedefs
  16. */
  17. typedef struct _ELAPSEDTIME {
  18. USHORT days;
  19. USHORT hours;
  20. USHORT minutes;
  21. USHORT seconds;
  22. } ELAPSEDTIME, * PELAPSEDTIME;
  23. #define MAX_PROCESSNAME 18
  24. #define UTILDLL_NAME TEXT("UTILDLL.DLL")
  25. #define SYSTEM_MESSAGE_MAX 256
  26. #define MAX_ELAPSED_TIME_LENGTH 15
  27. #define MAX_DATE_TIME_LENGTH 16
  28. /*
  29. * UTILDLL function prototypes
  30. */
  31. void StandardErrorMessage( LPCTSTR pszAppName,
  32. HWND hwndApp,
  33. HINSTANCE hinstApp,
  34. ULONG LogonId,
  35. UINT nId,
  36. int nErrorResourceID, ...);
  37. LPWSTR WINAPI GetSystemMessageW( ULONG LogonId, UINT nId, LPWSTR chBuffer, int chBuffSize );
  38. LPSTR WINAPI GetSystemMessageA( ULONG LogonId, UINT nId, LPSTR chBuffer, int chBuffSize );
  39. #ifdef UNICODE
  40. #define GetSystemMessage GetSystemMessageW
  41. #else
  42. #define GetSystemMessage GetSystemMessageA
  43. #endif
  44. PPDPARAMS WINAPI WinEnumerateDevices( HWND hWnd,
  45. PPDCONFIG3 pPdConfig,
  46. PULONG pEntries,
  47. BOOL bInSetup );
  48. BOOL WINAPI NetworkDeviceEnumerate( PPDCONFIG3, PULONG, PPDPARAMS,
  49. PULONG, BOOL );
  50. BOOL WINAPI QueryCurrentWinStation( PWINSTATIONNAME pWSName, LPTSTR pUserName,
  51. PULONG pLogonId, PULONG pWSFlags );
  52. LONG WINAPI RegGetNetworkDeviceName( HANDLE hServer, PPDCONFIG3 pPdConfig,
  53. PPDPARAMS pPdParams, LPTSTR szDeviceName,
  54. int nDeviceName );
  55. LONG WINAPI RegGetNetworkServiceName( HANDLE hServer,
  56. LPTSTR szServiceKey,
  57. LPTSTR szServiceName,
  58. int nServiceName );
  59. BOOL WINAPI AsyncDeviceEnumerate( PPDCONFIG3, PULONG, PPDPARAMS,
  60. PULONG, BOOL );
  61. BOOL WINAPI NetBIOSDeviceEnumerate( PPDCONFIG3, PULONG, PPDPARAMS,
  62. PULONG, BOOL );
  63. void WINAPI FormDecoratedAsyncDeviceName( LPTSTR pDeviceName,
  64. PASYNCCONFIG pAsyncConfig );
  65. void WINAPI ParseDecoratedAsyncDeviceName( LPCTSTR pDeviceName,
  66. PASYNCCONFIG pAsyncConfig );
  67. void WINAPI SetupAsyncCdConfig( PASYNCCONFIG pAsyncConfig,
  68. PCDCONFIG pCdConfig );
  69. BOOL WINAPI InstallModem( HWND hwndOwner );
  70. BOOL WINAPI ConfigureModem( LPCTSTR pModemName, HWND hwndOwner );
  71. BOOL GetAssociatedPortName(char *szKeyName, WCHAR *wszPortName);
  72. void WINAPI InitializeAnonymousUserCompareList( const WCHAR *pszServer );
  73. BOOL WINAPI HaveAnonymousUsersChanged();
  74. void WINAPI GetUserFromSid( PSID pSid, LPTSTR pUserName, DWORD cbUserName );
  75. void WINAPI CachedGetUserFromSid( PSID pSid, PWCHAR pUserName, PULONG cbUserName );
  76. BOOL WINAPI TestUserForAdmin( BOOL dom );
  77. BOOL WINAPI IsPartOfDomain( VOID );
  78. LPCTSTR WINAPI StrSdClass( SDCLASS SdClass );
  79. LPCTSTR WINAPI StrConnectState( WINSTATIONSTATECLASS ConnectState,
  80. BOOL bShortString );
  81. LPCTSTR WINAPI StrProcessState( ULONG State );
  82. LPCTSTR WINAPI StrSystemWaitReason( ULONG WaitReason );
  83. LPCTSTR WINAPI GetUnknownString();
  84. void WINAPI CalculateElapsedTime( LARGE_INTEGER *pTime,
  85. ELAPSEDTIME *pElapsedTime );
  86. int WINAPI CompareElapsedTime( ELAPSEDTIME *pElapsedTime1,
  87. ELAPSEDTIME *pElapsedTime2,
  88. BOOL bCompareSeconds );
  89. void WINAPI ElapsedTimeString( ELAPSEDTIME *pElapsedTime,
  90. BOOL bIncludeSeconds,
  91. LPTSTR pString );
  92. void WINAPI DateTimeString( LARGE_INTEGER *pTime, LPTSTR pString );
  93. void WINAPI CurrentDateTimeString( LPTSTR pString );
  94. LARGE_INTEGER WINAPI CalculateDiffTime( LARGE_INTEGER, LARGE_INTEGER );
  95. LPWSTR WINAPI EnumerateMultiUserServers( LPWSTR pDomain );
  96. #ifdef __cplusplus
  97. }
  98. #endif