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.

62 lines
1.5 KiB

  1. # -
  2. # This test verifies ReplaceAllAccessRights
  3. # -
  4. # Initialize a new ACL
  5. Exec InitNewACL
  6. # Add rayland\actest1-10 to the local explicit access list
  7. ToggleAccessPerm COM_RIGHTS_EXECUTE
  8. Set TrusteeName rayland\actest1
  9. AddTrustee ExplicitAccessList
  10. Set AccessMode DENY_ACCESS
  11. Set TrusteeName rayland\actest2
  12. AddTrustee ExplicitAccessList
  13. Set AccessMode GRANT_ACCESS
  14. Set TrusteeName rayland\actest3
  15. AddTrustee ExplicitAccessList
  16. Set AccessMode DENY_ACCESS
  17. Set TrusteeName rayland\actest4
  18. AddTrustee ExplicitAccessList
  19. Set AccessMode GRANT_ACCESS
  20. Set TrusteeName rayland\actest5
  21. AddTrustee ExplicitAccessList
  22. Set AccessMode DENY_ACCESS
  23. Set TrusteeName rayland\actest6
  24. AddTrustee ExplicitAccessList
  25. Set AccessMode GRANT_ACCESS
  26. Set TrusteeName rayland\actest7
  27. AddTrustee ExplicitAccessList
  28. Set AccessMode DENY_ACCESS
  29. Set TrusteeName rayland\actest8
  30. AddTrustee ExplicitAccessList
  31. Set AccessMode GRANT_ACCESS
  32. Set TrusteeName rayland\actest9
  33. AddTrustee ExplicitAccessList
  34. Set AccessMode DENY_ACCESS
  35. Set TrusteeName rayland\actest10
  36. AddTrustee ExplicitAccessList
  37. # Call ReplaceAllAccessRights
  38. Exec ReplaceAllAccessRights
  39. # Take a look at the ACL
  40. Exec GetExplicitAccessRights
  41. SwitchClientCtx
  42. actest1
  43. rayland
  44. Set TrusteeName rayland\actest1
  45. Exec IsAccessPermitted
  46. # Replace the current ACL with aan empty ACL
  47. Destroy LocalExplicitAccessList
  48. Exec ReplaceAllAccessRights
  49. # Take a look at the ACL
  50. Exec GetExplicitAccessRights
  51. Exec IsAccessPermitted
  52. # Kill server
  53. Quit