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.

112 lines
2.5 KiB

  1. //+-----------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. //
  5. // Copyright (c) Microsoft Corporation 1991 - 1995
  6. //
  7. // File: pac.hxx
  8. //
  9. // Contents: internal structures and definitions for PACs
  10. //
  11. //
  12. // History: 24-May-95 SuChang Created
  13. //
  14. //------------------------------------------------------------------------
  15. #ifndef __PAC2_HXX__
  16. #define __PAC2_HXX__
  17. typedef struct PAC_INFO_BUFFER2 {
  18. ULONG ulType;
  19. ULONG cbBufferSize;
  20. PBYTE pbBuffer;
  21. } PAC_INFO_BUFFER2, *PPAC_INFO_BUFFER2;
  22. typedef struct _PAC_CREDENTIAL_DATA2 {
  23. ULONG CredentialCount;
  24. SECPKG_SUPPLEMENTAL_CRED Credentials[ANYSIZE_ARRAY];
  25. } PAC_CREDENTIAL_DATA2, *PPAC_CREDENTIAL_DATA2;
  26. typedef struct _PAC_CREDENTIAL_INFO2 {
  27. ULONG Version;
  28. ULONG EncryptionType;
  29. UCHAR Data[ANYSIZE_ARRAY];
  30. } PAC_CREDENTIAL_INFO2, *PPAC_CREDENTIAL_INFO2;
  31. typedef struct _PACTYPE2 {
  32. ULONG cBuffers;
  33. PAC_INFO_BUFFER2 Buffers[ANYSIZE_ARRAY];
  34. } PACTYPE2, *PPACTYPE2;
  35. ULONG PAC2_GetSize( IN PACTYPE2 *pPac );
  36. ULONG PAC2_Marshal( IN PACTYPE2 *pPac,
  37. IN ULONG cbBuffer,
  38. OUT PBYTE pBuffer);
  39. ULONG
  40. PAC2_UnMarshal(
  41. IN PPACTYPE2 pBuffer,
  42. ULONG cbSize
  43. );
  44. BOOLEAN
  45. PAC2_ReMarshal( IN PPACTYPE2 pPac,
  46. IN ULONG cbSize );
  47. NTSTATUS
  48. PAC2_Init(
  49. IN PSAMPR_USER_ALL_INFORMATION UserAll,
  50. IN OPTIONAL PSAMPR_GET_GROUPS_BUFFER GroupsBuffer,
  51. IN OPTIONAL PSID_AND_ATTRIBUTES_LIST ExtraGroups,
  52. IN PSID LogonDomainId,
  53. IN PUNICODE_STRING LogonDomainName,
  54. IN PUNICODE_STRING LogonServer,
  55. IN ULONG SignatureSize,
  56. IN ULONG AdditionalDataCount,
  57. IN PPAC_INFO_BUFFER2 * AdditionalData,
  58. OUT PACTYPE2 ** ppPac
  59. );
  60. NTSTATUS
  61. PAC2_InitAndUpdateGroups(
  62. IN PNETLOGON_VALIDATION_SAM_INFO2 OldValidationInfo,
  63. IN PSAMPR_PSID_ARRAY ResourceGroups,
  64. IN PPACTYPE2 OldPac,
  65. OUT PACTYPE2 ** ppPac
  66. );
  67. PPAC_INFO_BUFFER2
  68. PAC2_Find( IN PPACTYPE2 pPac,
  69. IN ULONG ulType,
  70. IN PPAC_INFO_BUFFER2 pElem);
  71. NTSTATUS
  72. PAC2_UnmarshallValidationInfo(
  73. IN OUT PNETLOGON_VALIDATION_SAM_INFO2 ValidationInfo,
  74. IN ULONG ValidationSize
  75. );
  76. NTSTATUS
  77. PAC2_BuildCredentials(
  78. IN PSAMPR_USER_ALL_INFORMATION UserAll,
  79. OUT PBYTE * Credentials,
  80. OUT PULONG CredentialSize
  81. );
  82. NTSTATUS
  83. PAC2_UnmarshallCredentials(
  84. IN OUT PPAC_CREDENTIAL_DATA Credentials,
  85. IN PBYTE Base,
  86. IN ULONG CredentialSize
  87. );
  88. #endif // __PAC2_HXX__