Linux中锐捷认证开启WiFi热点解决方案


一、前期准备

#安装hostapd

apt-get install hostapd

#安装create_ap
git clone https://github.com/oblique/create_ap
cd create_ap
make install

 

二、开启热点

1.立即启动 NetworkManager服务

systemctl start NetworkManager

 

2.锐捷用户

### Enable IEEE 802.11n
create_ap --ieee80211n --ht_capab '[HT40+]' wlan0 eth0 MyAccessPoint MyPassPhrase

 

3.其他

create_ap详细见https://github.com/oblique/create_ap

 

 
 


## Examples
### No passphrase (open network):
create_ap wlan0 eth0 MyAccessPoint

 
 

### WPA + WPA2 passphrase:
create_ap wlan0 eth0 MyAccessPoint MyPassPhrase

 
 

### AP without Internet sharing:
create_ap -n wlan0 MyAccessPoint MyPassPhrase

 
 

### Bridged Internet sharing:
create_ap -m bridge wlan0 eth0 MyAccessPoint MyPassPhrase

 
 

### Bridged Internet sharing (pre-configured bridge interface):
create_ap -m bridge wlan0 br0 MyAccessPoint MyPassPhrase

 
 

### Internet sharing from the same WiFi interface:
create_ap wlan0 wlan0 MyAccessPoint MyPassPhrase

 
 

### Choose a different WiFi adapter driver
create_ap --driver rtl871xdrv wlan0 eth0 MyAccessPoint MyPassPhrase

 
 

### No passphrase (open network) using pipe:
echo -e "MyAccessPoint" | create_ap wlan0 eth0

 
 

### WPA + WPA2 passphrase using pipe:
echo -e "MyAccessPoint\nMyPassPhrase" | create_ap wlan0 eth0

 
 

### Enable IEEE 802.11n
create_ap --ieee80211n --ht_capab '[HT40+]' wlan0 eth0 MyAccessPoint MyPassPhrase

 
 

### Client Isolation:
create_ap --isolate-clients wlan0 eth0 MyAccessPoint MyPassPhrase

 
 

## Systemd service
Using the persistent [systemd](https://wiki.archlinux.org/index.php/systemd#Basic_systemctl_usage) service
### Start service immediately:
systemctl start create_ap

 
 

### Start on boot:
systemctl enable create_ap

 

 

三、认证脚步

t=1;
while true
do 
#此处插入锐捷认证程序的执行

#比如我的

#  /root/rjsupplicant/x64/rjsupplicant
let t=t+1;
echo 没有网络啦,正在第$t次重连!;
done

 

 


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM