How to reverse the batch I ran that blocked sites via hosts file (code incl)

mike_6289

Limp Gawd
Joined
Dec 31, 2004
Messages
316
I accidentally ran a batch file I shouldn't have, and know nothing about reversing it. Is there an easy way to reverse this?

Code:
@ECHO OFF
IF "%OS%"=="Windows_NT" (
SET HOSTFILE=%windir%\system32\drivers\etc\hosts
) ELSE (
SET HOSTFILE=%windir%\hosts
)

ECHO.>> %HOSTFILE%
ECHO 127.0.0.1       www.newsleecher.com>> %HOSTFILE%
ECHO 127.0.0.1       newsleecher.com>> %HOSTFILE%
ECHO 127.0.0.1       secure.newsleecher.com>> %HOSTFILE%
IPCONFIG -flushdns
CLS

ECHO The following sites have been blocked via your HOSTS file:
ECHO.
ECHO - newsleecher.com
ECHO - www.newsleecher.com
ECHO - secure.newsleecher.com
ECHO.
ECHO Please close any app that might use your DNS cache (eg. web browsers)
ECHO.
ECHO.
ECHO.
ECHO.
PAUSE
 
problem solved

C:\WINDOWS\system32\drivers\etc

opened the hosts file, deleted the entries made.
 
Back
Top