开发者

iPhone - How do I find the MAC address of the connected WiFi access point?

开发者 https://www.devze.com 2022-12-23 22:38 出处:网络
Without using the private APIs, is it possible to programatically determine the MAC address of the access point that the iPhone is connec开发者_Python百科ted to?

Without using the private APIs, is it possible to programatically determine the MAC address of the access point that the iPhone is connec开发者_Python百科ted to?

I understand that this should be doable using the core BSD libraries, but we are new to this, so it would be great if someone can point us to some starter code.

Note: we're trying to determine the MAC address of the remote device - not the MAC address of the iPhone.


I believe that the NSHost class exists on the iPhone. If you create an NSHost instance for the machine you're connected to, then sending it an -addresses message should give you its IPV4 address and its MAC address, if I recall.

0

精彩评论

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