freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

用linux架設(shè)ftp服務(wù)器-資料下載頁(yè)

2024-09-04 15:39本頁(yè)面

【導(dǎo)讀】使用文件傳輸協(xié)議來通過網(wǎng)絡(luò)在計(jì)算機(jī)之間傳輸文件是很普遍的一種方法。幾乎在所有的平臺(tái)上面都有FTP的客戶端和服。務(wù)端的軟件,因此用FTP來傳送文件也是很方便的一個(gè)方法。私有的FTP服務(wù)器只運(yùn)行系統(tǒng)中的用戶訪問,而且可以對(duì)用戶進(jìn)行訪問控制,這樣可以給予或拒絕特定用戶的訪問權(quán)限。另一種是把FTP服務(wù)器配置成匿名服務(wù)器。潛在的安全問題,必須小心配置使得只允許訪問系統(tǒng)中特定的目錄。下面所有的命令都是Unix兼容的命令。源路徑都為“/var/tmp”。安裝在RedHatLinux下測(cè)試通過?!癷nstall–m”安裝“xferstats”程序,用于統(tǒng)計(jì)傳輸了多少文件。大小以提高wu-ftpd的性能?!皉m”命令刪除所有編譯和安裝wu-ftpd所需要的源程序,并且把wu-ftpd軟件的壓縮包刪除掉。首先,創(chuàng)建一個(gè)新的用戶,這個(gè)用戶被允許連接到ftp服務(wù)器上。因?yàn)橐小癱hroot”的環(huán)境,這個(gè)。帳號(hào)不同于正常的用戶帳號(hào),不能受訪問限制?!癱hroot”使用戶產(chǎn)生這樣的感覺好像自己已經(jīng)在文件系。這個(gè)假的shell可以限制用戶對(duì)ftp服務(wù)

  

【正文】 的配置文件讀入配置信息。配置文件中每一行中的項(xiàng)用 TAB或空格隔開。 編輯 文件( vi /etc/),加入并驗(yàn)證是否存在下面這一行: ftp stream tcp nowait root /usr/sbin/tcpd l a 注意:更新完 “” 文件之后要發(fā)給 id一個(gè) SIGNUP信號(hào),運(yùn)行下面的命令: [root@deep /root] killall HUP id 編輯 “” 文件( vi /etc/)加入這一行: : 這表示 IP地址為 “” 并且主機(jī)名為 “ ” 的計(jì)算機(jī)允許訪問 ftp服務(wù)器。 FTP 管理工具 ftpwho ftpwho 顯示當(dāng)前連接到 ftp 服務(wù)器上的所有用戶。這個(gè)命令菜單輸出類似 “/bin/ps” 的輸出,其格式為: < pid> < time> < tty> < connection details> 其中< pid>表示 ftp daemon 用來處理這次文件傳輸?shù)倪M(jìn)程號(hào),< time>表示用戶什么時(shí)候連接到 ftp 服務(wù)器上,< tty>總是用問號(hào)( ?)表示因?yàn)槭峭ㄟ^ ftp而不是 tel連接,< connection details>告訴連接是來自哪里、用戶是誰(shuí)以及用戶現(xiàn)在在干什么。 下面是 ftpwho輸出的一個(gè)例子: [root@deep] ftpwho Service class openarch: 5443 ? S 0:00 ftpd: : admin: IDLE 1 users ( 20 maximum) 可以看到現(xiàn)在有一個(gè)用戶登錄(最多可以有 20 個(gè)用戶同時(shí)登錄),這個(gè)用戶的用戶名是 admin來自 。 ftpcount ftpcount是 ftpwho 的簡(jiǎn)化版,只顯示登錄到 ftp 服務(wù)器的用戶數(shù)以及最多允許多少個(gè)用戶登錄。下面是一個(gè)例子: [root@deep] ftpcount Service class openarch 1 users ( 20 maximum) 保證 ftp服務(wù)器的安全 首先確保已經(jīng)創(chuàng)建了 “/etc/ftpusers” 文件,這個(gè)文件用來設(shè)置不允許哪些用戶登錄 ftp服務(wù)器,其中至少要包括: root、 bin、 daemon、 adm、 lp、 sync、 shutdown、 halt、 mail、 news、 uucp、operator、 games、 nobody以及所有 Linux發(fā)行商在系統(tǒng)中提供的默認(rèn)帳號(hào)。 如果想禁止匿名 ftp 服務(wù),把 ftp用戶從 password文件中移去,再用下面的命令確定在系統(tǒng)中沒有安裝 : [root@deep] rpm q anonftp. upload 命令 在默認(rèn)情況下, WUFTPD服務(wù)器給所有的 guest用戶上載的權(quán)限。當(dāng)用戶登錄的時(shí)候,被改變根目錄( chroot)到 “/home /ftp” 就不能訪問這個(gè)目錄之外的地方。但是 “/home/ftp” 目錄中的一些地方還是需要保護(hù),不能讓用戶隨便訪問。在我們配置的 ftp 服務(wù)器中為 “/home/ftp” 目錄下的“bin” 、 “etc” 、 “dev” 和 “l(fā)ib” 目錄。我們不允許用戶上載文件到這些目錄。所以我們要為這些目錄設(shè)置訪問權(quán)限,可以在 “/etc/ftpaccess” 文件中設(shè)置上載權(quán)限。在我們的例子中是這樣設(shè)置的: upload /home/ftp/* / no upload /home/ftp/* /etc no upload /home/ftp/* /dev no upload /home/ftp/* /bin no (require only if you are not using the “ enablels” option) upload /home/ftp/* /lib no (require only if you are not using the “ enablels” option) noretrieve 命令 最好禁止某些用戶從 “/home/ftp” 目錄下的某些子目錄中下載文件,可以用 “ noretrieve” 命令在 “/etc/ftpaccess” 文件中設(shè)置。 noretrieve /home/ftp/etc noretrieve /home/ftp/dev noretrieve /home/ftp/bin (require only if you are not using the “ enablels” option) noretrieve /home/ftp/lib (require only if you are not using the “ enablels” option) “.notar” 文件 無論是否允許即時(shí)的目錄打包( onthefly tar),都必須保證用戶不能打包( tar)禁止上載的目錄。在 “/home/ftp” 目錄的每個(gè)子目錄中都創(chuàng)建 “.notar” 文件。 [root@deep] touch /home/ftp/.notar [root@deep] chmod 0 /home/ftp/.notar [root@deep] touch /home/ftp/etc/.notar [root@deep] chmod 0 /home/ftp/etc/.notar [root@deep] touch /home/ftp/dev/.notar [root@deep] chmod 0 /home/ftp/dev/.notar [root@deep] touch /home/ftp/bin/.notar (require only if you are not using the “ enablels” option) [root@deep] chmod 0 /home/ftp/bin/.notar (require only if you are not using the “ enablels” option) [root@deep] touch /home/ftp/lib/.notar (require only if you are not using the “ enablels” option) [root@deep] chmod 0 /home/ftp/lib/.notar (require only if you are not using the “ enablels” option) 這些長(zhǎng)度為 0 的 “.notar” 文件會(huì)使一些瀏覽器和 ftp 代理( proxy)出現(xiàn)混亂,要解決這個(gè)問題必須把它們標(biāo)識(shí)為禁止下載。在 “/etc/ftpaccess” 文件中加入這一行: noretrieve .notar 安裝到系統(tǒng)中的文件 > /etc/ftphosts > /etc/ftpusers > /etc/ftpaccess > /etc/ > /etc/ftpconversions > /etc/ftpgroups > /etc/ > /usr/bin/ftpcount > /usr/bin/ftpwho > /usr/man/man1/ > /usr/man/man1/ > /usr/man/man5/ > /usr/man/man5/ > /usr/man/man5/ > /usr/man/man5/ > /usr/man/man8/ > /usr/man/man8/ > /usr/man/man8/ > /usr/sbin/ > /usr/sbin/ftpshut > /usr/sbin/ckconfig > /usr/sbin/ftprestart > /usr/sbin/xferstats > /usr/sbin/ > /usr/sbin/ > /var/log/xferlog
點(diǎn)擊復(fù)制文檔內(nèi)容
公司管理相關(guān)推薦
文庫(kù)吧 www.dybbs8.com
備案圖鄂ICP備17016276號(hào)-1