@echo off
set ver=v1
title Block in Host_ Soft98.iR

fltmc >nul 2>&1 || (
  echo Set UAC = CreateObject^("Shell.Application"^) > "%temp%\GetAdmin.vbs"
  echo UAC.ShellExecute "%~fs0", "", "", "runas", 1 >> "%temp%\GetAdmin.vbs"
  cmd /u /c type "%temp%\GetAdmin.vbs">"%temp%\GetAdminUnicode.vbs"
  cscript //nologo "%temp%\GetAdminUnicode.vbs"
  del /f /q "%temp%\GetAdmin.vbs" >nul 2>&1
  del /f /q "%temp%\GetAdminUnicode.vbs" >nul 2>&1
  exit
)

@echo off
SET hosts=%windir%\system32\drivers\etc\hosts
SET tempFile=%temp%\temp_hosts.txt
(

echo 127.0.0.1 dl-files.com
echo 127.0.0.1 licenseapi.dl-files.com

) > %tempFile%
attrib -r %hosts%
FOR /F "usebackq delims=" %%A IN (%tempFile%) DO (
    findstr /i /c:"%%A" %hosts% >nul || (
        echo %%A >> %hosts%
    )
)
attrib +r %hosts%
del %tempFile%
IPCONFIG -flushdns
echo.
echo Successfully Host Block in Windows.
echo.
echo ~~~~~~~~~~~~~~~~~~~~~~ Soft98.iR ~~~~~~~~~~~~~~~~~~~~~~
echo.
echo Press any key to exit...
pause >nul
