936-架設Wireless LAN Hot Spot服務.ppt
《936-架設Wireless LAN Hot Spot服務.ppt》由会员分享,可在线阅读,更多相关《936-架設Wireless LAN Hot Spot服務.ppt(42页珍藏版)》请在三一文库上搜索。
1、1,實驗六 Term Project 架設Wireless LAN Hot Spot服務,Web Server使用apache DHCP Server使用dhcpd Firewall使用iptables NAT使用iptables 撰寫CGI程式使用C,Outline,實驗目的 實驗設備與環境 實驗方法與步驟 報告繳交 實驗記錄 問題討論與心得 注意事項 (含DEMO相關資訊) 參考資料,實驗目的 (1/4),身分認證 IP 安全,實驗目的 (2/4),實作一個Hot Spot,提供user連接Wireless LAN 802.11b Wireless access 只能有一個對外的IP ad
2、dress (Public IP) 提供Web-based認證,只有認證通過的user才可使用網路服務 讓user上網時,簡單上手,實驗目的 (3/4),DHCP Server Firewall IP Masquerading (NAT) Forward Web-based authentication,一般使用者 192.168.2.10 IP Address由 DHCP Server配給,Access Point 192.168.2.2 當bridge使用 SSID : netlab_TA (或用HostAP),對內:有線網卡 eth0: 192.168.2.1,對外:無線網卡 eth1:
3、 140.113.24.105,連上WL1,Internet,Station加入192.168.2.0/24網域,透過192.168.2.1的DHCP Server配給IP,並在連外時先連到192.168.2.1的認證網頁,通過認證之後才可對外連結上Internet,實驗目的 (4/4),瞭解Hot Spot需要那些技術與如何運作 使用與設定DHCP daemon 使用iptables來達到firewall與IP masquerading(偽裝IP),即NAT的功能 透過Web介面達成基本的認證,實驗設備與環境,設備與環境: (23台NB與01台AP) 一台FC5的NB (含有線與無線網卡介面
4、) Web Server使用apache 2.2 DHCP Server使用dhcpd-3.0.3 Firewall使用iptables NAT使用iptables 撰寫CGI程式使用C 一台不限平台的NB (含無線網卡,當user登入Hot Spot服務) 一台AP (當做無線端介面,做Bridge使用) 可向實驗室借AP,或是借網卡架設HostAP,DHCP Server Firewall IP Masquerading (NAT) Forward Web-based authentication,對內:有線網卡 eth0: 192.168.2.1,對外:無線網卡 eth1: 140.11
5、3.24.105,連上WL1,Internet,實驗方法與步驟 Web Server (1/3),實驗方法與步驟 Web Server (2/3),Web Server使用apache 2.2,Fedora Core 5已預設安裝 到預設安裝目錄/etc/httpd/conf,修改設定檔。 cd /etc/httpd/conf/ vim httpd.conf 修改httpd執行的使用者,將原先的apache改成nobody。(之後要修改iptables) User nobody Group nobody,實驗方法與步驟 Web Server (3/3),將ServerName改為Web Ser
6、ver對外的IP Address,如此Server的Name才可透過DNS Server name lookup成功。 ServerName 140.113.24.105 將Apache Web Server啟動。 httpd k start 更多關於httpd man httpd http:/httpd.apache.org,對內:有線網卡 eth0: 192.168.2.1,對外:無線網卡 eth1: 140.113.24.105,連上WL1,Internet,實驗方法與步驟 DHCP Server (1/7),DHCP Server Firewall IP Masquerading (N
7、AT) Forward Web-based authentication,192.168.2.0/24網域,透過192.168.2.1的DHCP Server配給IP,實驗方法與步驟 DHCP Server (2/7),安裝dhcp server套件 (dhcp-3.0.3-28),實驗方法與步驟 DHCP Server (3/7),安裝完成後,將dhcpd.conf.sample檔案複製到/etc目錄下,並更名為dhcpd.conf。 cp /usr/share/doc/dhcp-3.0.3/dhcpd.conf.sample /etc/dhcpd.conf,實驗方法與步驟 DHCP Ser
8、ver (4/7),修改dhcpd server的設定檔案,改成符合所在區域網路的設定值。 vim /etc/dhcpd.conf 第4行:subnet 192.168.2.0 netmask 255.255.255.0 第7行:option routers 192.168.2.1 第12行:option domain-name-servers 140.113.1.1, 140.113.6.2 第21行:range dynamic-bootp 192.168.2.3 192.168.2.10,實驗方法與步驟 DHCP Server (5/7),產生dhcpd執行時所需記載租約的檔案。 touc
9、h /var/lib/dhcpd/dhcpd.leases 修改起始dhcpd的script檔案。 vim /etc/rc.d/init.d/dhcpd,實驗方法與步驟 DHCP Server (6/7),增加dhcpd檔案內所需要的資訊。 第48行:CONFIGFILE=“/etc/dhcpd.conf” 第49行:LEASEFILE=“/var/lib/dhcpd/dhcpd.leases” 第50行:INTERFACE=“eth0” (有線網卡) 第51行:OPTIONS=“-q” 在start()內, daemon /usr/sbin/dhcpd cf $CONFIGFILE lf $
10、LEASEFILE $OPTIONS $INTERFACE,實驗方法與步驟 DHCP Server (7/7),將DHCP Server啟動。 /etc/rc.d/init.d/dhcpd start,對內:有線網卡 eth0: 192.168.2.1,對外:無線網卡 eth1: 140.113.24.105,連上WL1,Internet,DHCP Server Firewall IP Masquerading (NAT) Forward Web-based authentication,實驗方法與步驟 Firewall & NAT(1/7),一般使用者 192.168.2.10,Statio
11、n未認證前,所有連內/外的流量皆不允許通過,IPTABLES,filter: default for local nat: 轉譯封包ip/port mangle: 修改/標註封包,封包的處理流程,將mangle table忽略後的運作順序,實驗方法與步驟 Firewall & NAT(2/7),將系統內Forward Packet功能開啟。 echo “1” /proc/sys/net/ipv4/ip_forward 將Firewall功能與NAT功能所需要的modules載入系統中。 modprobe ip_tables modprobe ip_nat_ftp modprobe ip_nat
12、_irc modprobe ip_conntrack modprobe ip_conntrack_ftp modprobe ip_conntrack_irc,實驗方法與步驟 Firewall & NAT(3/7),將iptables內原先記載的Rule清除並重設為零 -F表示刪除某個table內的rules -X表示刪除使用者定義的rules -Z表示將所有rules中的封包和位元組計數為零。 iptables F iptables X iptables Z iptables F t nat iptables X t nat iptables Z t nat,實驗方法與步驟 Firewall
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- 936-架設Wireless LAN Hot Spot服務 936 架設 Wireless Spot 服務
链接地址:https://www.31doc.com/p-3025598.html