开发者

reading a MAC address in as a variable in BASH, should i use hex, do i need semicolons?

开发者 https://www.devze.com 2023-02-19 03:05 出处:网络
i have a BASH script that does a few network utili开发者_开发技巧ties at home.I want to read in a few variables at the start. For something fed into airodump-ng, which can take a MAC address as an arg

i have a BASH script that does a few network utili开发者_开发技巧ties at home. I want to read in a few variables at the start. For something fed into airodump-ng, which can take a MAC address as an arg just like: 00:01:02:03:04:05, how should input this for 'read'?


read -p "Enter the MAC Address: " mac
echo "You entered the MAC Address: $mac"
0

精彩评论

暂无评论...
验证码 换一张
取 消