"block ads wps" - Views: 474 · Hits: 474 - Type: Public

@echo off
netsh advfirewall firewall add rule name="wpscenter" dir=in action=block program="%USERPROFILE%\AppData\Local\wps\10.2.0.6020\office6\wpscenter.exe" enable=yes
netsh advfirewall firewall add rule name="wps cloudsvr" dir=in action=block program="%USERPROFILE%\AppData\Local\wps\10.2.0.6020\office6\wpscloudsvr.exe" enable=yes


SET NEWLINE=^& echo.

FIND /C /I "ec2-34-213-133-234.us-west-2.compute.amazonaws.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 ec2-34-213-133-234.us-west-2.compute.amazonaws.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "ec2-34-213-238-222.us-west-2.compute.amazonaws.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 ec2-34-213-238-222.us-west-2.compute.amazonaws.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "ec2-52-220-226-146.ap-southeast-1.compute.amazonaws.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 ec2-52-220-226-146.ap-southeast-1.compute.amazonaws.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "ec2-52-43-249-196.us-west-2.compute.amazonaws.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 ec2-52-43-249-196.us-west-2.compute.amazonaws.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "ec2-52-89-212-137.us-west-2.compute.amazonaws.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 ec2-52-89-212-137.us-west-2.compute.amazonaws.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "ec2-54-149-125-87.us-west-2.compute.amazonaws.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 ec2-54-149-125-87.us-west-2.compute.amazonaws.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "ec2-54-187-93-72.us-west-2.compute.amazonaws.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 ec2-54-187-93-72.us-west-2.compute.amazonaws.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "ec2-54-191-41-159.us-west-2.compute.amazonaws.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 ec2-54-191-41-159.us-west-2.compute.amazonaws.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "ec2-54-68-129-70.us-west-2.compute.amazonaws.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 ec2-54-68-129-70.us-west-2.compute.amazonaws.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "home.office.wps.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 home.office.wps.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "home.wps.cn" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 home.wps.cn>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "http://ec2-34-213-133-234.us-west-2.compute.amazonaws.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 http://ec2-34-213-133-234.us-west-2.compute.amazonaws.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "http://ec2-52-220-226-146.ap-southeast-1.compute.amazonaws.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 http://ec2-52-220-226-146.ap-southeast-1.compute.amazonaws.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "http://ec2-52-43-249-196.us-west-2.compute.amazonaws.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 http://ec2-52-43-249-196.us-west-2.compute.amazonaws.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "http://ec2-52-89-212-137.us-west-2.compute.amazonaws.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 http://ec2-52-89-212-137.us-west-2.compute.amazonaws.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "http://ec2-54-187-93-72.us-west-2.compute.amazonaws.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 http://ec2-54-187-93-72.us-west-2.compute.amazonaws.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "http://ec2-54-191-41-159.us-west-2.compute.amazonaws.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 http://ec2-54-191-41-159.us-west-2.compute.amazonaws.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "http://ec2-54-68-129-70.us-west-2.compute.amazonaws.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 http://ec2-54-68-129-70.us-west-2.compute.amazonaws.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "http://home.office.wps.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 http://home.office.wps.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "http://home.wps.cn" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 http://home.wps.cn>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "http://kdl1.cache.wps.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 http://kdl1.cache.wps.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "http://map2.hwcdn.net" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 http://map2.hwcdn.net>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "http://officecontent.wps.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 http://officecontent.wps.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "kdl1.cache.wps.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 kdl1.cache.wps.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "map2.hwcdn.net" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 map2.hwcdn.net>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "officecontent.wps.com" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 officecontent.wps.com>>%WINDIR%\System32\drivers\etc\hosts

FIND /C /I "zone.kingsoft.jp" %WINDIR%\system32\drivers\etc\hosts
IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^127.0.0.1 zone.kingsoft.jp>>%WINDIR%\System32\drivers\etc\hosts