我找了官方文档,和网上的,都没有一个准信。
官方文档:https://manual.nssurge.com/rule/subnet.html
提示的是:
Subnet Expression
A subnet expression can be one of these:
Use SSID:value to match the Wi-Fi SSID, wildcard character is allowed.
Use BSSID:value to match the Wi-Fi BSSID, wildcard character is allowed.
Use ROUTER:value to match the router IP address.
Use TYPE:WIFI to match all Wi-Fi networks.
Use TYPE:WIRED to match all wired networks.
Use TYPE:CELLULAR to match all cellular networks.
If no prefix is provided, it tries to match SSID/BSSID/Router for the legacy version compatibility.
但是我试了这几种写法都不行
"BSSID:3c:7c:xx:xx:82:84" = DIRECT
"BSSID:3c-7c-xx-xx-82-84" = DIRECT
"BSSID:3C:7C:XX:XX:82:84" = DIRECT
"BSSID:3C-7C-XX-XX-82-84" = DIRECT
我是脚本中打印出来的 bssid 是 “3c:7c:xx:xx:82:84” 这种格式,实际根据它来执行脚本也是可以的。
$network.wifi.bssid === bssid;` 这种形式是可以的。