问题
Can anyone of you let me know what is the identity field value generated in WhatsApp Android and/or iOS clients? For example
$w = new WhatsProt($username, $identity, "test", true);
If it is a unique random number generated by the WhatsApp client on the device, where exactly it will be stored (in which file and path)? Will that file not be wiped off once I uninstall the application?
The reason I asked the above is that I feel that there might be some device identifier used by WhatsApp client based on my test analysis:
- I installed Whatsapp on my second phone and provided the phone number of my first phone.
- As expected, SMS received on my first phone and I manually entered an incorrect OTP in my second phone.
- Resend SMS button on validate OTP screen was disabled for 1 minute.
- After one minute, I clicked on the resend SMS button and again as expected I received the SMS on my first phone.
- I re-entered an incorrect OTP again on my second phone. This time, the resend SMS button was disabled for 2 hours.
- I uninstalled the app and installed it again. However, the Resend SMS button is still disabled for 2 hours (to be precise, 1 hr 52 mins - uninstall and install took some time).
If the client is using a random unique identifier (like UUID or SecureRandom
) and which is stored in the internal memory (/appdata/com.whatsapp/somefile
), will it not be deleted when I uninstalled the app?
If the /appdata/com.whatsapp/somefile
is deleted on uninstall, how can WhatsApp Server side recognize this device and able to disable the "resend SMS" button?
By seeing this behavior, I think, it is making use of some unique identifier related to the device or something cool which WhatsApp has developed.
Has anyone knows how it is done?
回答1:
There are plenty of ways to detect your phone. They Might using IMEI, IMSI, AndroidID. Those all are the unique fields. With this whatsapp is getting that you already requested otp from this phone.
Try to research on
- IMEI number (Phone Unique ID)
- IMSI Number (SIM card Unique ID)
- Android ID (Unique ID of this Android phone)
来源:https://stackoverflow.com/questions/38909807/what-is-the-identity-field-value-generated-in-whatsapp-android-ios-clients