Source code of Windows XP (NT5)
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.

157 lines
2.8 KiB

  1. /*++
  2. Copyright (c) 1998 Microsoft Corporation
  3. Module Name:
  4. ipc.h
  5. Abstract:
  6. Implements IPC interface to allow setup to talk with migisol.exe,
  7. in order to run migration DLLs in separate processes.
  8. Author:
  9. Jim Schmidt (jimschm) 28-Mar-1997
  10. Revision History:
  11. jimschm 23-Sep-1998 Changed from mailslots to memory mapped files
  12. --*/
  13. #pragma once
  14. BOOL
  15. IpcOpenW (
  16. IN BOOL Win95Side,
  17. IN PCWSTR ExePath, OPTIONAL
  18. IN PCWSTR MigrationDllPath, OPTIONAL
  19. IN PCWSTR WorkingDir OPTIONAL
  20. );
  21. BOOL
  22. IpcOpenA (
  23. IN BOOL Win95Side,
  24. IN PCSTR ExePath, OPTIONAL
  25. IN PCSTR MigrationDllPath, OPTIONAL
  26. IN PCSTR WorkingDir OPTIONAL
  27. );
  28. DWORD
  29. IpcCheckForWaitingData (
  30. IN HANDLE Slot,
  31. IN DWORD MinimumSize,
  32. IN DWORD Timeout
  33. );
  34. BOOL
  35. IpcProcessAlive (
  36. VOID
  37. );
  38. VOID
  39. IpcKillProcess (
  40. VOID
  41. );
  42. BOOL
  43. IpcSendCommand (
  44. IN DWORD Command,
  45. IN PBYTE Data, OPTIONAL
  46. IN DWORD DataSize
  47. );
  48. BOOL
  49. IpcGetCommandResults (
  50. IN DWORD Timeout,
  51. OUT PBYTE *ReturnData, OPTIONAL
  52. OUT PDWORD ReturnDataSize, OPTIONAL
  53. OUT PDWORD ResultCode, OPTIONAL
  54. OUT PDWORD TechnicalLogId, OPTIONAL
  55. OUT PDWORD GuiLogId OPTIONAL
  56. );
  57. BOOL
  58. IpcGetCommand (
  59. IN DWORD Timeout,
  60. IN PDWORD Command, OPTIONAL
  61. IN PBYTE *Data, OPTIONAL
  62. IN PDWORD DataSize OPTIONAL
  63. );
  64. BOOL
  65. IpcSendCommandResults (
  66. IN DWORD ResultCode,
  67. IN DWORD TechnicalLogId,
  68. IN DWORD GuiLogId,
  69. IN PBYTE Data, OPTIONAL
  70. IN DWORD DataSize
  71. );
  72. #define IPC_GET_RESULTS_WIN9X 1000
  73. #define IPC_GET_RESULTS_NT 7500
  74. #define IPC_GET_COMMAND_WIN9X 10000
  75. #define IPC_GET_COMMAND_NT 10000
  76. #ifdef UNICODE
  77. #define IpcOpen IpcOpenW
  78. #else
  79. #define IpcOpen IpcOpenA
  80. #endif
  81. VOID
  82. IpcClose (
  83. VOID
  84. );
  85. typedef LONG (WINAPI WINVERIFYTRUST_PROTOTYPE)(HWND hwnd, GUID *ActionId, PVOID Data);
  86. typedef WINVERIFYTRUST_PROTOTYPE * WINVERIFYTRUST;
  87. BOOL
  88. IsDllSignedA (
  89. IN WINVERIFYTRUST WinVerifyTrustApi,
  90. IN PCSTR DllSpec
  91. );
  92. BOOL
  93. IsDllSignedW (
  94. IN WINVERIFYTRUST WinVerifyTrustApi,
  95. IN PCWSTR DllSpec
  96. );
  97. #ifdef UNICODE
  98. #define IsDllSigned IsDllSignedW
  99. #else
  100. #define IsDllSigned IsDllSignedA
  101. #endif
  102. //
  103. // Remote commands
  104. //
  105. #define IPC_QUERY 1
  106. #define IPC_INITIALIZE 2
  107. #define IPC_MIGRATEUSER 3
  108. #define IPC_MIGRATESYSTEM 4
  109. #define IPC_TERMINATE 5
  110. #define IPC_DVDCHECK 6
  111. //
  112. // APIs implemented in IPC
  113. //
  114. BOOL
  115. IsolatedIsDvdPresentA (
  116. PCSTR ExePath
  117. );