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.

173 lines
4.8 KiB

  1. /*****************************************************************/
  2. /** Microsoft Windows **/
  3. /** Copyright (C) Microsoft Corp., 1993-5 **/
  4. /*****************************************************************/
  5. /*
  6. SEC32API.H
  7. This header file contains declarations for the internal versions
  8. of the 32-bit Access API, as exported by FILESEC.386. It also
  9. contains constant definitions used by securty components
  10. This file relies, in part, on NETVXD.H and VXDCALL.H.
  11. This file must be H2INC-able.
  12. FILE HISTORY:
  13. dannygl 09/25/93 Initial version
  14. dannygl 09/29/93 Add NetAccessSetInfo
  15. dannygl 10/04/93 Add security-related string constants
  16. dannygl 01/17/94 Replace Win32 services with IOCtls
  17. dannygl 02/10/94 Add NetAccess arg count constants
  18. dannygl 02/16/94 Update registry string constants
  19. dannygl 11/17/94 Add Logon2 API (supported by MSSP only)
  20. */
  21. // Registry string constants
  22. // Security provider information (in HKEY_LOCAL_MACHINE)
  23. #define REGKEY_SP_CONFIG "Security\\Provider"
  24. #define REGVAL_SP_PLATFORM "Platform_Type"
  25. #define REGVAL_SP_CONTAINER "Container"
  26. #define REGVAL_SP_ABSERVER "Address_Server"
  27. #define REGVAL_SP_ONEOFFABSERVER "One_Off_Address_Server"
  28. #define REGVAL_SP_ABPROVIDER "Address_Book"
  29. #define REGVAL_SP_NO_SORT "NoSort"
  30. // Obsolescent definition -- will be deleted soon
  31. //#define REGVAL_SP_PTPROVIDER "Pass_Through"
  32. // Definitions for the IOControl interface that FILESEC uses for Win32 API
  33. // support
  34. #define FSIOC_API_Base 100
  35. /*XLATOFF*/
  36. typedef enum
  37. {
  38. FSIOC_AccessAddAPI = FSIOC_API_Base,
  39. FSIOC_AccessCheckAPI,
  40. FSIOC_AccessDelAPI,
  41. FSIOC_AccessEnumAPI,
  42. FSIOC_AccessGetInfoAPI,
  43. FSIOC_AccessGetUserPermsAPI,
  44. FSIOC_AccessSetInfoAPI
  45. } FSIOC_Ordinal;
  46. /*XLATON*/
  47. // Important: We define this constant separately because we need it
  48. // to be H2INC'able. It must match the above enumerated type.
  49. #define FSIOC_API_Count 7
  50. // Arg counts for Access functions
  51. //
  52. // Note: These constants are defined for readability purposes and should not
  53. // be modified independently.
  54. #define Argc_AccessAdd 3
  55. #define Argc_AccessCheck 4
  56. #define Argc_AccessDel 1
  57. #define Argc_AccessEnum 7
  58. #define Argc_AccessGetInfo 5
  59. #define Argc_AccessGetUserPerms 3
  60. #define Argc_AccessSetInfo 5
  61. // Definitions used by the Security Provider VxDs to expose interfaces
  62. // to Win32 code via IOCtls
  63. #define SPIOC_API_Base 100
  64. /*XLATOFF*/
  65. typedef enum
  66. {
  67. SPIOC_PreLogonAPI = SPIOC_API_Base,
  68. SPIOC_LogonAPI,
  69. SPIOC_LogoffAPI,
  70. SPIOC_GetFlagsAPI,
  71. SPIOC_GetContainerAPI,
  72. SPIOC_NW_GetUserObjectId, // NWSP only
  73. SPIOC_Logon2API, // Currently MSSP only
  74. SPIOC_DiscoverDC // MSSP only
  75. } SPIOC_Ordinal;
  76. /*XLATON*/
  77. // Important: We define this constant separately because we need it
  78. // to be H2INC'able. It must match the above enumerated type.
  79. #define SPIOC_API_Count 8
  80. /*XLATOFF*/
  81. typedef struct
  82. {
  83. unsigned char *pbChallenge;
  84. unsigned long *pcbChallenge;
  85. } AUTHPRELOGONINFO, *PAUTHPRELOGONINFO;
  86. typedef struct
  87. {
  88. const char *pszContainer;
  89. const char *pszUserName;
  90. const char *pszClientName;
  91. const unsigned char *pbResponse;
  92. unsigned long cbResponse;
  93. const unsigned char *pbChallenge;
  94. unsigned long cbChallenge;
  95. unsigned long fResponseType;
  96. unsigned long *pfResult;
  97. } AUTHLOGONINFO, *PAUTHLOGONINFO;
  98. typedef struct
  99. {
  100. const char *pszContainer;
  101. char *pszContainerValidated;
  102. const char *pszUserName;
  103. char *pszUserValidated;
  104. const char *pszClientName;
  105. const unsigned char *pbResponse;
  106. unsigned long cbResponse;
  107. const unsigned char *pbResponse2;
  108. unsigned long cbResponse2;
  109. const unsigned char *pbChallenge;
  110. unsigned long cbChallenge;
  111. unsigned long *pfFlags;
  112. unsigned long *pfResult;
  113. } AUTHLOGON2INFO, *PAUTHLOGON2INFO;
  114. typedef struct
  115. {
  116. const char *pszContainer;
  117. const char *pszUserName;
  118. const char *pszClientName;
  119. } AUTHLOGOFFINFO, *PAUTHLOGOFFINFO;
  120. typedef struct
  121. {
  122. unsigned long *pdwFlags;
  123. unsigned long *pdwSecurity;
  124. } AUTHGETFLAGS, *PAUTHGETFLAGS;
  125. typedef struct
  126. {
  127. char *pszContainer;
  128. unsigned long *pcbContainer;
  129. } AUTHGETCONTAINER, *PAUTHGETCONTAINER;
  130. typedef struct
  131. {
  132. char *pszUserName;
  133. unsigned long dwObjectId;
  134. } AUTHNWGETUSEROBJECTID, *PAUTHNWGETUSEROBJECTID;
  135. typedef struct
  136. {
  137. const char *pszDomain;
  138. char *pszDCs; // Concatenated strings, ended with an extra null
  139. unsigned long *pcbDCs;
  140. } AUTHDISCOVERDC, *PAUTHDISCOVERDC;
  141. /*XLATON*/