wifi icon indicating copy to clipboard operation
wifi copied to clipboard

how do you know "com.apple.wifi.linkdidchange"

Open powfulhong opened this issue 10 years ago • 11 comments

hi, is there any "com.apple.wifi.***" that shows wifi's state? I found that after the wifi's association succeed, wifi icon would wait for seconds to show in the status bar...how do i know its truly time that everything is ready? wait for your answer...(poor english, sorry)

powfulhong avatar Jan 23 '15 02:01 powfulhong

You mean a notification that is sent when WiFi turns on or turns off?

davidmurray avatar Jan 23 '15 21:01 davidmurray

No, just like when android wifi is associating, it has a few states that would broadcast, for example authorization.what I want to know is what notification it will send when iOS wifi is associating. Because I found when association callback returns success, the wifi icon don't appear right now,likely it is doing something.

发自我的 iPad

在 2015年1月24日,05:19,David Murray [email protected] 写道:

You mean a notification that is sent when WiFi turns on or turns off?

— Reply to this email directly or view it on GitHub.

powfulhong avatar Jan 24 '15 01:01 powfulhong

Try WiFiDeviceClientAssociateAsync with the callback argument.

davidmurray avatar Jan 24 '15 17:01 davidmurray

I did use WiFiDeviceClientAssociateAsync and the callback show wifi was associating successfully . What i confused is why it would wait a few seconds to appear at top-left. And how do you know there is a notification called "com.apple.wifi.linkdidchange"? How can i find others? Thanks.

powfulhong avatar Jan 25 '15 07:01 powfulhong

Run the command strings on a MobileWiFi binary. You should see all the notifications.

davidmurray avatar Jan 25 '15 14:01 davidmurray

I try strings MobileWiFi | grep "com.apple", but it just return ------ com.apple.wifi.manager.available com.apple.wifi.manager com.apple.wifid.queue com.apple.wifi.manager.available com.apple.wifi.manager com.apple.wifid.queue com.apple.wifi.manager.available com.apple.wifi.manager

com.apple.wifid.queue

is it right???(Though i do think so...)

powfulhong avatar Jan 26 '15 10:01 powfulhong

or can you help me find out all notifications of MobileWiFi?

powfulhong avatar Jan 26 '15 10:01 powfulhong

Sorry, not sure how you can find the other notifications. :( Maybe check the wifid binary?

davidmurray avatar Jan 26 '15 17:01 davidmurray

can't find the other notifications.....:( i found when the association callback return success, it was actually doing something, for example, getting the ip address.
now i found another problem that even if i enter the wrong pwd, the association would return success but actually associated to a different wifi? How could it be?

powfulhong avatar Jan 28 '15 03:01 powfulhong

And how did you get *.h??? class_dump doesn't get it. I use nm MobileWiFi and find that there are a lot of 'information' that you didn't show in headers...

powfulhong avatar Jan 28 '15 06:01 powfulhong

I'm not really sure about the other issue you're experiencing. I don't know everything about the iOS WiFi.

I didn't use class-dump, I manually reverse engineered the functions.

davidmurray avatar Jan 29 '15 21:01 davidmurray