ExecutePrivilege.cs 1.1 KB

12345678910111213141516171819202122232425262728293031323334
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. namespace SmartCoalApplication.SystemLayer
  7. {
  8. public enum ExecutePrivilege
  9. {
  10. /// <summary>
  11. /// The process is started with default permissions: either the same as the invoker,
  12. /// or those required by the executable's manifest.
  13. /// </summary>
  14. AsInvokerOrAsManifest,
  15. /// <summary>
  16. /// The process is required to run with administrator privilege. If the user does not
  17. /// have administrator privilege, nor has the ability to obtain it, then the operation
  18. /// will fail.
  19. /// </summary>
  20. RequireAdmin,
  21. /// <summary>
  22. /// The process is required to run with normal privilege. On some systems this may
  23. /// not be possible, and as such this will have the same effect as AsInvokerOrAsManifest.
  24. /// </summary>
  25. /// <remarks>
  26. /// This flag only has an effect in Windows Vista from a process that already has
  27. /// administrator privilege.
  28. /// </remarks>
  29. RequireNonAdminIfPossible
  30. }
  31. }