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.

86 lines
1.9 KiB

  1. //+--------------------------------------------------------------------------
  2. //
  3. // Copyright (c) 1997-1999 Microsoft Corporation
  4. //
  5. // File: pid.h
  6. //
  7. // Contents:
  8. //
  9. // History:
  10. //
  11. //---------------------------------------------------------------------------
  12. #ifndef __PID_H__
  13. #define __PID_H__
  14. #include "srvdef.h"
  15. #define NTPID_REGISTRY _TEXT("Software\\Microsoft\\Windows NT\\CurrentVersion")
  16. #define NTPID_VALUE _TEXT("ProductId")
  17. #define TLSUNIQUEID_SIZE 3
  18. #define TLSUNIQUEID_SIZE_2 7
  19. #define TLSUNIQUEID_OFFSET_2 10
  20. #define NTPID_OEM_OFFSET 6
  21. #define NTPID_OEM_LENGTH 3
  22. #define NTPID_OEM _TEXT("OEM")
  23. #define NTPID_OEM_CHANNELID_OFFSET 12
  24. #define MAX_PID20_LENGTH 25
  25. #ifdef __cplusplus
  26. extern "C" {
  27. #endif
  28. DWORD
  29. TLSGeneratePid(
  30. OUT LPTSTR* pszTlsPid,
  31. OUT PDWORD pcbTlsPid,
  32. OUT LPTSTR* pszTlsUniqueId,
  33. OUT PDWORD pcbTlsUniqueId
  34. );
  35. DWORD
  36. LoadNtPidFromRegistry(
  37. OUT LPTSTR* ppbNtPid
  38. );
  39. DWORD
  40. ServerIdsToLsaServerId(
  41. IN PBYTE pbServerUniqueId,
  42. IN DWORD cbServerUniqueId,
  43. IN PBYTE pbServerPid,
  44. IN DWORD cbServerPid,
  45. IN PBYTE pbServerSPK,
  46. IN DWORD cbServerSPK,
  47. IN PCERT_EXTENSION pCertExtensions,
  48. IN DWORD dwNumCertExtensions,
  49. OUT PTLSLSASERVERID* ppLsaServerId,
  50. OUT DWORD* pdwLsaServerId
  51. );
  52. DWORD
  53. LsaServerIdToServerIds(
  54. IN PTLSLSASERVERID pLsaServerId,
  55. IN DWORD dwLsaServerId,
  56. OUT PBYTE* ppbServerUniqueId,
  57. OUT PDWORD pcbServerUniqueId,
  58. OUT PBYTE* ppbServerPid,
  59. OUT PDWORD pcbServerPid,
  60. OUT PBYTE* ppbServerSPK,
  61. OUT PDWORD pcbServerSPK,
  62. OUT PCERT_EXTENSIONS* pCertExtensions,
  63. OUT PDWORD pdwNumCertExtensions
  64. );
  65. #ifdef __cplusplus
  66. }
  67. #endif
  68. #endif