Advertisement
PC_Aide

Compatibility mode (runAsInvoker - bypass UAC).bat

Feb 8th, 2019
3,793
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Batch 3.36 KB | None | 0 0
  1. ::&----------------------------------------------------------------------------------------------------------------------
  2. ::  Doc: https://ss64.com/nt/syntax-elevate.html
  3. ::  SRC: https://stackoverflow.com/questions/37878185/what-does-compat-layer-actually-do
  4. ::  RunAsInvoker can bypass UAC for:
  5. ::
  6. :: Hint App-V5.x -> some app (old) working perfectly on Win7 but on Win10 some glitch visual (issue) because on Win10 we have gretest resolution that OS precede
  7. :: so the solution is very simple - just testing couple resolution + colour and now working on Win10
  8. :: Tested -> pending... <-- maybe need to end march 2019 to discover
  9. ::
  10. :: Link ext -> https://pastebin.com/fTYBxTS6 <-- Compatibility available in Windows 10 -32-bit Compatibility Modes (90)
  11. :: List : __compat_layer=@
  12. ::          @=RunAsInvoker <-- ignore any elevattion request in the app's manifest :
  13. ::          <requestedExecutionLevel level=asInvoker" uiAccess="false" />
  14. :: each VA or package we have a manifest file and can customize it
  15. :: Warning -> RunAsInvoker doesn't perform any elevation
  16. ::
  17. ::  Doc UAC: https://docs.microsoft.com/en-us/previous-versions/windows/it-pro/windows-server-2008-R2-and-2008/dd835564(v=ws.10)
  18. ::
  19. ::          @=Win98 640x480
  20. ::          @=VistaSP1
  21. ::          @=VistaSP2
  22. ::          @=Win7RTM
  23. ::          @=Win8RTM
  24. ::          @=WINXPSP3
  25. ::          @=Win95
  26. ::
  27. ::  ╔═══════════════════════════════════════════════════════════════════╗
  28. ::  ║ set __COMPAT_LAYER=256Color                                        ║
  29. ::  ║ "C:\Program Files\Microsoft Office 15\root\office15\winword.exe"   ║
  30. ::  ╚═══════════════════════════════════════════════════════════════════╝
  31. ::
  32. ::  ╔═══════════════════════════════════════════════════════════════════╗
  33. ::  ║ cmd /min /C "set __COMPAT_LAYER=RUNASINVOKER && start "" "%1"      ║
  34. ::  ║ "C:\Program Files\Microsoft Office 15\root\office15\winword.exe"   ║
  35. ::  ╚═══════════════════════════════════════════════════════════════════╝
  36. ::◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼
  37. ::  mp4 -> https://youtu.be/geptyFklZe4
  38. ::◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼◼
  39. ::&----------------------------------------------------------------------------------------------------------------------
  40.  
  41. ::Bypass UAC prompt
  42. cmd /k SET __COMPAT_LAYER=RunAsInvoker
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement