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.

127 lines
2.3 KiB

  1. /*++
  2. Copyright (C) Microsoft Corporation, 1990 - 2000
  3. All rights reserved.
  4. Module Name:
  5. dbgsec.h
  6. Abstract:
  7. Header file for Spooler Subsystem Debugger Extensions
  8. Author:
  9. Krishna Ganugapati (KrishnaG) 08-July-1992
  10. Revision History:
  11. --*/
  12. //
  13. // Object types
  14. //
  15. #define SPOOLER_OBJECT_SERVER 0
  16. #define SPOOLER_OBJECT_PRINTER 1
  17. #define SPOOLER_OBJECT_DOCUMENT 2
  18. #define SPOOLER_OBJECT_COUNT 3
  19. /* These access bits must be different from those exposed in winspool.h,
  20. * so that no auditing takes place when we do an access check against them:
  21. */
  22. #define SERVER_ACCESS_ADMINISTER_PRIVATE 0x00000004
  23. #define PRINTER_ACCESS_ADMINISTER_PRIVATE 0x00000008
  24. #define JOB_ACCESS_ADMINISTER_PRIVATE 0x00000080
  25. PSECURITY_DESCRIPTOR
  26. CreateServerSecurityDescriptor(
  27. VOID
  28. );
  29. PSECURITY_DESCRIPTOR
  30. CreatePrinterSecurityDescriptor(
  31. PSECURITY_DESCRIPTOR pCreatorSecurityDescriptor
  32. );
  33. PSECURITY_DESCRIPTOR
  34. CreateDocumentSecurityDescriptor(
  35. PSECURITY_DESCRIPTOR pPrinterSecurityDescriptor
  36. );
  37. BOOL
  38. SetPrinterSecurityDescriptor(
  39. SECURITY_INFORMATION SecurityInformation,
  40. PSECURITY_DESCRIPTOR pModificationDescriptor,
  41. PSECURITY_DESCRIPTOR *ppObjectsSecurityDescriptor
  42. );
  43. BOOL
  44. DeletePrinterSecurity(
  45. PINIPRINTER pIniPrinter
  46. );
  47. BOOL
  48. DeleteDocumentSecurity(
  49. PINIJOB pIniJob
  50. );
  51. PSECURITY_DESCRIPTOR
  52. CreateEverybodySecurityDescriptor(
  53. VOID
  54. );
  55. BOOL
  56. ValidateObjectAccess(
  57. DWORD ObjectType,
  58. ACCESS_MASK DesiredAccess,
  59. LPVOID ObjectHandle
  60. );
  61. BOOL
  62. AccessGranted(
  63. DWORD ObjectType,
  64. ACCESS_MASK DesiredAccess,
  65. PSPOOL pSpool
  66. );
  67. VOID MapGenericToSpecificAccess(
  68. DWORD ObjectType,
  69. DWORD GenericAccess,
  70. PDWORD pSpecificAccess
  71. );
  72. BOOL
  73. GetTokenHandle(
  74. PHANDLE TokenHandle
  75. );
  76. BOOL
  77. GetSecurityInformation(
  78. PSECURITY_DESCRIPTOR pSecurityDescriptor,
  79. PSECURITY_INFORMATION pSecurityInformation
  80. );
  81. ACCESS_MASK
  82. GetPrivilegeRequired(
  83. SECURITY_INFORMATION SecurityInformation
  84. );
  85. BOOL
  86. BuildPartialSecurityDescriptor(
  87. ACCESS_MASK AccessGranted,
  88. PSECURITY_DESCRIPTOR pSourceSecurityDescriptor,
  89. PSECURITY_DESCRIPTOR *ppPartialSecurityDescriptor,
  90. PDWORD pPartialSecurityDescriptorLength
  91. );
  92. PSECURITY_DESCRIPTOR
  93. CreateDriversShareSecurityDescriptor(
  94. VOID
  95. );
  96. PSECURITY_DESCRIPTOR
  97. CreatePrintShareSecurityDescriptor(
  98. VOID
  99. );
  100.