整了一上午,总算把无线AP的radius验证MAC地址搞定了;整理记录如下,以备日后之需。
AP型号:SMC2552W-G2
freeradius、mysql 均为CentOS 5.5 自带
一、配置 freeradius
1、修改clients.conf
client 10.0.0.0/8 { //增加AP连接radius的接口地址
secret = 123456 //AP连接radius的密码
shortname = wifi
nastype = othe
secret = 123456 //AP连接radius的密码
shortname = wifi
nastype = othe
2、修改naslist
# vi /usr/local/etc/raddb/naslist
在最后加入一行:
在最后加入一行:
10.0.0.0/8 wifi other //加入AP的nas
3、修改radius.conf, 使radius支持mysql认证
要修改三个地方:
# vi /usr/local/etc/raddb/radiusd.conf
$INCLUDE ${confdir}/sql.conf //将前面#号去掉
authorize {
...
authorize {
...