Advertisement
Dr_G

Petya_block1

Jun 29th, 2017
186
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Batch 2.82 KB | None | 0 0
  1. @echo off
  2. setlocal enabledelayedexpansion
  3.  
  4. echo ----------------------------------------------------------------------------
  5. net session >nul 2>&1
  6. if %errorLevel% == 0 (
  7. if exist C:\Windows\perfc (
  8.  echo Mar letezik a prefc
  9. ) else (
  10.  echo Fajlok letrehozasa
  11.  echo. 2>C:\Windows\perfc
  12.  echo. 2>C:\Windows\perfc.dll
  13.  echo. 2>C:\Windows\perfc.dat
  14.  attrib +R C:\Windows\perfc
  15.  attrib +R C:\Windows\perfc.dll
  16.  attrib +R C:\Windows\perfc.dat
  17. )) else (
  18.  echo Nem vagy rendszergazda.
  19.  pause
  20.  exit
  21. )
  22.  
  23. echo ----------------------------------------------------------------------------
  24. SET UJSOR=^& echo.
  25. echo Hosts modositasa
  26. FIND /C /I "benkow.cc" %WINDIR%\system32\drivers\etc\hosts
  27. IF %ERRORLEVEL% NEQ 0 ECHO %UJSOR%^0.0.0.0 benkow.cc>>%WINDIR%\System32\drivers\etc\hosts
  28. FIND /C /I "185.165.29.78" %WINDIR%\system32\drivers\etc\hosts
  29. IF %ERRORLEVEL% NEQ 0 ECHO %UJSOR%^0.0.0.0 185.165.29.78>>%WINDIR%\System32\drivers\etc\hosts
  30. FIND /C /I "upd.me-doc.com.ua" %WINDIR%\system32\drivers\etc\hosts
  31. IF %ERRORLEVEL% NEQ 0 ECHO %UJSOR%^0.0.0.0 upd.me-doc.com.ua>>%WINDIR%\System32\drivers\etc\hosts
  32. FIND /C /I "95.141.115.108" %WINDIR%\system32\drivers\etc\hosts
  33. IF %ERRORLEVEL% NEQ 0 ECHO %UJSOR%^0.0.0.0 95.141.115.108>>%WINDIR%\System32\drivers\etc\hosts
  34. FIND /C /I "111.90.139.247" %WINDIR%\system32\drivers\etc\hosts
  35. IF %ERRORLEVEL% NEQ 0 ECHO %UJSOR%^0.0.0.0 111.90.139.247>>%WINDIR%\System32\drivers\etc\hosts
  36. FIND /C /I "84.200.16.242" %WINDIR%\system32\drivers\etc\hosts
  37. IF %ERRORLEVEL% NEQ 0 ECHO %UJSOR%^0.0.0.0 84.200.16.242>>%WINDIR%\System32\drivers\etc\hosts
  38. FIND /C /I "yadi.sk" %WINDIR%\system32\drivers\etc\hosts
  39. IF %ERRORLEVEL% NEQ 0 ECHO %UJSOR%^0.0.0.0 yadi.sk>>%WINDIR%\System32\drivers\etc\hosts
  40. FIND /C /I "french-cooking.com" %WINDIR%\system32\drivers\etc\hosts
  41. IF %ERRORLEVEL% NEQ 0 ECHO %UJSOR%^0.0.0.0 french-cooking.com>>%WINDIR%\System32\drivers\etc\hosts
  42.  
  43. echo ----------------------------------------------------------------------------
  44. set /P SMBv1off=SMBv1 kikapcsolasa ['I/N']?
  45. if /I "%SMBv1off%" EQU "I" (
  46.  
  47.  ver | find "6.1."
  48.  if !ERRORLEVEL! EQU 0 (
  49.   sc.exe config lanmanworkstation depend= bowser/mrxsmb20/nsi
  50.   sc.exe config mrxsmb10 start= disabled
  51.   reg add "HKCU\SYSTEM\CurrentControlSet\Services\LanmanServer\Parameters" /v SMB1 /t REG_DWORD /d 0 /f
  52.  )
  53.  
  54.  ver | find "6.3."
  55.  if !ERRORLEVEL! EQU 0 (
  56.   sc.exe config lanmanworkstation depend= bowser/mrxsmb20/nsi
  57.   sc.exe config mrxsmb10 start= disabled
  58.   reg add "HKCU\SYSTEM\CurrentControlSet\Services\LanmanServer\Parameters" /v SMB1 /t REG_DWORD /d 0 /f
  59.  )
  60.  
  61.  ver | find "5.1."
  62.  if !ERRORLEVEL! EQU 0 echo Windows XP - nincs mit tenni
  63.  
  64.  ver | find "10.0."
  65.  if !ERRORLEVEL! EQU 0 DISM /online /disable-feature /featurename:SMB1Protocol
  66. )
  67.  
  68. echo ----------------------------------------------------------------------------
  69. echo Vege
  70. pause
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement