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.

119 lines
3.0 KiB

  1. //+-----------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. //
  5. // Copyright (c) Microsoft Corporation 1992 - 1996
  6. //
  7. // File: pkauth.h
  8. //
  9. // Contents: Structures and prototypes for public key kerberos
  10. //
  11. //
  12. // History: 14-October-1997 Created MikeSw
  13. //
  14. //------------------------------------------------------------------------
  15. #ifndef __PKAUTH_H__
  16. #define __PKAUTH_H__
  17. VOID
  18. KerbFreePKCreds(
  19. IN PKERB_PUBLIC_KEY_CREDENTIALS PkCreds,
  20. IN BOOLEAN OkForReuse
  21. );
  22. BOOLEAN
  23. KerbRetrieveDomainFromDn(
  24. IN PCCERT_CONTEXT Cert,
  25. IN OUT PUNICODE_STRING CrackedDomain
  26. );
  27. BOOL
  28. KerbComparePublicKeyCreds(
  29. IN PKERB_PUBLIC_KEY_CREDENTIALS PkCreds1,
  30. IN PKERB_PUBLIC_KEY_CREDENTIALS PkCreds2
  31. );
  32. NTSTATUS
  33. KerbBuildPkinitPreauthData(
  34. IN PKERB_PRIMARY_CREDENTIAL Credentials,
  35. IN OPTIONAL PKERB_PA_DATA_LIST InputPaData,
  36. IN PTimeStamp TimeSkew,
  37. IN PKERB_INTERNAL_NAME ServiceName,
  38. IN PUNICODE_STRING RealmName,
  39. IN ULONG Nonce,
  40. IN OUT PKERB_PA_DATA_LIST * PreAuthData,
  41. OUT PKERB_ENCRYPTION_KEY EncryptionKey,
  42. OUT PKERB_CRYPT_LIST * CryptList,
  43. OUT PBOOLEAN Done
  44. );
  45. NTSTATUS
  46. KerbCreateSmartCardLogonSessionFromCertContext(
  47. IN PCERT_CONTEXT *ppCertContext,
  48. IN PLUID pLogonId,
  49. IN PUNICODE_STRING pAuthorityName,
  50. IN PUNICODE_STRING pPin,
  51. IN PUCHAR pCspData,
  52. IN ULONG CspDataLength,
  53. OUT PKERB_LOGON_SESSION *ppLogonSession,
  54. OUT PUNICODE_STRING pAccountName
  55. );
  56. NTSTATUS
  57. KerbCreateSmartCardLogonSession(
  58. IN PVOID ProtocolSubmitBuffer,
  59. IN PVOID ClientBufferBase,
  60. IN ULONG SubmitBufferSize,
  61. IN SECURITY_LOGON_TYPE LogonType,
  62. OUT PKERB_LOGON_SESSION *ReturnedLogonSession,
  63. OUT PLUID ReturnedLogonId,
  64. OUT PUNICODE_STRING AccountName,
  65. OUT PUNICODE_STRING AuthorityName
  66. );
  67. NTSTATUS
  68. KerbDoLocalSmartCardLogon(
  69. IN PKERB_LOGON_SESSION LogonSession,
  70. OUT PLSA_TOKEN_INFORMATION_TYPE TokenInformationType,
  71. OUT PVOID *NewTokenInformation,
  72. OUT PULONG ProfileBufferLength,
  73. OUT PVOID * ProfileBuffer,
  74. OUT PSECPKG_PRIMARY_CRED PrimaryCredentials,
  75. OUT PSECPKG_SUPPLEMENTAL_CRED_ARRAY * CachedCredentials,
  76. IN OUT PNETLOGON_VALIDATION_SAM_INFO4 * Validation4
  77. );
  78. VOID
  79. KerbCacheSmartCardLogon(
  80. IN PNETLOGON_VALIDATION_SAM_INFO3 ValidationInfo,
  81. IN PUNICODE_STRING DnsDomain,
  82. IN OPTIONAL PUNICODE_STRING UPN,
  83. IN PKERB_LOGON_SESSION LogonSession,
  84. IN OPTIONAL PSECPKG_SUPPLEMENTAL_CRED_ARRAY CachedCredentials
  85. );
  86. NTSTATUS
  87. KerbInitializePkinit(
  88. VOID
  89. );
  90. NTSTATUS
  91. KerbInitializePkCreds(
  92. IN PKERB_PUBLIC_KEY_CREDENTIALS PkCreds
  93. );
  94. VOID
  95. KerbReleasePkCreds(
  96. IN OPTIONAL PKERB_LOGON_SESSION LogonSession,
  97. IN OPTIONAL PKERB_PUBLIC_KEY_CREDENTIALS PkCreds,
  98. IN BOOLEAN OkForReuse
  99. );
  100. NTSTATUS
  101. KerbMapCertChainError(ULONG ChainStatus, BOOLEAN Client);
  102. #endif // __PKAUTH_H__