using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace ShareWifi.Utils.Net { class WifiUtils { /// /// 获取WIFI SSID /// /// public static string getSSID() { string v = Shell.RunCmd("netsh wlan show interfaces | findstr SSID"); return v; } /// /// 根据SSID获取密码 /// /// SSID /// public static string getSSDIPassword(string ssid) { string v = Shell.RunCmd("netsh wlan show profile name=" + ssid + " key=clear | findstr Key"); return v; } } }