Skip to content

About

Allows WhatsApp users on Android to extract their backed up WhatsApp data from Google Drive.

Resources

Stars

0 stars

Watchers

0 watching

Forks

 
 

Repository files navigation

WhatsApp Google Drive Extractor

Allows WhatsApp users on Android to extract their backed up WhatsApp data from Google Drive.

Prerequisites

  1. Python 3
  2. Android device with WhatsApp installed and the Google Drive backup feature enabled.
  3. The device's Android ID (if you want to reduce the risk of being logged out of Google). Run adb shell settings get secure android_id or Search Google Play for "device id" for plenty of apps that can reveal this information.
  4. Google account credentials. Password login (an App password if you use 2-factor authentication: https://myaccount.google.com/apppasswords) often fails with BadAuthentication, so a master token is recommended instead.

Instructions

  1. Extract WhatsApp-GD-Extractor-master.zip.
  2. Install dependencies: Run python3 -m pip install -r requirements.txt from your command console. Make sure gpsoauth is the latest version.
  3. Copy settings.cfg.example to settings.cfg and edit the [auth] section.
  4. Authenticate with a master token (recommended, see below), or leave master_token empty to log in with the password.
  5. Run python3 WhatsAppGDExtract.py from your command console.
  6. Read the usage examples that are displayed.
  7. Run any of the examples.

Getting a master token

  1. Open https://accounts.google.com/EmbeddedSetup in a browser and sign in.
  2. Click "I agree", then copy the value of the oauth_token cookie (it starts with oauth2_4/) from your browser's developer tools.
  3. Run python3 get_master_token.py and paste the cookie at the hidden prompt. Alternatively, set it in the OAUTH_TOKEN environment variable.
  4. Put the printed aas_et/... value after master_token = in settings.cfg.

The cookie is short-lived and single use. Treat the master token like a password: it grants broad access to your Google account, and settings.cfg is git-ignored so that it is not committed.

If downloading is interrupted, the files that were received successfully won't be re-downloaded when running the tool one more time. After downloading, you may verify the integrity of the downloaded files using md5sum --check md5sum.txt on Linux or md5summer on Windows.

Troubleshooting

  1. Check that you have the required imports installed: python3 -m pip install gpsoauth
  2. BadAuthentication when using a password: use a master token instead.
  3. If you have Error:Need Browser, go to this url to solve the issue: https://accounts.google.com/b/0/DisplayUnlockCaptcha

Credits

Author: TripCode

Contributors: DrDeath1122 from XDA for the multi-threading backbone part, YuriCosta for reverse engineering the new restore system

About

Allows WhatsApp users on Android to extract their backed up WhatsApp data from Google Drive.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages