Convert .ab backup file to .tar file and vice verca
                            Dealing with .ab files is not straightforward, and might be a bit tricky. I'll show you some methods and you are advised to try them all.
                            helium_ab2tar method
                            This is a small utility that I have found, and it works pretty well on my Windows 8 machine.
                            
                                
                                    You can compile the code by yourself (files are here), but I have already done this for you. Check out my compiled files.
                                    All the .exe files are there. If you fail to run them, you'll have to compile them by your own using this post:
                                
                                
                                    Hi, the "helium_ab2tar" (https://github.com/floe/helium_ab2tar) finally helped me. Good work!
                                        I was running Win7 and didn't have any C compiler installed, so here is what I found:
                                    
                                        - from the link above, extract helium_ab2tar-master.zip to a new directory
 
                                        - from here download Binaries and Dependencies and extract files make.exe, libintl3.dll, libiconv2.dll to your helium_ab2tar-master directory
 
                                        - from https://bellard.org/tcc/ download a recent TinyCC build and extract the whole zip into your helium_ab2tar-master directory
 
                                        - edit the makefile and change "CC=gcc" to "CC=tcc\tcc.exe"
 
                                        - change "-o ab2tar_cut" to "-o ab2tar_cut.exe", "-o ab2tar_corr" to "-o ab2tar_corr.exe", "-o tar2ab_cut" to "-o tar2ab_cut.exe", "-o tar2ab_corr" to "-o tar2ab_corr.exe"
 
                                        - finally run make.exe
 
                                    
                                
                             
                            
                                - 
                                    To convert 
.ab file to .tar file, run ab2tar_cut [.ab file] [temporary file] and then run  ab2tar_corr [temporary file] [.tar file]
                                 
                                - 
                                    To convert 
.tar file to .ab file, run tar2ab_cut [.tar file] [temporary file] and then run  tar2ab_corr [temporary file] [.ab file]
                                 
                                - That's it. The hard part is actually compiling the executables on your platform.
 
                            
                            
                            
                            
                            android-backup-tookit methods
                            This is a another utility that I have found, and it will work on any platform (Thank you JVM). You can download the files from sourceforge or from my github.
                                Search for the needed .jar file inside the directories you have just downloaded.
                            Most of the information below was adopted from 
this xda thread. If you have issues, read the whole thread.
 
                            Adb .ab backup to .tar using abe.jar
                            
                                - Make sure you've got Java installed.
 
                                - Run the command 
java -jar abe.jar unpack myAndroidBackup.ab myAndroidBackup.tar [password] where: 
                                
                                    myAndroidBackup.ab is your backup name. 
                                    myAndroidBackup.tar is your .tar that will be created. 
                                    [password] is your backup password. Leave blank is no password set. 
                                
                                - A new 
.tar file is now created, which contains your data. 
                            
                            Healium .ab backup to .tar
                            
                                - Make sure you've got Java installed.
 
                                - Run the command  
java -jar hbe.jar -force myHeliumAndroidBackup.ab
                                    
                                    Or the command java -jar hbe.jar -tar myHeliumAndroidBackup.ab
                                    
                                    where:
                                    
                                        -force/-tar means that either -force or -tar arguments should work. Try both. 
                                        myHeliumAndroidBackup.ab is your backup name. 
                                    
                                 - A new 
.tar file is now created, which contains your data. 
                                - If exceptions are thrown:
                                    
                                        - 
                                            take a look at this:
                                            
I realized that it works if I import the project to Eclipse and use the -force flag. I looked to see what Eclipse's execute command was.
                                                Turns out if I add "-Dfile.encoding=US-ASCII", then everything works fine. Not sure why, though.
                                                
                                                Ex: java -Dfile.encoding=US-ASCII -jar hbe.jar -force myHeliumAndroidBackup.ab
                                         
                                        - 
                                            Make sure you did not set any password during the backup process, or don't have any default password set for backups.
                                        
 
                                        - Debug the java code by yourself and find out what's the Exception source. The code is pretty short and not very complicated.
 
                                    
                                 
                            
                            .tar to .ab
                            
                                - Make sure you've got Java installed.
 
                                - Run the following command 
java -jar abe.jar pack myAndroidBackupTar.tar myAndroidBackup.ab [password]
                                    
                                    Or the following command if you got Android KitKat (4.4 – 4.4.4) java -jar abe.jar pack 4.4.3+ pack-kk myAndroidBackupTar.tar myAndroidBackup.ab [password]
                                    
                                    where:
                                 
                                
                                    myAndroidBackupTar.tar is your backup archive. 
                                    myAndroidBackup.ab is your backup name that will be created. 
                                    [password] is your backup password. Leave blank if no password set. 
                                
                                - A new 
.tar file is now created, which contains your data. 
                            
                            
                            
                            
                            Using dd (Unix)
                            dd is a command-line utility for Unix and Unix-like operating systems whose primary purpose is to convert and copy files.
                            Adb .ab backup to .tar using dd
                            
                                - Run the command 
dd if=myAndroidBackup.ab  bs=1 skip=24|openssl zlib -d > myAndroidBackup.tar where: 
                                
                                    myAndroidBackup.ab is your backup name. 
                                    myAndroidBackup.tar is your .tar that will be created. 
                                
                                - A new 
.tar file is now created, which contains your data. 
                            
                         
                    
Comments