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.

162 lines
7.7 KiB

  1. //+-------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. //
  5. // Copyright (C) Microsoft Corporation, 1997 - 1999
  6. //
  7. // File: sclgnrpc.idl
  8. //
  9. //--------------------------------------------------------------------------
  10. import "unknwn.idl";
  11. #define NTSTATUS LONG
  12. typedef struct _OUT_BUFFER1 {
  13. DWORD cb;
  14. [size_is(cb)] BYTE *pb;
  15. } OUT_BUFFER1, *POUT_BUFFER1;
  16. typedef struct _OUT_BUFFER2 {
  17. ULONG cb;
  18. [size_is(cb)] BYTE *pb;
  19. } OUT_BUFFER2, *POUT_BUFFER2;
  20. ////////////////////////////
  21. // Interfaces
  22. [
  23. uuid(95958c94-a424-4055-b62b-b7f4d5c47770),
  24. version(1.0),
  25. pointer_default(unique)
  26. ]
  27. interface IRPCSCLogon
  28. {
  29. typedef [context_handle] void *BINDING_CONTEXT;
  30. NTSTATUS
  31. RPC_ScHelperInitializeContext(
  32. [in] handle_t h,
  33. [in] DWORD cbLogonInfo,
  34. [in][size_is(cbLogonInfo)] BYTE *pbLogonInfo,
  35. [in, out] BINDING_CONTEXT *pBindingContext
  36. );
  37. NTSTATUS
  38. RPC_ScHelperRelease(
  39. [in] handle_t h,
  40. [in, out] BINDING_CONTEXT *pBindingContext
  41. );
  42. NTSTATUS
  43. RPC_ScHelperGetCertFromLogonInfo(
  44. [in] handle_t h,
  45. [in] BINDING_CONTEXT BindingContext,
  46. [in][unique] LPCWSTR wszPIN,
  47. [out] OUT_BUFFER1 *pCertContextBuffer
  48. );
  49. NTSTATUS
  50. RPC_ScHelperGetProvParam(
  51. [in] handle_t h,
  52. [in] BINDING_CONTEXT BindingContext,
  53. [in][unique] LPCWSTR wszPIN,
  54. [in] DWORD dwParam,
  55. [in][out] DWORD *pdwDataLen,
  56. [out] OUT_BUFFER1 *pbData,
  57. [in] DWORD dwFlags
  58. );
  59. NTSTATUS
  60. RPC_ScHelperGenRandBits(
  61. [in] handle_t h,
  62. [in] BINDING_CONTEXT BindingContext,
  63. [in][out] BYTE bR1[32],
  64. [in][out] BYTE bR2[32]
  65. );
  66. NTSTATUS
  67. RPC_ScHelperVerifyCardAndCreds(
  68. [in] handle_t h,
  69. [in] BINDING_CONTEXT BindingContext,
  70. [in][unique] LPCWSTR wszPIN,
  71. [in] ULONG EncryptedDataSize,
  72. [in][size_is(EncryptedDataSize)] BYTE *EncryptedData,
  73. [in][out] ULONG *pCleartextDataSize,
  74. [out] OUT_BUFFER2 *pCleartextData
  75. );
  76. NTSTATUS
  77. RPC_ScHelperEncryptCredentials(
  78. [in] handle_t h,
  79. [in] BINDING_CONTEXT BindingContext,
  80. [in][unique] LPCWSTR wszPIN,
  81. [in] BYTE bR1[32],
  82. [in] BYTE bR2[32],
  83. [in] ULONG CleartextDataSize,
  84. [in][size_is(CleartextDataSize)] BYTE *CleartextData,
  85. [in][out] ULONG *pEncryptedDataSize,
  86. [out] OUT_BUFFER2 *pEncryptedData
  87. );
  88. NTSTATUS
  89. RPC_ScHelperSignMessage(
  90. [in] handle_t h,
  91. [in] BINDING_CONTEXT BindingContext,
  92. [in][unique] LPCWSTR wszPIN,
  93. [in] ULONG Algorithm,
  94. [in] ULONG BufferLength,
  95. [in][size_is(BufferLength)] BYTE *Buffer,
  96. [in][out] ULONG *pSignatureLength,
  97. [out] OUT_BUFFER2 *pSignature
  98. );
  99. NTSTATUS
  100. RPC_ScHelperVerifyMessage(
  101. [in] handle_t h,
  102. [in] BINDING_CONTEXT BindingContext,
  103. [in] ULONG Algorithm,
  104. [in] ULONG BufferLength,
  105. [in][size_is(BufferLength)] BYTE *Buffer,
  106. [in] ULONG SignatureLength,
  107. [in][size_is(SignatureLength)] BYTE *Signature
  108. );
  109. NTSTATUS
  110. RPC_ScHelperSignPkcsMessage(
  111. [in] handle_t h,
  112. [in] BINDING_CONTEXT BindingContext,
  113. [in][unique] LPCWSTR wszPIN,
  114. [in] LPSTR AlgorithmPszObjId,
  115. [in] DWORD AlgorithmParametersLength,
  116. [in][unique][size_is(AlgorithmParametersLength)] BYTE *AlgorithmParameters,
  117. [in] DWORD dwSignMessageFlags,
  118. [in] ULONG BufferLength,
  119. [in][size_is(BufferLength)] BYTE *Buffer,
  120. [in][out] ULONG *pSignedBufferLength,
  121. [out] OUT_BUFFER2 *pSignedBuffer
  122. );
  123. NTSTATUS
  124. RPC_ScHelperVerifyPkcsMessage(
  125. [in] handle_t h,
  126. [in] BINDING_CONTEXT BindingContext,
  127. [in] ULONG BufferLength,
  128. [in][size_is(BufferLength)] BYTE *Buffer,
  129. [in][out] ULONG *pDecodedBufferLength,
  130. [out] OUT_BUFFER2 *pDecodedBuffer,
  131. [in] BOOL fCertContextRequested,
  132. [out] OUT_BUFFER1 *pCertContext
  133. );
  134. NTSTATUS
  135. RPC_ScHelperDecryptMessage(
  136. [in] handle_t h,
  137. [in] BINDING_CONTEXT BindingContext,
  138. [in][unique] LPCWSTR wszPIN,
  139. [in] ULONG CipherLength,
  140. [in][size_is(CipherLength)] BYTE *CipherText,
  141. [in][out] ULONG *pClearTextLength,
  142. [out] OUT_BUFFER2 *pClearText
  143. );
  144. }