เนื่องจาก FreeNAC ค่อนข้างซับซ้อน และ ต้องการเครื่องที่รันบน Linux และ มี tools OpenSource ต่างๆ ที่จะต้องติดตั้งมากมาย
ทาง Freenac.net จึงได้สร้าง Virtual Machine (VM) สำหรับ FreeNAC ไว้เพื่อให้ง่ายสำหรับคนที่ต้องการจะเริ่มต้นทดสอบการใช้งาน FreeNAC ซึ่งตัว VM
นี่ download ได้ที่ Freenac.net
การติดตั้ง VM
1. ติดตั้ง Program VMware Workstation (หรือ free VMware Player)
3. ทำการแตกไฟล์ FreeNAC_VM ที่ download ได้และเก็บใน Folder ที่ใช้เก็บไฟล์ VM
4. เริ่มต้นใช้งาน run FreeNAC_VM บน VMware Workstation
5. FreeNAC_VM จะเป็น Linux Ubuntu 8.04

6. ทำการ Login โดยใช้ username: freenac และ password: freenac
ึ7. โดย default keyboard จะเป็นภาษา Swiss German โดยสามารถเข้าไปแก้ไขได้โดยใช้คำสั่ง
dpkg-reconfigure -plow console-setup
8. เข้าไปทำการดู IP address ของ FreeNAC ของเครื่องได้จากคำสั่ง
ifconfig –a
ซึ่ง default จะ set เป็น DHCP มาให้
ทำการแก้ไขโดยเรียกไฟล์ /etc/network/interfaces ขึ้นมาแก้ไขและทำการ save โดยใช้คำสั่ง
sudo vi /etc/network/interfaces
auto eth0
iface eth0 inet dhcp
แก้ไขให้เป็น IP static ตามนี้
auto eth0
iface eth0 inet static
address 192.168.1.100
netmask 255.255.255.0
network 192.168.1.0
broadcast 192.168.1.255
gateway 192.168.1.1
save file และทำการ restart network service โดยคำสั่ง
/etc/init.d/networking restart

ทำการเชื่อมต่อกับ Web Interface
1. เปิด web browser และพิมพ์ IP ของ VM ที่ set ไว้ ในที่นี้คือ 192.168.1.100
2. web page จะแสดงหน้าจอ web GUI ของ FreeNAC ซึ่งเป็นหน้าจอสำหรับจัดการระบบ NAC

Set ค่า cisco switch ให้รู้จักกับ NAC Server
1. Set VMPS parameters ที่ switch ตามนี้
conf t
vmps server 192.168.1.100
vmps reconfirm 120
end
vmps reconfirm
sho vmps
2. เปิด VMPS บน port ของ switch โดยใช้คำสั่ง
conf t
int fa0/2
switchport access vlan dynamic
ทำการ Set port fast ethernet 2 ให้รับ dynamic vlan

ตัวอย่างแสดงการ config parameter ที่ switch
1. Set up ค่า SNMP บน Switch ตามนี้
conf t
snmp-server group secure v3 auth read secure-ro write secure-rw access 1
snmp-server view secure-ro internet included
snmp-server view secure-wr mgmt included
snmp-server user snmpusr secure v3 auth md5 cisco123 access 1
access-list 1 permit host 192.168.1.100
access-list 1 deny any log
2. Setup ค่า SNMP บน NAC Server ตามนี้
ใส่ค่า SNMP RO/RW communities ที่ set ไว้ใน Switch ลงใน NAC Server โดยเข้าไปแก้ไขในไฟล์ /opt/nac/etc/config.inc
sudo vi /opt/nac/etc/config.inc
หาบรรทัดต่อไปนี้
## SNMP communities
$snmp_ro="PASSWORD2"; # maybe public
$snmp_rw="PASSWORD3"; # very private
$router_ro="PASSWORD4"; #For router_mac_ip script. If empty, use snmp_ro defined above
แล้วแก้ไขให้เป็นตามนี้
## SNMP communities
$snmp_ro="secure-ro"; # maybe public
$snmp_rw="secure-rw"; # very private
$router_ro="secure-ro"; #For router_mac_ip script. If empty, use snmp_ro defined above
ทำการ Test การทำงานของ SNMP ใน NAC Server โดยใช้คำสั่งดังนี้
snmpwalk -v 3 -u snmpusr -l authNoPriv -a MD5 -A cisco123 192.168.1.10 system
snmpwalk -v 3 -u snmpusr -l authNoPriv -a MD5 -A cisco123 192.168.1.10 sysUpTime
หลังจากที่ Switch สามารถติดต่อกับ NAC Server ผ่านทาง SNMP ได้แล้ว ใช้ Program Wireshark จับ Packet เพื่อศึกษาการทำงานของ Protocol ต่างๆ
ไม่มีความคิดเห็น:
แสดงความคิดเห็น