Close dangerous ports with one click (preventing hacker intrusion)
Dangerous, port, hacker
Copy all of the following content
Use NotePad to save the suffix
Bat
Copy From @ below as prompted
Copy codeThe Code is as follows: @ echo off
Color 1f
Title: Disable common dangerous ports
Echo.
Echo.
Echo this batch is used to start the firewall of the XP system and disable common dangerous ports.
Echo.
Echo, please make sure that you are using the XP system and have not installed other firewalls
Echo.
Echo to avoid conflicts with the firewall of the XP System
Echo.
Echo.
Echo.
Pause
Cls
Echo is starting the firewall. Please wait...
SC config SharedAccess start = auto> nul
Net start SharedAccess> nul
Echo firewall has been started successfully
Echo.
Echo is disabling common dangerous ports. Please wait...
Echo.
Echo closing port 135... please wait...
Netsh firewall set portopening protocol = ALL port = 135 name = 135 mode = DISABLE scope = ALL profile = ALL
Echo closing port 137... please wait...
Netsh firewall set portopening protocol = ALL port = 137 name = 137 mode = DISABLE scope = ALL profile = ALL
Echo closing port 138... please wait...
Netsh firewall set portopening protocol = ALL port = 138 name = 138 mode = DISABLE scope = ALL profile = ALL
Echo closing port 139... please wait...
Netsh firewall set portopening protocol = ALL port = 139 name = 139 mode = DISABLE scope = ALL profile = ALL
Echo closing port 445... please wait...
Netsh firewall set portopening protocol = ALL port = 445 name = 445 mode = DISABLE scope = ALL profile = ALL
Echo closing port 593... please wait...
Netsh firewall set portopening protocol = TCP port = 593 name = 593 mode = DISABLE scope = ALL profile = ALL
Echo closing port 1025... please wait...
Netsh firewall set portopening protocol = TCP port = 1025 name = 1024 mode = DISABLE scope = ALL profile = ALL
Echo closing port 3389... please wait...
Netsh firewall set portopening protocol = ALL port = 3389 name = 3389 mode = DISABLE scope = ALL profile = ALL
Cls
Echo.
Echo.
Echo.
Echo common dangerous ports have been disabled
Echo.
Echo.
Echo.
Echo.
Echo
Echo.
Echo.
Echo.
Echo press any key to exit
Pause> nul