EliteAndroidApps / WhatsApp-Key-DB-Extractor

Allows WhatsApp users to extract their cipher key and databases on non-rooted Android devices.
GNU General Public License v3.0
363 stars 183 forks source link

Failure [INSTALL_FAILED_VERSION_DOWNGRADE] #10

Open peyobr opened 6 years ago

peyobr commented 6 years ago

Hi,

any chance this wonderful utility will work on Huawey P9 plus ?

Please help me! Thank you 1k

Pietro


Please connect your Android device with USB Debugging enabled:

Downloading legacy WhatsApp 2.11.431 to local folder

% Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 17.4M 100 17.4M 0 0 5264k 0 0:00:03 0:00:03 --:--:-- 5264k

WhatsApp 2.17.323 installed

Backing up WhatsApp 2.17.323 remote object '/data/app/com.whatsapp-2/base.apk' does not exist Backup complete

Removing WhatsApp 2.17.323 skipping data Success Removal complete

Installing legacy WhatsApp 2.11.431 7958 KB/s (18329558 bytes in 2.249s) Failure [INSTALL_FAILED_VERSION_DOWNGRADE] Install complete

Now unlock your device and confirm the backup operation.

Please enter your backup password (leave blank for none) and press Enter:

Password is set but strong AES encryption is not allowed Please install Java Cryptography Extension (JCE) Unlimited Strength Jurisdiction Policy Files 7 or 8 http://www.oracle.com/technetwork/java/javase/downloads/jce-7-download-432124.html http://www.oracle.com/technetwork/java/javase/downloads/jce8-download-2133166.html Exiting. tar: tmp/whatsapp.tar: Cannot open: No such file or directory tar: Error is not recoverable: exiting now tar: tmp/whatsapp.tar: Cannot open: No such file or directory tar: Error is not recoverable: exiting now tar: tmp/whatsapp.tar: Cannot open: No such file or directory tar: Error is not recoverable: exiting now tar: tmp/whatsapp.tar: Cannot open: No such file or directory tar: Error is not recoverable: exiting now tar: tmp/whatsapp.tar: Cannot open: No such file or directory tar: Error is not recoverable: exiting now

Saving whatsapp.cryptkey ... cp: cannot stat 'tmp/apps/com.whatsapp/f/key': No such file or directory Saving msgstore.db ... cp: cannot stat 'tmp/apps/com.whatsapp/db/msgstore.db': No such file or directory Saving wa.db ... cp: cannot stat 'tmp/apps/com.whatsapp/db/wa.db': No such file or directory Saving axolotl.db ... cp: cannot stat 'tmp/apps/com.whatsapp/db/axolotl.db': No such file or directory Saving chatsettings.db ... cp: cannot stat 'tmp/apps/com.whatsapp/db/chatsettings.db': No such file or directory

Pushing cipher key to: /sdcard/WhatsApp/Databases/.nomedia cannot stat 'tmp/apps/com.whatsapp/f/key': No such file or directory

Downloading WhatsApp 2.17.323 to local folder

% Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 33428 0 33428 0 0 98360 0 --:--:-- --:--:-- --:--:-- 98317

Restoring WhatsApp 2.17.323 742 KB/s (33428 bytes in 0.043s) Failure [INSTALL_PARSE_FAILED_UNEXPECTED_EXCEPTION: Failed to parse /data/app/vmdl843851857.tmp/base.apk: AndroidManifest.xml] Restore complete

Cleaning up temporary files ... rm: cannot remove 'tmp/whatsapp.tar': No such file or directory Done

Operation complete

Please press Enter to quit...

hknnisar commented 6 years ago

Same issue: Failure [INSTALL_FAILED_VERSION_DOWNGRADE] on Android 7.1.2 Is this an OS specific bug?

VidhiBhansali commented 6 years ago

Hi,

I am facing a similar error when I execute WhatsAppKeyDBExtract.bat file

Error: Failure [INSTALL_FAILED_VERSION_DOWNGRADE]

**Deleted file - C:\Users....\WhatsApp-Key-DB-Extractor-master\tm\wapver.txt Deleted file - C:\Users....\WhatsApp-Key-DB-Extractor-master\tm\sdkver.txt

Done

Downloading WhatsApp 2.17.395 to local folder % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 33428 0 33428 0 0 110k 0 --:--:-- --:--:-- --:--:-- 110k Restoring WhatsApp 2.17.395 1920 KB/s (33428 bytes in 0.017s) Failure [INSTALL_PARSE_FAILED_UNEXPECTED_EXCEPTION: Failed to parse /data/app/v dl429337027.tmp/base.apk: AndroidManifest.xml]

Restore complete

Removing WhatsApp 2.17.395 temporary apk Deleted file - C:\Users....\WhatsApp-Key-DB-Extractor-master\tm \base.apk

Operation complete

Press any key to continue . . .**

I am currently using Android 7.0 and WhatsApp v2.17.395.

Thanks in advance :)

Nick2324 commented 6 years ago

Hi!

Regarding the issues with java, you just need to install the software that it says from the links.

Password is set but strong AES encryption is not allowed Please install Java Cryptography Extension (JCE) Unlimited Strength Jurisdiction Policy Files 7 or 8 http://www.oracle.com/technetwork/java/javase/downloads/jce-7-download-432124.html http://www.oracle.com/technetwork/java/javase/downloads/jce8-download-2133166.html

If you don't do so, it's impossible for the extractor to access to the backup of your phone.

Hope it helps.

bjohas commented 6 years ago

"[INSTALL_FAILED_VERSION_DOWNGRADE]". I think this looks like a feature of Android 7.0, see documentation for ADB. Apps can only be downgraded if the app permits it. A work-around might be to move your whatsapp temporarily to a device that has Android < 7.0, and extract the key there. You can then also back up any data you want to back up.

Also, the key may or may not work when you go back to your Android >= 7.0 device. However, it if does, then you can continue backing up.

NOTE: Haven't tested this yet, but if one of you does try it, feedback would be appreciated.

reedy commented 6 years ago

Annoyingly, just installing the old whatsapp version manually gives a complaint that "Your phone date is inaccurate!"

nicolabeghin commented 6 years ago

Any news on this? So from Android 7 it's not possible to use it anymore?

bjohas commented 6 years ago

This article (https://android.stackexchange.com/questions/150071/how-to-manually-transfer-entire-whatsapp-installation-to-another-device-the-har) suggests that the adb backup functionality is also disabled (in addition to the ability to downgrade, see above).

Edit - there is another way - see my post below. You don't need the following.

Just using the device, the only possibility seems to get the key under Android 6, and then to work on a rooted device, where you can access /data/data/com.whatsapp/databases (or likely that has the key anyway, so rooting would work). Otherwise, the only possibility I can see is with Google Drive - assuming you are using this on Android for WhatsApp backups. You can download the archive (I guess) using WhatsApp-GD-Extractor, and then (I guess) use WhatsApp-Crypt12-Decrypter to decrypt the message store. This assumes that the key (extracted under Android 6) stays the same, so that you can use it with the backup downloaded from Google Drive. Has anybody tried this? Any thoughts?

reedy commented 6 years ago

It'd be a lot easier if the WhatsApp (well, Facebook) just put a proper export feature in

bjohas commented 6 years ago

@reedy Of course, I agree. I'm also using Telegram and Signal. Unfortunately they aren't all that great in terms of data export either, but at least being open source, it looks like it may happen sooner than WhatsApp.

reedy commented 6 years ago

Yeah, it's hard enough getting some people onto WhatsApp (which is at least fairly well used). Trying to get people to install "yet another app" can be painful.

I did email and ask...

Unfortunately, at this time it's not possible to transfer your history across platforms. We are always working to improve our app and will take your suggestion into consideration.

bjohas commented 6 years ago

If you're on Android, here's some good news, following on from my above post: The whatsapp message store (msgstore.db.crypt12) is kept in internal SD memory (if you back up to Google Drive). Once you have the key, you can then decrypt that file using 'WhatsApp-Crypt12-Decrypter'.

In summary, the following recipe worked for me:

The only caveat to this is that I don't know whether the WhatsApp key might change as you upgrade, or change devices in the future. Also, I guess WhatsApp may eventually become unavailable for Android 6, blocking this recipe altogether.

sparshgupta1 commented 5 years ago

@bjohas From your last comment, the script will only work if Android 6. This may come as super lame, but would be possible to emulate a phone with android 6 on PC. Install WhatsApp on the emulator. And then get the data?

sparshgupta1 commented 5 years ago

So I recently migrated to iPhone, I ended up using the software called Backuptrans. Now no I mean I am suggesting to do piracy. But you can follow these steps, which I got from this youtube video[https://www.youtube.com/watch?v=rbf2TN2wjpA]:

  1. Get a VM or physical machine, Win7SP1 32bit
  2. Download this directory[https://drive.google.com/file/d/17HQWEkGGiES7cqXg7n1Z2tQo-4kxcxCY/view]
  3. Install iTunes
  4. Install ADB drivers for your phone.
  5. Disconnect the internet on VM.
  6. Disconnect Gdrive from WhatsApp, and create a local backup of chats on phone.
  7. Transfer the chats to the VM using the software, and then to your iPhone after creating the chat.sqlite.
MarcoG3 commented 5 years ago

@bjohas From your last comment, the script will only work if Android 6. This may come as super lame, but would be possible to emulate a phone with android 6 on PC. Install WhatsApp on the emulator. And then get the data?

Hey, I've made a script that does exactly that. Check it out at https://github.com/MarcoG3/WhatsDump