pamela rizk
asked on
Extract database of android
dear all
I refer to the below link :https://medium.com/@k1d_bl4ck/how-to-extract-the-database-and-other-things-from-an-enterprise-android-app-2194a52b249b
in order to extract database of an android apk
mybackup.ab is generated sucessfully
but I need to know how to convert mybackup.ab to mybackup.db in order to open it in sqllite browser so I can see the content of the table there .
below is the error generated
Please help
I refer to the below link :https://medium.com/@k1d_bl4ck/how-to-extract-the-database-and-other-things-from-an-enterprise-android-app-2194a52b249b
in order to extract database of an android apk
mybackup.ab is generated sucessfully
but I need to know how to convert mybackup.ab to mybackup.db in order to open it in sqllite browser so I can see the content of the table there .
below is the error generated
C:\Program Files (x86)\Android\android-sdk\platform-tools>dd if=backup.ab bs=1 skip=24 | python -c "import zlib,sys;sys.stdout.write(zlib.decompress(sys.stdin.read()))" | tar -xvf -\n
'dd' is not recognized as an internal or external command,
operable program or batch file.
Please help
ASKER
my needs is to convert file backup.ab to backup.db
so that I can open .db file generated from Sqllite browser
so that I can open .db file generated from Sqllite browser
the dd program can be found in cygwin , or on any linux/unix distro.
You can use it in the next way if you like:
dd if=backup.ab of=backup.db bs=1 skip=24
And then use the backup.db file as input for the python script.
or try:
You can use it in the next way if you like:
dd if=backup.ab of=backup.db bs=1 skip=24
And then use the backup.db file as input for the python script.
or try:
python -c "import zlib,sys; sys.stdin.read(24); sys.stdout.write(zlib.decompress(sys.stdin.read()))" <backup.ab | tar -xvf -
Might work of not work depending on file openmode. it should work if binary openmode was used. Not sure about windows python implementation though.
ASKER
after installing cygwin
using below command:
$ dd if=C:\\Users\\Pamela.Rizk\ \Desktop\\ backup.ab bs=24 skip=1|openssl zlib -d > mybackup.tar;
generates below output :
994002+1 records in
994002+1 records out
23856062 bytes (24 MB, 23 MiB) copied, 26.7905 s, 890 kB/s
and using below command:
$ tar -xvf mybackup.tar
generates below output :
apps/com.aims.SocrateMobil e_N/_manif est
apps/com.aims.SocrateMobil e_N/f/SM_D atabase.db 3-shm
apps/com.aims.SocrateMobil e_N/f/SM_D atabase.db 3-wal
apps/com.aims.SocrateMobil e_N/f/SM_D atabase.db 3
but where can I find apps folder?
using below command:
$ dd if=C:\\Users\\Pamela.Rizk\
generates below output :
994002+1 records in
994002+1 records out
23856062 bytes (24 MB, 23 MiB) copied, 26.7905 s, 890 kB/s
and using below command:
$ tar -xvf mybackup.tar
generates below output :
apps/com.aims.SocrateMobil
apps/com.aims.SocrateMobil
apps/com.aims.SocrateMobil
apps/com.aims.SocrateMobil
but where can I find apps folder?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
yes thank you , i could find the file where cygwin is installed.
thank you for your help.
thank you for your help.
ASKER
es thank you , i could find the file where cygwin is installed.
thank you for your help.
thank you for your help.
In this case the blocksize (bs=1) is set to 1 byte and the first 24 (skip=24) bytes are skipped ... all other stuff is then read.and set to stdout.
Use this procedure on a Unix/Linux system. Or try install cygwin to get the commands.