[Q] How to decode WhatsApp crypt8-files whit Cygwin, it show me an error - Android Q&A, Help & Troubleshooting

Hi, sorry for my bad english, i try my best.
I want to decode my crypt8-file with Cygwin and i got this error-message: gzip: msgstore.gz: not in gzip format (see image).
Please help.

Cm11 said:
Hi, sorry for my bad english, i try my best.
I want to decode my crypt8-file with Cygwin and i got this error-message: gzip: msgstore.gz: not in gzip format (see image).
Please help.
Click to expand...
Click to collapse
If you are using a recent version of WhatsApp then this method will not work as the iv is no longer stored in the key file. See: Decrypting WhatsApp crypt8 >= v2.12.38.

TripCode said:
If you are using a recent version of WhatsApp then this method will not work as the iv is no longer stored in the key file. See: Decrypting WhatsApp crypt8 >= v2.12.38.
Click to expand...
Click to collapse
Hi TripCode,
thanks for the answer, but i get the same error-message. Have you another idea?

Cm11 said:
Hi TripCode,
thanks for the answer, but i get the same error-message. Have you another idea?
Click to expand...
Click to collapse
Can you confirm that aes.txt and iv.txt have data written to them and what size is msgstore.gz? There could be a few things wrong. Just a question of narrowing things down.

TripCode said:
Can you confirm that aes.txt and iv.txt have data written to them and what size is msgstore.gz? There could be a few things wrong. Just a question of narrowing things down.
Click to expand...
Click to collapse
Hi TripCode,
After the decryption, I get all this files. (See the image. ) But I can´t extract the msgstore.gz file because it is corrupted.

Cm11 said:
Hi TripCode,
After the decryption, I get all this files. (See the image. ) But I can´t extract the msgstore.gz file because it is corrupted.
Click to expand...
Click to collapse
Having same issue here?
Did you come up with any solution or any proper explanation on this ?

Most likely scenario is that either the tools being utilized aren't functioning properly (common on Windows if using Cygwin as it's hit and miss) or the cipher key has rolled to a new algorithm. Try on Unix or use WhatCrypt (either online version or offline).

Related

[Q] Decompress kernel

Hi.
I noticed the kernel in all the boot images we have here are compressed.
Looks like gzip BUT, when you try to decompress it it just adds a bunch of bytes to the file top.
So is there any way to decompress dell's kernel?
Thanks.
maxrfon said:
Hi.
I noticed the kernel in all the boot images we have here are compressed.
Looks like gzip BUT, when you try to decompress it it just adds a bunch of bytes to the file top.
So is there any way to decompress dell's kernel?
Thanks.
Click to expand...
Click to collapse
I don't think there is at the moment.
We're currently waiting for dell to release the source code for the kernel, like they're legally obliged to
Meltus said:
I don't think there is at the moment.
We're currently waiting for dell to release the source code for the kernel, like they're legally obliged to
Click to expand...
Click to collapse
Thanks, but i mean just decompress.
I made it on windows machine - winrar does the trick. But now i need to compress it back to flash with fastboot.
Btw where is the fastboot topic? Could anyone please point me in the right direction (but not to the search please).
maxrfon said:
Thanks, but i mean just decompress.
I made it on windows machine - winrar does the trick. But now i need to compress it back to flash with fastboot.
Btw where is the fastboot topic? Could anyone please point me in the right direction (but not to the search please).
Click to expand...
Click to collapse
ah, sorry, i thought you meant decrypt.
I'm not sure you could just flash it again after compressing it, wouldn't you need to sign it with google's test keys?

[Q] Xperia Firmware & Rooting

Hi,
I'm considering buying the Xperia-S but I have no information about Sony's policy in modding & tweaking. I don't plan to install custom kernels / recoveries / rom's initially & would only want to root the device & maybe customise it a little.
How good is Sony's support in updates & How easy is it to stay close to stock & still be rooted ?
I was browsing the development subforum & came across the thread with the stock firmware at : http://forum.xda-developers.com/showthread.php?t=1527319.
I downloaded Xperia_S_(LT26)_6.0.A.3.62_1252-0023.rar & LT26i_6.0.A.3.62_NCB World.ftf. I've extracted both the files & managed to get the system.sin files but I dont know how to browse / extract them.
I found a link to an old utility 'Xperia ROM Manager' which comes with mkyaffs.exe, SIN2IMG.exe & unyaffs.exe but I'm stuck as I cant get the output from the sin to img to mount in linux.
Any pointer in the right direction would help. Thank You.
Snmjm said:
Any pointer in the right direction would help. Thank You.
Click to expand...
Click to collapse
Yes, not to create new topic and continue discussion in the right thread.
I'm Sorry to have offended you but which is the right thread for a question like this ?
I thought posting something on the dev thread would be wrong & the thread with the utilities ( mkyaffs.exe, SIN2IMG.exe & unyaffs.exe) wasn't in the Xperia S forums but a year old thread for other SE devices.
Hey.
Use our FreeXperia/CM sin2img converter. It works better than the windows tools.
https://github.com/defer/semc-xperia-tools/blob/master/sin2img.py
After that extract the partitions, but its not yaffs its ext4. So if you are running linux system you can simply mount with:
mount -o loop system.img /home/yourname/folderwhereitgetsmounted
Have fun
Thank You so much.
I'm new to Xperia but not to android. I know how to root my desire-hd & a little about theming. Is there a wiki where general information about Xperia is available ?
Right, I am sorry for the above. I focused more on you topic name, rather than post itself. I apoligize.
Snmjm said:
Thank You so much.
I'm new to Xperia but not to android. I know how to root my desire-hd & a little about theming. Is there a wiki where general information about Xperia is available ?
Click to expand...
Click to collapse
http://forum.xda-developers.com/showthread.php?t=1526866
No worries.
Bin4ry said:
Hey.
Use our FreeXperia/CM sin2img converter. It works better than the windows tools.
https://github.com/defer/semc-xperia-tools/blob/master/sin2img.py
After that extract the partitions, but its not yaffs its ext4. So if you are running linux system you can simply mount with:
mount -o loop system.img /home/yourname/folderwhereitgetsmounted
Have fun
Click to expand...
Click to collapse
I am getting the below error when running the script with system.sin from .62 firmware
Code:
Traceback (most recent call last):
File "sin2img.py", line 52, in <module>
convert (sin, img)
File "sin2img.py", line 28, in convert
bt = sinfile.read(2)
File "D:\Python32\lib\encodings\cp1252.py", line 23, in decode
return codecs.charmap_decode(input,self.errors,decoding_table)[0]
UnicodeDecodeError: 'charmap' codec can't decode byte 0x8f in position 130: character maps to <undefined>
I tried it in linux & it worked. Maybe you can try it using a live cd or install linux in a vm
Bin4ry said:
Hey.
Use our FreeXperia/CM sin2img converter. It works better than the windows tools.
https://github.com/defer/semc-xperia-tools/blob/master/sin2img.py
After that extract the partitions, but its not yaffs its ext4. So if you are running linux system you can simply mount with:
mount -o loop system.img /home/yourname/folderwhereitgetsmounted
Have fun
Click to expand...
Click to collapse
Hi, i have debian installed, how can i use sin2img.py? i mean, what commands and what packages do i need to make it work? because i only get "command not found" error
Yakandu said:
Hi, i have debian installed, how can i use sin2img.py? i mean, what commands and what packages do i need to make it work? because i only get "command not found" error
Click to expand...
Click to collapse
use your python path, for example i'm using redhat and my python path is /usr/bin/python, then the command is
# /usr/bin/phyton sin2img.py system.sin system.img

[Q] Need help with bin2sin

Hello,
I am using the bin2sin tool at http://forum.xda-developers.com/showthread.php?p=17357668. But I need some clarification - how to get the 'partition info' from the SIN file? Say, now I've got an official SIN file of the kernel (boot) partition, what could I do to extract the partition address? I actually have no clue where DATA (oops, don't leave the thread yet - accept my apology for being a noob!) is. I attempted to use the address at(and after) 0000147a, but that's a non-sense number. If possible, please kindly point out where the 'DATA' actually resides.
Thanks in advance,
klikli said:
Hello,
I am using the bin2sin tool at http://forum.xda-developers.com/showthread.php?p=17357668. But I need some clarification - how to get the 'partition info' from the SIN file? Say, now I've got an official SIN file of the kernel (boot) partition, what could I do to extract the partition address? I actually have no clue where DATA (oops, don't leave the thread yet - accept my apology for being a noob!) is. I attempted to use the address at(and after) 0000147a, but that's a non-sense number. If possible, please kindly point out where the 'DATA' actually resides.
Thanks in advance,
Click to expand...
Click to collapse
watch this
http://forum.xda-developers.com/showpost.php?p=17384177&postcount=3
it will surely help u!!

**SOLVED** nandroid backup MD5 issues... desperate here :(

Hi guys,
I currently have a Zopo ZP300 phone
I have no issues getting CWM to install or work, but when trying to create a rom backup things start to go funny.
Firstly, the backup takes hours to complete.. 2~3 hrs.
- I end up with :
boot.img approx 3.8 Gigs in size
cache.ext4.tar approx 17kb
data.ext4.tar approx 334 MB
recovery.img approx 3.8 Gigs
system.ext4.tar approx 386 MB
Secondly, when the backup completes, i am greeted with "Error while generating md5 sum"...
I have factory reset the phone, i have wiped all caches, Dalvik etc, etc... no luck.
I have also tried Terminal Emulator to generate a MD5 and end up with nandroid.md5 of 0 Kb in size which is useless..
Anyone ??
Get 4EXT recovery and you will never have any sort of problems installing or updating custom roms. Its free, constant updates, touch based interface, and easier to use than clockwork.
Sent from my HTC Desire using xda app-developers app
chico1620 said:
Get 4EXT recovery and you will never have any sort of problems installing or updating custom roms. Its free, constant updates, touch based interface, and easier to use than clockwork.
Sent from my HTC Desire using xda app-developers app
Click to expand...
Click to collapse
Is it compatible with ZP300 ?
Can you make backup with it ?
Cheers
Not sure about compatibility but yes you can make backups everything you do with clockwork you can do with 4EXT and more
Sent from my HTC Desire using xda app-developers app
chico1620 said:
Not sure about compatibility but yes you can make backups everything you do with clockwork you can do with 4EXT and more
Sent from my HTC Desire using xda app-developers app
Click to expand...
Click to collapse
Thx for the help but app not compatible
cheers
Ok.
I tried again to make a backup, but again i get "could not generate md5 file" error.
So now i tried to make md5 using ABD and md5sum command, but i get "sh: md5sum: not found" error.
I also tried terminal emulator with same result..
Now what do i do ? Why do i get "not found" error ?
Is there another way to make md5 ?
I really need to make a reliable nandroid backup...
vvulture said:
Ok.
I tried again to make a backup, but again i get "could not generate md5 file" error.
So now i tried to make md5 using ABD and md5sum command, but i get "sh: md5sum: not found" error.
I also tried terminal emulator with same result..
Now what do i do ? Why do i get "not found" error ?
Is there another way to make md5 ?
I really need to make a reliable nandroid backup...
Click to expand...
Click to collapse
Recovery might be generating a corrupt md5.
Ok try this:
Code:
cd /sdcard/clockworkmod/backup/XXXXXX/
rm nandroid.md5
md5sum *.img > nandroid.md5
This should do the trick because the md5sum file must be named nandroid.md5
venoma333 said:
Recovery might be generating a corrupt md5.
Ok try this:
Code:
cd /sdcard/clockworkmod/backup/XXXXXX/
rm nandroid.md5
md5sum *.img > nandroid.md5
This should do the trick because the md5sum file must be named nandroid.md5
Click to expand...
Click to collapse
Thx so much for replying venoma....
Since posting this, i found another thread ( post #112 ):
http://forum.xda-developers.com/showthread.php?t=714114&page=12
It actually generated a MD5 file. :laugh:
Now, as i type, i started a recovery process to test, and so far so good.
Cheers :good:
**UPDATE**
Restore completed successfully !! Yay !! :good:
Big thank you to those that helped...
Where to find a working clockworkmod recovery for the ZOPO ZP300?
THank you!
blackspawn2 said:
Where to find a working clockworkmod recovery for the ZOPO ZP300?
THank you!
Click to expand...
Click to collapse
There ---> http://bbs.zopomobile.com/forum.php?mod=viewthread&tid=21332&highlight=卓普ZP300
The site is in Chinese but Google translate is your best friend. Also, you need to register in order to get the app.
ALso, the app is in Chinese, but the menu structure of CWM is the same as the english version of CWM.
Cheers
vvulture said:
There ---> http://bbs.zopomobile.com/forum.php?mod=viewthread&tid=21332&highlight=卓普ZP300
The site is in Chinese but Google translate is your best friend. Also, you need to register in order to get the app.
ALso, the app is in Chinese, but the menu structure of CWM is the same as the english version of CWM.
Cheers
Click to expand...
Click to collapse
Thank you for the answer.
I registered but i cannot download the app.
Can you please upload it on a file hosting server.
blackspawn2 said:
Thank you for the answer.
I registered but i cannot download the app.
Can you please upload it on a file hosting server.
Click to expand...
Click to collapse
Done..
http://www.4shared.com/rar/QkXmiU4j/zp300_120621_cmw_recovery.html
UPDATED 29/7/2012 with new download link
vvulture said:
Done..
http://www.4shared.com/rar/9-56_6Xx/zp300recovery-20120622__1_.html?refurl=d1url
Click to expand...
Click to collapse
Thank you so much!
blackspawn2 said:
Thank you so much!
Click to expand...
Click to collapse
Can you please explain to me how to flash it???
thanks
ya-big said:
Can you please explain to me how to flash it???
thanks
Click to expand...
Click to collapse
There is now an official english version of CWM for ZP300
http://www.4shared.com/rar/QkXmiU4j/zp300_120621_cmw_recovery.html
Use this to flash : http://www.zopomobileshop.com/download/SP_Flash_Tool_v3.1206.01.rar
Cheers
Ok, using spflash i have already upgraded the official rom to the latest version, but i cant install this recovery in my zp300...whats wrong? is there a proper procedure for flashing this recovery?
BROM ERROR: S_DL_GET_DRAM_SETTING_FAIL (5054)
[EMI] Obtain DRAM Failed!
[HINT]: Please check your load matches to your target which is to be downloaded
help please
venoma333 said:
Recovery might be generating a corrupt md5.
Ok try this:
Code:
cd /sdcard/clockworkmod/backup/XXXXXX/
rm nandroid.md5
md5sum *.img > nandroid.md5
This should do the trick because the md5sum file must be named nandroid.md5
Click to expand...
Click to collapse
i'm coming up with the same problem, md5 sum stuff..
i'm on xperia play.
and how to do this?
Code:
cd /sdcard/clockworkmod/backup/XXXXXX/
rm nandroid.md5
md5sum *.img > nandroid.md5
i have to do this with terminal emulator?
md5sum: not found
I installed busybox but can not install md5sum.exe
please help me Xperia play r800x

How To Guide Automated GSI build script (Linux/WSL)

I've spent last day automating the guide at https://forum.xda-developers.com/t/guide-t220-t225-flash-a-gsi-on-the-a7-lite-without-twrp.4456821/ into a bash script (linux only)!
Here it is releasing it for anyone that needs it
Code:
I am not responsible whatever happens to your device
by using this script, i have tested it on my own device
and it worked but it may or may not work for you.
I will do my best to help you but that may be limited
as i have other responsibilities in life
Before starting read the third post
Usage​Download the your desired firmware from somewhere like samfw.com and extract it
Download your desired GSI image and extract it
Download otatools-mini, gsi-build script and vbmeta image, place them all together inside one directory (extract the otatools-mini next to the script)
Download patched odin
Run this in Linux or WSL!
Code:
$ ./build-gsi.sh <PATH TO YOUR AP FILE .tar.md5> <PATH TO GSI .img>
And let it do the work, may take a while depending on your PC
You may get something like this in the process, ignore it
Code:
Invalid sparse file format at header magic
Then go into download mode (VOLUME UP and DOWN when plugging in USB) and flash the CUSTOM_AP file you got from the script and BL, CSC from the firmware you used, DO NOT USE HOME_CSC
Reboot into recovery and factory reset (VOLUME UP while booting)!
If you are getting dm-verify error then flash the vbmeta_disabled_R (it needs to be .tar, extract it) in odin as AP and try rebooting again into recovery
Downloads​I used to provide one archive but it was large and i couldnt change the script without reuploading it so i am going to use gist for the script and provide other files separately
ota-tools-mini
build-gsi.sh
Getting Help​If you want me to help you ALWAYS post full output from the script, and make sure to use the latest script from the gist
I've spent a lot of time trying to make it work with all GSIs but i could not get it to work consistently
By default it works for all smaller GSIs, if you get the following error
Code:
ERROR: Output image is bigger than original super image, rerun the script with correct super image size
Then you will have to manually provide the new super size which i cannot help you with try to guess but it has to be divisible by 512
Not enough free space to expand partition: vendor
error while repacking
i have a lot of space . but it shows me like that
lpmake E 01-15 23:22:16 100 100 builder.cpp:698] [liblp]Not enough free space to expand partition: vendor
i am using debian wsl
Please post full script log in a spoiler or pastebin
sandorex said:
Please post full script log in a spoiler or pastebin
Click to expand...
Click to collapse
Could you try normal AP file not the magisk patched, i do not know how it modifies it
Also from my experience you do not need to patch whole AP file for magisk, you just need to patch the boot.img, zip it then flash it
OK . i will try
i tried with original ap file but same error
dxsyrz said:
i tried with original ap file but same error
Click to expand...
Click to collapse
It seems for some reason your gsi is too big, i managed to reproduce it, ill see if i can fix it
@dxsyrz can you test this one, it should work now
EDIT: i've updated the gist so you can just use that instead
good util but test more.
tom.android said:
good util but test more.
Click to expand...
Click to collapse
It worked for me, i would not release it if it did not work
sandorex said:
It worked for me, i would not release it if it did not work
Click to expand...
Click to collapse
OK sorry to write that message.
sandorex said:
It worked for me, i would not release it if it did not work
Click to expand...
Click to collapse
Well, something did not work in my case:
:: Uncompressing super image
super.img.lz4 : decoded 5637366988 bytes
:: Running simg2img
./build-gsi.sh: line 79: /mnt/c/Users/Zero/Desktop/otatools-mini/otatools-mini/simg2img: No such file or directory
^ Despite the files actually existing. You tell me cuz I've no idea (do note I do know how to do this manually, was just trying your script to simplify everything).
nirogu325 said:
Well, something did not work in my case:
:: Uncompressing super image
super.img.lz4 : decoded 5637366988 bytes
:: Running simg2img
./build-gsi.sh: line 79: /mnt/c/Users/Zero/Desktop/otatools-mini/otatools-mini/simg2img: No such file or directory
^ Despite the files actually existing. You tell me cuz I've no idea (do note I do know how to do this manually, was just trying your script to simplify everything).
Click to expand...
Click to collapse
You need to place otatools-mini in folder next to the script not together with the script
hi i have this problem
izimen said:
hi i have this problem
View attachment 5814501
Click to expand...
Click to collapse
You havs a space in your path, its actually a bug but you can jist move the files to somewhere without spaces
EDIT: Fixed it on gist
sandorex said:
You havs a space in your path, its actually a bug but you can jist move the files to somewhere without spaces
EDIT: Fixed it on gist
Click to expand...
Click to collapse
ok i try
bro it worked thank you I managed to make it work with a GSI and when I try with another I have this error

Categories

Resources