一鍵關(guān)閉危險(xiǎn)端口的批處理(防止黑客入侵)
更新時(shí)間:2012年06月04日 14:57:28 作者:
一鍵關(guān)閉危險(xiǎn)端口的bat代碼,防止黑客入侵,在一定程度上加強(qiáng)了系統(tǒng)安全
一鍵關(guān)閉危險(xiǎn)端口(防止黑客入侵)
危險(xiǎn), 端口, 黑客
講以下內(nèi)容全部復(fù)制
用記事本保存后綴為
bat
按提示進(jìn)行 從下面@開始復(fù)制
復(fù)制代碼 代碼如下:
@echo off
color 1f
title 關(guān)閉常見的危險(xiǎn)端口
echo.
echo.
echo 本批處理用于啟動(dòng)XP系統(tǒng)的防火墻并關(guān)閉常見的危險(xiǎn)端口
echo.
echo 請確認(rèn)您正在使用的是XP系統(tǒng) 并且未安裝其他防火墻
echo.
echo 以避免與XP系統(tǒng)的防火墻發(fā)生沖突
echo.
echo.
echo.
pause
cls
echo 正在啟動(dòng)防火墻 請稍候…
sc config SharedAccess start= auto > nul
net start SharedAccess > nul
echo 防火墻已經(jīng)成功啟動(dòng)
echo.
echo 正在關(guān)閉常見的危險(xiǎn)端口 請稍候…
echo.
echo 正在關(guān)閉135端口 請稍候…
netsh firewall set portopening protocol = ALL port = 135 name = 135 mode = DISABLE scope = ALL profile = ALL
echo 正在關(guān)閉137端口 請稍候…
netsh firewall set portopening protocol = ALL port = 137 name = 137 mode = DISABLE scope = ALL profile = ALL
echo 正在關(guān)閉138端口 請稍候…
netsh firewall set portopening protocol = ALL port = 138 name = 138 mode = DISABLE scope = ALL profile = ALL
echo 正在關(guān)閉139端口 請稍候…
netsh firewall set portopening protocol = ALL port = 139 name = 139 mode = DISABLE scope = ALL profile = ALL
echo 正在關(guān)閉445端口 請稍候…
netsh firewall set portopening protocol = ALL port = 445 name = 445 mode = DISABLE scope = ALL profile = ALL
echo 正在關(guān)閉593端口 請稍候…
netsh firewall set portopening protocol = TCP port = 593 name = 593 mode = DISABLE scope = ALL profile = ALL
echo 正在關(guān)閉1025端口 請稍候…
netsh firewall set portopening protocol = TCP port = 1025 name = 1024 mode = DISABLE scope = ALL profile = ALL
echo 正在關(guān)閉3389端口 請稍候…
netsh firewall set portopening protocol = ALL port = 3389 name = 3389 mode = DISABLE scope = ALL profile = ALL
cls
echo.
echo.
echo.
echo 常見的危險(xiǎn)端口已經(jīng)關(guān)閉
echo.
echo.
echo.
echo.
echo
echo.
echo.
echo.
echo 按任意鍵退出
pause>nul
相關(guān)文章
windows服務(wù)操作之刪除服務(wù) 批處理實(shí)現(xiàn)
用批處理實(shí)現(xiàn)的刪除服務(wù)器的方法,其實(shí)就是利用了批處理下的sc命令。2009-03-03
根據(jù)當(dāng)前目錄下的文件生成網(wǎng)址列表的bat
最近我需要獲取當(dāng)前目錄下的圖片文件。因?yàn)閳D片都有放到服務(wù)器里面,這時(shí)候又需要填寫一個(gè)完整的網(wǎng)址路徑,因?yàn)閳D片過多,所以我們通過bat實(shí)現(xiàn)了,下面分享下2013-05-05
批處理系統(tǒng)管理之6?-?用戶和localgroup組篇
本文主要介紹?net?localgroup?命令、net?user?命令、WMIC?命令有關(guān)本地用戶和組的增刪查改等實(shí)例,以及結(jié)合BAT腳本實(shí)現(xiàn)批量操作2023-07-07

