mirror of
https://gitee.com/dcren/my-script-tools.git
synced 2026-07-04 04:56:48 +08:00
8 lines
254 B
Batchfile
8 lines
254 B
Batchfile
@echo off
|
|
setlocal enabledelayedexpansion
|
|
set "IPLIST=blacklist.txt"
|
|
for /f "usebackq delims=" %%i in ("%IPLIST%") do (
|
|
set "ip=%%i"
|
|
netsh advfirewall firewall add rule name="Block_!ip!" dir=in action=block remoteip="!ip!"
|
|
)
|
|
echo 完成。 |