yashsingh1/xdaforums huggingface dataset:
[Android Apps and Games] old2112:
Hello friends.

My phone is a Samsung J5 version 6.0.1. I'm not familiar with the whatsapp version on that phone, but I do want to recover my old whatsapp chatlogs. I tried all the steps and the script ran but it reported me nothing was found, I don't understand why this is the case. Can anyone assist?

Thanks

=========================================================================
= This script will extract the WhatsApp Key file and DB on Android 4.0+ =
= You DO NOT need root for this to work but you DO need Java installed. =
= If your WhatsApp version is greater than 2.11.431 (most likely), then =
= a legacy version will be installed temporarily in order to get backup =
= permissions. You will NOT lose ANY data and your current version will =
= be restored at the end of the extraction process so try not to panic. =
= Script by: TripCode (Greets to all who visit: XDA Developers Forums). =
= Thanks to: dragomerlin for ABE and to Abinash Bishoyi for being cool. =
= ### Version: v4.7 (12/10/2016) ### =
=========================================================================

Please connect your Android device with USB Debugging enabled:

* daemon not running. starting it now on port 5037 *
* daemon started successfully *

WhatsApp 2.18.306 installed

Found legacy WhatsApp 2.11.431 in local folder

Backing up WhatsApp 2.18.306
7921 KB/s (31869439 bytes in 3.928s)
Backup complete

Removing WhatsApp 2.18.306 skipping data
Success
Removal complete

Installing legacy WhatsApp 2.11.431
195 KB/s (1070 bytes in 0.005s)
pkg: /data/local/tmp/LegacyWhatsApp.apk
Failure [INSTALL_FAILED_INVALID_APK]
Install complete

Now unlock your device and confirm the backup operation.

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

bin\tar.exe: Record size = 2 blocks
bin\tar.exe: apps/com.whatsapp/f/key: Not found in archive
bin\tar.exe: Error exit delayed from previous errors
bin\tar.exe: Record size = 2 blocks
bin\tar.exe: apps/com.whatsapp/db/msgstore.db: Not found in archive
bin\tar.exe: Error exit delayed from previous errors
bin\tar.exe: Record size = 2 blocks
bin\tar.exe: apps/com.whatsapp/db/wa.db: Not found in archive
bin\tar.exe: Error exit delayed from previous errors
bin\tar.exe: Record size = 2 blocks
bin\tar.exe: apps/com.whatsapp/db/axolotl.db: Not found in archive
bin\tar.exe: Error exit delayed from previous errors
bin\tar.exe: Record size = 2 blocks
bin\tar.exe: apps/com.whatsapp/db/chatsettings.db: Not found in archive
bin\tar.exe: Error exit delayed from previous errors

Cleaning up temporary files ...

Done

Restoring WhatsApp 2.18.306
5816 KB/s (31869439 bytes in 5.350s)
pkg: /data/local/tmp/base.apk
Success

Restore complete

Removing WhatsApp 2.18.306 temporary apk

Operation complete

Press any key to continue . . .
[Android Apps and Games] Sandrloo:
Guys i hope you help me

i'm not expert in these stuffs

but i want to know if i understand well or not

this way is trying to extract msgstore from WhatsApp or just get the code so you can view the messages ?

because i delete the msgstore by mistake !
[Android Apps and Games] anmac1789@gmail.com:
I have a note 8 on android 9.0 and I'm trying to get the whatsapp chat's without phone number, but everytime I try to use this type of extractor I am getting this error:

Exception in thread "main" java.lang.UnsupportedClassVersionError: org/nick/abe/Main has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.access$100(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.launcher.LauncherHelper.checkAndLoadMain(Unknown Source)
bin\tar.exe: Cannot open tmp\whatsapp.tar: No such file or directory
bin\tar.exe: Error is not recoverable: exiting now
bin\tar.exe: Cannot open tmp\whatsapp.tar: No such file or directory
bin\tar.exe: Error is not recoverable: exiting now
bin\tar.exe: Cannot open tmp\whatsapp.tar: No such file or directory
bin\tar.exe: Error is not recoverable: exiting now
bin\tar.exe: Cannot open tmp\whatsapp.tar: No such file or directory
bin\tar.exe: Error is not recoverable: exiting now
bin\tar.exe: Cannot open tmp\whatsapp.tar: No such file or directory
bin\tar.exe: Error is not recoverable: exiting now
[Android Apps and Games] WoKoschekk:
update your Java version as stated in your error message
[Android Apps and Games] anmac1789@gmail.com:
To what version ? I already have the JDK 17 installed
[Android Apps and Games] WoKoschekk:
Java 22 was released on March 19, 2024.

Source: https://en.m.wikipedia.org/wiki/Java_version_history
[Android Apps and Games] anmac1789@gmail.com:
I've installed Java 22.0.1 today. What does the error code mean about 52.0 vs. 55 ?
[Android Apps and Games] Deltafox79:
Same problem for me on HTC m7 GPE lollipop 5.0.1.. I have also update abe.jar package downloaded here :

http://sourceforge.net/projects/adbextractor/?source=typ_redirect

But have the problems display in attachement..

I see the line command "bin\adb.exe backup -f tmp\whatsapp.ab -noapk com.whatsapp" produce a file whatsapp.ab of 1kb only.. maybe this is the problems but why?

Regards
[Android Apps and Games] kanj004:
please help

It works just fine on my galaxy note3 and my galaxy grand 2. But i try it using my xperia z it doesn't work

The error message in the attachments

Thank you
[Android Apps and Games] DURKH3IM:
The backup seems to be null, maybe whatsapp change the app folder? The com.whatsapp are empty!!:confused:

No info about crypt8?
[Android Apps and Games] cyb3r:
crypt8 is pretty easy to decode:

get the key from "data/data/com.whatsapp/files/key" once and latest db-backup from "sdcard/Whatsapp/Databases/msgstore.db.crypt8", then execute in bash:

hexdump -e '2/1 "%02x"' key | cut -b 253-316 > tmp/aes.txt

hexdump -e '2/1 "%02x"' key | cut -b 221-252 > tmp/iv.txt

dd if=msgstore.db.crypt8 of=tmp/msgstore.db.crypt8.nohdr ibs=67 skip=1 &> /dev/null

openssl enc -aes-256-cbc -d -nosalt -nopad -bufsize 16384 -in tmp/msgstore.db.crypt8.nohdr -K $(cat tmp/aes.txt) -iv $(cat tmp/iv.txt) > tmp/msgstore.gz

gzip -cdq tmp/msgstore.gz >msgstore.db

source: http://party3d.com/2014/12/16/nachste-whatsapp-version-bereits-geknackt/
[Android Apps and Games] DURKH3IM:
Nice info! But, the problem was in extracting the key file, when you did the android backup its seem to be empty! Now whatsapp its protected to android backup? Or it is impossible?

(soz bad english)
[Android Apps and Games] SimJoSt:
It seems that WhatsApp has opted out of the Android-Backup feature. Atleast my Helium/Carbon-Backup-App says so.

I have Version 2.11.476 installed.

At first I thought it had something todo with me installing a WhatsApp beta APK, because one of my friends send me one of these messages, that crashes WA when I open it... :)
[Android Apps and Games] collateral47:
Hi guys, I tried to do this one a HTC M7 but using the original attachment (in OPs post) I get an "exception in thread main java.lang..."

I also tried Abinash's version from Github but I get a file not found error this time.

Ive attached the screencaps

Am I correct in assuming that on a rooted device the bat file wont do anything, as Ive tried to test this on a rooted S3 and nothing happens.
[Android Apps and Games] DURKH3IM:
Yep...now its impossible to get the key file without root...
[Android Apps and Games] DURKH3IM:
It can be awesome if u can modify the apk! I really need it!!

Ah, and im working in translating my app, btw thanks for your help!

Regards!
[Android Apps and Games] SimJoSt:
I would definitively be interested! In general I am not relying on regular updates, so why not?

Thanks!
[Android Apps and Games] tayade.ameya:
This tool worked for a phone but did not for another phone

Thank you for this wonderful tool. I was able to extract key file from Moto G easily using this tool. But when I connect another phone, HTC Desire 816, the key is not extracted and an error message is shown. I have included an image to show the error:

[IMG="Image showing the error"]https://fbcdn-sphotos-h-a.akamaihd.net/hphotos-ak-xpf1/v/t34.0-12/10872587_761861090533989_1088684848_n.jpg?oh=4501fc231d3ba99f44d95c6030ae94a1&oe=549E80B8&__gda__=1419604136_3a9ee3bc63f4004203a5bbdefe5f64e5[/IMG]

Can somebody please help me?
[Android Apps and Games] TripCode:
This tool will still work on the latest WhatsApp, but you will need to patch the APK to re-enable ADB Backups. Please see: WhatsApp ADB Patch if you wish to patch your official apk with a simple drag and drop bat script. It will work with the current and all future versions of WhatsApp.
[Android Apps and Games] insigniared:
confirmed working

Confirmed working like a charm today in a non rooted stock HTC ONE X from ATT running android 4.1.1 with whatsapp version 2.11.432

just plug and play, but I had to copy the java path to "my pc", advance system settings, etc.

thank you

powerfull tool indeed.
[Android Apps and Games] ltGuillaume:
Since Tri-Crypt v1.4 (which supports crypt8) isn't available in the Play Store just yet, could you please attach the apk here, as you mentioned in a PM? Much appreciated, thanks TripCode! :)
[Android Apps and Games] TripCode:
No problem. Here you go! :)
[Android Apps and Games] ltGuillaume:
Thank you so much! Working perfectly :)
[Android Apps and Games] Moshuro:
Hi,

I've followed all the steps in the description. Installed Latest java version, APB and USB debbuging

when i connect the androit phone to the PC, after I run the bat file i get this message:

When I check the "extracted" folder there is nothing in it.

Could anyone please help?

Note: the phone is not rooted and i've searched the internet for all key extractors but all fail to work :(
[Android Apps and Games] testobomber:
if you cannot extract the key file is it possible to generate it on pc somehow?
[Android Apps and Games] thezyzz:
It runs the script, deletes my whatsapp app from my phone, then t it just opens the backup window on my phone, the "back up my data" buttom is blocked, and the whatsapp app is deleted and no whatsapp at all on my phone.

i'm using galaxy s3

android version: 4.1.2

latest whatsapp version.
[Android Apps and Games] testobomber:
another question. is it possible to copy the key file with another android app with sd card permission?
[Android Apps and Games] peperocco:
ello mali_ need your help.

well, this is a diferent thing, but i will apreciate if you can help me...i see you are very expert in this things.. may i send you a private message or i can do it here..?
[Android Apps and Games] testobomber:
does anybody know if it is possible to

first extract the msgstore.db.crypt8 file and the .nomedia file with the password from the device

then copy those files on another device without sim card and start whatsapp.

the .nomedia file contains a token so you do not need to verify with sms i read.

is it possible to read the backup files on the other device?
[Android Apps and Games] Malvlex:
Same problem here unfortunately. :( Might have to do something that I changed the phone and just use the backup files to access my whatsapp messages.
[Android Apps and Games] adolf.spenko:
i've been stuck for a week. Please help

HI,

i'm trying to backup my whatsapp messages from sony xperia S since they hold some crucial information. However i've been trying for a week now with no success. Please see attachment. I'm stuck here no matter what i do. I never get Backup prompt on my phone. USB debugging is turned on. Is this incompatibility issue with Sony? Unfortunately i don't have another phone to try it. Any help would be much appreciated. Thank you.
[Android Apps and Games] ralhamami:
Missing WhatsApp Key

I have successfully rooted my device, but in the data/data/com.whatsapp/files directory there is no key file. There are plenty of files there, but not the one I need. Any ideas? Thanks in advance.
[Android Apps and Games] ambience39:
hello there

I tried WhatsAppKey/DBExtractor/ CRYPT7/CRYPT8 NON-ROOT

on Samsung galaxy GT-I9082

android ver 4.2

but I allways have this result

my whatsapp crypt8
[Android Apps and Games] hasoooon:
I cant find whatsapp key

HI ... my phone is sonyericsson neo v ... i rooted to 4.0.4 ice ..... when i connected the device to pc with whatsapp extract key its cant find key
[Android Apps and Games] Triplets_Praburam:
Will the patch affect the latest call feature?
[Android Apps and Games] ArunBalaji:
Getting error message

I am getting some error message, when I try to backup my data plz help me to solve this.

Extracting msgstore.db ....

The system cannot find the path specified.

this is the error message iam gettin.
[Android Apps and Games] foxxychiq:
does this method still work?

Hello,

I've followed all the instructions but I get the below error message. My phone is Samsung not e 3 with android ver 4.4.2 and whatsapp ver 2.12.5

Please help thanks!
[Android Apps and Games] SilviuG:
not working on MotoG

Moto G 1st gen x1032 not rooted here.

I used the latest from here: https://github.com/AbinashBishoyi/WhatsApp-Key-DB-Extractor

At the Full backup step, I select to backup my data, no password, and the program ends with an error:

Any ideas? Anyone succesful on Moto G?

Backing up WhatsApp
Now unlock your device and confirm the backup operation.

Exception in thread "main" java.lang.RuntimeException: java.lang.NumberFormatException: For input string: ""
at org.nick.abe.AndroidBackup.extractAsTar(AndroidBackup.java:203)
at org.nick.abe.Main.main(Main.java:35)
Caused by: java.lang.NumberFormatException: For input string: ""
at java.lang.NumberFormatException.forInputString(Unknown Source)
at java.lang.Integer.parseInt(Unknown Source)
at java.lang.Integer.parseInt(Unknown Source)
at org.nick.abe.AndroidBackup.extractAsTar(AndroidBackup.java:67)
... 1 more
bin\tar: Cannot open tmp\whatsapp.tar: No such file or directory
bin\tar: Error is not recoverable: exiting now
bin\tar: Cannot open tmp\whatsapp.tar: No such file or directory
bin\tar: Error is not recoverable: exiting now
bin\tar: Cannot open tmp\whatsapp.tar: No such file or directory
bin\tar: Error is not recoverable: exiting now

Extracting whatsapp.key ...
File not found - key
0 File(s) copied

Extracting msgstore.db ...
The system cannot find the path specified.

Extracting wa.db ...
The system cannot find the path specified.

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

Cleaning up temporary files ...

Deleted file - c:\Users\x201\Downloads\WhatsApp-Key-DB-Extractor-master\tmp\whatsapp.ab
Could Not Find c:\Users\x201\Downloads\WhatsApp-Key-DB-Extractor-master\tmp\whatsapp.tar
The system cannot find the file specified.

Done
[Android Apps and Games] Triplets_Praburam:
Whataapp disabled adb backup:sly:
[Android Apps and Games] arough007:
Hey guys,

i updated the latest whatsapp.apk with the patch on page 10 but am still getting the error "cannot find the path/file specified".

Neither on my S3 mini nor my LG G3 it works.

I saw that some people had the same issue, but there was no solution yet.

Anyone got an idea this time around? ;)
[Android Apps and Games] TripCode:
The new version of this tool will temporarily patch with an official legacy version, rendering WhatsApp's "feeble attempt" to block ADB Backups useless! ;)

Please try the latest version as I have just updated this tool to support all new WhatsApp versions (including those that block ADB Backups).
[Android Apps and Games] Fl4sh3r:
I've tried using the updated version on HTC One (M7) with Lollipop.

The installation of the patched .apk failed:

WhatsApp-Key-DB-Extractor>bin\adb.exe install -r WhatsApp_Patched.apk
1709 KB/s (20748523 bytes in 11.852s)
pkg: /data/local/tmp/WhatsApp_Patched.apk
Failure [INSTALL_FAILED_DUPLICATE_PERMISSION perm=com.whatsapp.permission.VOIP_CALL pkg=com.whatsapp]

After removing WhatsApp (bin\adb.exe uninstall com.whatsapp), installation succeeded.

Doing the backup afterwards, resulted in an almost empty .tar with just the apps\com.whatsapp\_manifest in there.

Starting WhatsApp on my phone, resulted in asking me to import my existing messages. Only messages from the SD card were imported. Any messages received since the last backup are lost.

Maybe it would suffice if recent messages are backupped (Settings -> Backup messages).

Additionally the extracted keyfile is not working. The IV is all zeros, but other than that the keyfile is just the same as before. However, I'm not able to decrypt new backup files with either keyfile (old with IV and new without IV).
[Android Apps and Games] TripCode:
This should not be used in conjunction with a patched apk. There is no need. It's for official WhatsApp versions only. The reason it failed is because you cannot upgrade/downgrade via adb when the app contains different signatures. I.E. One signed by WhatsApp and the other self-signed.
[Android Apps and Games] Fl4sh3r:
I don't understand. The script is actually patching the apk, because (as I read the changelog) WhatsApp has disabled adb backup in the manifest.

So, there is not way to use the new script on the updated WhatsApp without using a patched apk.
[Android Apps and Games] TripCode:
Previously I developed WhatsApp ADB Patch to re-enable ADB backups on newer versions of WhatsApp. If you check the thread you will now see I have updated the original post with "This app is now obsolete as there is now a workaround to re-enable ADB using WhatsApp Key/DB Extractor." What this new script does is downgrade your official version of WhatsApp to a legacy version where ADB backups are enabled. After it extracts your key and db it will then upgrade you to the version you were on prior to the legacy version. WhatsApp Key/DB Extractor is for official WhatsApp versions. You should not patch it with the other script as that process will break this one and leave you open to errors such as your WhatsApp has been tampered with etc...
[Android Apps and Games] Zeyad Shaban:
thank you, i've solved the issue.
[Android Apps and Games] skurdekar:
Phone complains that the old Whatsapp version is too old. Seems to be benign warning and everything seems to work. So not sure if Whatsapp is really being downgraded or what else is going on. Tried on Motorola Droid Turbo and Moto X. Both exhibit same behaviour.
[Android Apps and Games] okunova:
Problems with the script

Hi I have been testing the script but it gives an error code is as follows

=========================================================================
= This script will extract the WhatsApp Key file and DB on Android 4.0+ =
= You DO NOT need root for this to work, but you DO need Java installed =
= Base Script by: TripCode =
= Thanks to: Nikolay Elenkov for abe.jar =
= Thanks to: David Fraser, Joel Purra =
= Updated By: Abinash Bishoyi (Added support for 4.4.X/L devices) =
= Version: v3 (26th Jan 2015) =
=========================================================================

Using Java from C:\Program Files\Java\jre7 directory
java version "1.7.0_45"
Java(TM) SE Runtime Environment (build 1.7.0_45-b18)
Java HotSpot(TM) 64-Bit Server VM (build 24.45-b08, mixed mode)
I: Decompiling APK
I: Using Apktool 2.0.0-ec3fbf-SNAPSHOT on WhatsApp.apk
I: Loading resource table...
I: Decoding AndroidManifest.xml with resources...
I: Loading resource table from file: C:\apktool\framework\1.apk
I: Regular manifest package...
I: Decoding file-resources...
I: Decoding values */* XMLs...
I: Baksmaling classes.dex...
I: Copying assets and libs...
I: Copying unknown files...
I: Copying original files...
I: Patching AndroidManifest.xml
I: Recompiling APK
I: Using Apktool 2.0.0-ec3fbf-SNAPSHOT on WhatsApp
I: Checking whether sources has changed...
I: Smaling smali folder into classes.dex...
I: Checking whether resources has changed...
I: Building resources...
I: Copying libs...
I: Building apk file...
I: Copying unknown files/dir...
I: Signing APK
I: Patching Done

Please connect your Android device with USB Debugging enabled:

adb server is out of date. killing...
* daemon started successfully *
Uninstalling older version
Installing latest WhatsApp version
4916 KB/s (20547242 bytes in 4.081s)
pkg: /data/local/tmp/WhatsApp_Patched.apk
Failure [INSTALL_PARSE_FAILED_INCONSISTENT_CERTIFICATES]
Backing up WhatsApp
Now unlock your device and confirm the backup operation.

1024 bytes written to tmp\whatsapp.tar.
bin\tar: Record size = 2 blocks
bin\tar: apps/com.whatsapp/f/key: Not found in archive
bin\tar: Error exit delayed from previous errors
bin\tar: Record size = 2 blocks
bin\tar: apps/com.whatsapp/db/msgstore.db: Not found in archive
bin\tar: Error exit delayed from previous errors
bin\tar: Record size = 2 blocks
bin\tar: apps/com.whatsapp/db/wa.db: Not found in archive
bin\tar: Error exit delayed from previous errors

Extracting whatsapp.key ...
File not found: key
0 files(s) copied(s)

Extracting msgstore.db ...
The system can not find the path specified.

Extracting wa.db ...
The system can not find the path specified.

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

Cleaning up temporary files ...

Deleted file: C:\WhatsApp-Key-DB-Extractor-master (3)\WhatsApp-Key-DB-Extractor-master\tmp\whatsapp.ab
Archivo eliminado: C:\WhatsApp-Key-DB-Extractor-master (3)\WhatsApp-Key-DB-Extractor-master\tmp\whatsapp.tar
The system can not find the file specified.

Done
.

Is there any possible solution
[Android Apps and Games] doras100p:
After using this tool, whatsapp now crashes everytime I start it. What should I do?

I tried uninstalling and reinstalling whatsapp
[Android Apps and Games] TripCode:
If you are referring to the alert in the notification bar, then this is normal behavior. It will go away when WhatsApp gets upgraded again. If the alert keeps popping up then you must still be on the legacy release, in which case just go to the Play Store or WhatsApp's website and install the latest version. As long as you have extracted your key file then that's all that really matters.

This is an old script that patches WhatsApp and is not the script I posted on this thread. It's failing because the patched version is self-signed and is mismatched against the pre-installed apk; hence the error: "INSTALL_PARSE_FAILED_INCONSISTENT_CERTIFICATES". You should download the script contained within my original post instead, as it does not use a self-signed apk. If you did download the script I posted in this thread, then you're running the wrong bat file! ;)

If you have uninstalled and re-installed WhatsApp, then the fault is elsewhere and has nothing to do with my tool.
[Android Apps and Games] maikwars:
Hey TripCode,

When I used our script I get the same error message how "okunova". I have the newest version but get always the same error!

Next step was to install the patched.apk manual , after successful installation its not possible to verifiy your WhatsApp-Account, cause WhatsApp checked the APK and says "You have an modified version of WhatsApp, please contact bla bla bla...".

Next thing....the paths in our tool where you pull out the keyfile and wa.db are really correct?! I only see the paths "apps/com.whatsapp/f/key" and "apps/com.whatsapp/db/wa.db". I checked the path with my rooted device and I found the named files at "data/data/com.whatsapp/files/key" and "/data/data/com.whatsapp/databases/wa.db".

Sorry for mistakes-maikwars