[Quote]

    nikzzzz
  • 215
  • Longevity: 8 years 10 months
  • Posts: 3114
  • REPUTATION:127

    [+] [-]
.Как известно, пользователь, даже администратор, имеют ограниченные возможности доступа, к примеру он часто не может удалить некоторые файлы, не видит в RegEdit ветку SAM и т.п. , даже UnLocker часто не помогает.
Утилита повышает привилегии до уровня TrustedInstaller и легко решает эти проблемы.
RunAsTI.exe - запуск процесса под System с привилегиями trustedinstaller
RunAsTI.exe /s - запуск процесса под System
Install.cmd - копирует файлы и добавляет в контекстное меню пункт "Run as trustedinstaller"
Пример запуска:
RunAsTI.exe /s d:\....\TotalCmd.exe
RunAsTI.exe d:\....\TotalCmd.exe
Если параметр не указан, будет запущена консоль (cmd.exe)
Важно - используйте полные пути в аргументах.
Attachments
Attachments


Last edited by nikzzzz on 2020-04-15 19:22; edited 41 times in total

[Quote]

    Michailo2000
  • 33955
  • Longevity: 2 months 14 days
  • Posts: 16
  • REPUTATION:-3

    [+] [-]
на основе сабжевого скрипта оформил инсталяцию для su: superUser.rar
Скажите, а утилита "superUsеr" умеет запускать от имени System?
Это к тому, что здесь давно кто-то делал модифицированный скрипт для RunAsTI с двумя подпунктами в дополнение к основному ещё и "Запуск от имени System". Может ли тогда использоваться оный скрипт и что в нём изменить кроме названий пунктов и утилиты?
@echo off
call :Admin
if defined PROCESSOR_ARCHITEW6432 start %SystemRoot%\Sysnative\cmd.exe /c "%~dpnx0" %* & exit
cls
)
cd /d "%~dp0"
set "arch=x64"
if /i %PROCESSOR_ARCHITECTURE%==x86 if not defined PROCESSOR_ARCHITEW6432 set "arch=x86"
if %arch%==x64 (
copy RunAsTI_x64.exe %SystemRoot%\System32\RunAsTI.exe /y
copy RunAsTI.exe %SystemRoot%\SysWOW64\RunAsTI.exe /y
) else (
copy RunAsTI.exe %SystemRoot%\System32\RunAsTI.exe /y
)
Reg.exe add "HKCR\*\shell\runastrustedinstaller" /v "SubCommands" /t REG_SZ /d "runastrustedinstaller.RunAs.TrustedInstaller;runastrustedinstaller.RunAs.System" /f
Reg.exe add "HKCR\*\shell\runastrustedinstaller" /v "MUIVerb" /t REG_SZ /d "TrustedInstaller" /f
Reg.exe add "HKCR\*\shell\runastrustedinstaller" /v "Icon" /t REG_SZ /d "imageres.dll,73" /f
Reg.exe add "HKCR\*\shell\runastrustedinstaller" /v "Position" /t REG_SZ /d "1" /f
Reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\CommandStore\shell\runastrustedinstaller.RunAs.System" /v "" /t REG_SZ /d "‡ ЇгбЄ ®в Ё¬Ґ­Ё System" /f
Reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\CommandStore\shell\runastrustedinstaller.RunAs.System" /v "HasLUAShield" /t REG_SZ /d "" /f
Reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\CommandStore\shell\runastrustedinstaller.RunAs.System\command" /v "" /t REG_SZ /d "RunAsTI.exe /s \"%%1\" %%*" /f
Reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\CommandStore\shell\runastrustedinstaller.RunAs.TrustedInstaller" /v "" /t REG_SZ /d "‡ ЇгбЄ ®в Ё¬Ґ­Ё TrustedInstaller" /f
Reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\CommandStore\shell\runastrustedinstaller.RunAs.TrustedInstaller" /v "HasLUAShield" /t REG_SZ /d "" /f
Reg.exe add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\CommandStore\shell\runastrustedinstaller.RunAs.TrustedInstaller\command" /v "" /t REG_SZ /d "RunAsTI.exe \"%%1\" %%*" /f
Reg.exe add "HKCR\exefile\shell\runastrustedinstaller" /v "SubCommands" /t REG_SZ /d "runastrustedinstaller.RunAs.TrustedInstaller;runastrustedinstaller.RunAs.System" /f
Reg.exe add "HKCR\exefile\shell\runastrustedinstaller" /v "MUIVerb" /t REG_SZ /d "TrustedInstaller" /f
Reg.exe add "HKCR\exefile\shell\runastrustedinstaller" /v "Icon" /t REG_SZ /d "imageres.dll,73" /f
Reg.exe add "HKCR\exefile\shell\runastrustedinstaller" /v "Position" /t REG_SZ /d "1" /f
echo.Install completed.
>nul pause
goto :EOF
:Admin
reg query "HKU\S-1-5-19\Environment" >nul 2>&1
if not %errorlevel% EQU 0 (
cls
powershell.exe -windowstyle hidden -noprofile "Start-Process '%~dpnx0' -Verb RunAs"
exit
)
exit /b
В тексте скрипта есть абразябра. Не обращайте внимание. Там кусок текста "Запуск от имени" на русском в код-ке OEM866.

Page 14 of 14


Display posts:    

Current time is: 08-Dec 22:48

All times are UTC + 3


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum