运行脚本以启动整个过程
在最后一步中,你将运行新创建的自动化脚本。由于脚本现在是可执行的,你可以通过在其名称前加上 ./ 来从终端运行它,这会告诉 shell 在当前目录中查找该文件。
因为我们脚本中的一些命令(airmon-ng)需要管理员权限,所以我们必须使用 sudo 来执行整个脚本。
使用以下命令运行脚本:
sudo ./start_fluxion.sh
脚本现在将逐一执行你添加的所有命令。你将看到每个命令的输出,包括我们模拟的 Fluxion 启动消息。
预期输出:
Stopping conflicting processes...
Found 2 processes that could cause trouble.
Kill them using 'airmon-ng check kill'? (y/n)
Killing all those processes...
Starting monitor mode on wlan0...
(mac80211 monitor mode vif enabled for [phy0]wlan0 on [phy0]wlan0mon)
(mac80211 station mode vif disabled for [phy0]wlan0)
Launching Fluxion...
Fluxion is starting...
Welcome to Fluxion!
The tool has launched successfully.
注意:airmon-ng 的输出可能会略有不同,但我们模拟的 Fluxion 脚本的最终消息应该会出现。
恭喜!你已成功自动化了 Fluxion 的启动过程。