網(wǎng)絡(luò)技術(shù)是從1990年代中期發(fā)展起來的新技術(shù),它把互聯(lián)網(wǎng)上分散的資源融為有機(jī)整體,實(shí)現(xiàn)資源的全面共享和有機(jī)協(xié)作,使人們能夠透明地使用資源的整體能力并按需獲取信息。資源包括高性能計(jì)算機(jī)、存儲(chǔ)資源、數(shù)據(jù)資源、信息資源、知識(shí)資源、專家資源、大型數(shù)據(jù)庫、網(wǎng)絡(luò)、傳感器等。 當(dāng)前的互聯(lián)網(wǎng)只限于信息共享,網(wǎng)絡(luò)則被認(rèn)為是互聯(lián)網(wǎng)發(fā)展的第三階段。 基于內(nèi)核的入侵檢測(cè) 基于內(nèi)核的入侵檢測(cè)是一種相當(dāng)巧妙的新型的Linux入侵檢測(cè)系統(tǒng)。現(xiàn)在最主要的基于內(nèi)核的入侵檢測(cè)系統(tǒng)叫做LIDS。 什么是LIDS?LIDS是一種基于Linux內(nèi)核的入侵檢測(cè)和預(yù)防系統(tǒng)。 LIDS的保護(hù)目的是防止超級(jí)用戶root的篡改系統(tǒng)重要部分的。LIDS主要的特點(diǎn)是提高系統(tǒng)的安全性,防止直接的端口連接或者是存儲(chǔ)器連接,防止原始磁碟的使用,同時(shí)還要保護(hù)系統(tǒng)日志文件。LIDS當(dāng)然也會(huì)適當(dāng)制止一些特定的系統(tǒng)操作,譬如:安裝sniffer、修改防火墻的配置文件。 LIDS文檔工程 LIDS比安裝PortSentry和LogCheck要復(fù)雜一點(diǎn),但是很幸運(yùn)的是,在LIDS的主頁上面有詳細(xì)的安裝和配置手冊(cè)。 安裝LIDS 首先,在安裝之前,我們需要大部分最新的LIDS軟件包(我使用的是0.9)和適當(dāng)?shù)膬?nèi)核版本。我現(xiàn)在使用的是從Red Hat主頁上下載的2.2.14-12版本的內(nèi)核,因?yàn)槠渲邪恍┌踩a(bǔ)丁。同時(shí)你也需要你使用的內(nèi)核的一些源代碼。 現(xiàn)在的LIDS主要是適用于2.2.14版本的內(nèi)核。我安裝的在2.2.14的內(nèi)核的Red Hat Linux 6.2上面安裝了LIDS。在安裝LIDS之前,我在ftp.redhat.com下載了最新的內(nèi)核版本,并且依照http://www.redhat.com/support/docs/howto/kernel-upgrade/kernel-upgrade.html 安裝了這個(gè)內(nèi)核。 接著的事情就是升級(jí)內(nèi)核源代碼。這里我們是這樣做的: rpm -Uhv kernel-source-2.2.14-12.i386.rpm然后就是編譯和安裝lidsadm這個(gè)程序: cd /usr/local/src/security/lids-0.9/lidsadm-0.9make make install 生成一個(gè)RipeMD-160口令,這個(gè)以后將會(huì)在安裝進(jìn)內(nèi)核的: lidsadm -P輸入口令是"anypass",得到秘鑰"d502d92bfead11d1ef17887c9db07a78108859e8"。接著,我把Redhat的配置文件拷貝到我的結(jié)構(gòu)體系中,在/usr/src/linux目錄下面: cd /usr/src/linux/configs/ cp kernel-2.2.12-i686.config .. 下面我們就使用下面的命令來安裝LIDS: cd /usr/src patch -p0 同時(shí)我們應(yīng)該注意到Red Hat所提供的內(nèi)核和Linus發(fā)布的標(biāo)準(zhǔn)的2.2.14版本的內(nèi)核有一些細(xì)微的差別,因?yàn)槠渲邪恍┬薷倪^的驅(qū)動(dòng)程序。同樣lids-0.9-2.2.14-redhat.patch文件也是和LIDS發(fā)布的標(biāo)準(zhǔn)的lids-0.9-2.2.14.patch有一些細(xì)微的差別,不過可能后者并不是特別適合于Red Hat系統(tǒng)。 最后,就是配置、編譯和安裝內(nèi)核了: cd /usr/src/linuxmake menuconfig make dep; make clean make install; make modules; make modules_install 下面的腳本展示了在配置內(nèi)核的過程中我設(shè)置的LIDS配置選項(xiàng): [*] Linux Intrusion Detection System support (EXPERIMENTAL)--- LIDS features [ ] Hang up console when raising a securit alert [*] Security alert when execing unprotected programs before sealing [ ] Do not execute unprotected programs before sealing LIDS [*] Enable init children lock feature [*] Try not to flood logs (60) Authorised time between two identic logs (seconds) [*] Allow switching LIDS protections RipeMD-160 encrypted password: d502d92bfead11d1ef17887c9db07a78108859e8 (3) Number of attempts to submit password (3) Time to wait after a fail (seconds) [*] Allow remote users to switch LIDS protections [ ] Allow any program to switch LIDS protections [*] Allow reloading config. file [ ] Hide some known processes [*] Port Scanner Detector in kernel [ ] Send security alerts through network --- Special authorizations [ ] Allow some known processes to access /dev/mem (xfree, etc.) [ ] Allow some known processes to access raw disk devices [ ] Allow some known processes to access io ports [ ] Allow some known processes to change routes --- Special UPS [*] Allow some known processes to unmount devices Allowed processes: "/etc/rc.d/init.d/halt;/etc/rc.d/init.d/netfs" [*] Unmounting capability is inherited [*] Allow some known processes to kill init children Allowed processes: "/etc/rc.d/init.d/halt" [*] Killing capability is inherited 看得出,我沒有使用UPS,同時(shí)運(yùn)行的是一個(gè)需要能夠遠(yuǎn)程訪問的服務(wù)器,我就按照上面的文件進(jìn)行了配置,但是在實(shí)際應(yīng)用過程中,每個(gè)人的系統(tǒng)根據(jù)環(huán)境不一樣,會(huì)有一些差別。 網(wǎng)絡(luò)的神奇作用吸引著越來越多的用戶加入其中,正因如此,網(wǎng)絡(luò)的承受能力也面臨著越來越嚴(yán)峻的考驗(yàn)―從硬件上、軟件上、所用標(biāo)準(zhǔn)上......,各項(xiàng)技術(shù)都需要適時(shí)應(yīng)勢(shì),對(duì)應(yīng)發(fā)展,這正是網(wǎng)絡(luò)迅速走向進(jìn)步的催化劑。 |
溫馨提示:喜歡本站的話,請(qǐng)收藏一下本站!