edl icon indicating copy to clipboard operation
edl copied to clipboard

MacOS 10.10.5

Open ruckusman opened this issue 3 years ago • 6 comments

Trying to get this built on Yosemite The system has python 2.7 installed by default, which cannot be removed

I've got Python 3.9.7 installed python -V returns that correctly

Set the following environment variables in .bash_profile PATH="/Library/Frameworks/Python.framework/Versions/3.9/bin:${PATH}" export PYTHONPATH="/Library/Frameworks/Python.framework/Versions/3.9" alias python=/usr/local/bin/python3.9 alias pip=/Library/Frameworks/Python.framework/Versions/3.9/bin/pip3

Pip3 is installed correctly which pip /Library/Frameworks/Python.framework/Versions/3.9/bin/pip

When running sudo python setup.py install it throws a lot of syntax error because it's trying to build against 2.7 - edl-3.5-py2.7.egg

which python returns /usr/bin/python

/usr/bin/python -V returns 2.7.10 which is my problem

I know it's picking up the 2.7 install from somewhere, but I am unsure which environment variable I've missed or which part of the install I can modify

Any help appreciated

thanks

Glenn

ruckusman avatar Sep 14 '21 14:09 ruckusman

Just solved it myself with ln -s -f /usr/local/bin/python3.9 /usr/local/bin/python

Now I can probably go and undo all of those environment variables one at a time to see which ones are actually necessary

ruckusman avatar Sep 14 '21 15:09 ruckusman

OK, So I am bit further along

The device is working fine, I am trying to make an image of the data partition as the phone is my brother's and he took his own life and his former girlfriend deleted images and other data

So my objective is to read just the data partition to attempt data recovery

I know I don't have the correct loader - see below I have downloaded from Oppo the firmware which is CPH1879EX_11_OTA_3130_all_FoZra0hfw2Cz.ozip

Can I extract the required loader from the downloaded firmware package? I've done some more reading and made more progress, managed to extract the encrypted ozip.

Am I headed in the right direction? I know I'm missing something basic

`edl.py r data data.img --memory=ufs --vid=0x05c6 --pid=0x9008 Qualcomm Sahara / Firehose Client V3.52 (c) B.Kerler 2018-2021. main - Trying with no loader given ... main - Waiting for the device main - Device detected :) main - Mode detected: sahara Device is in EDL mode .. continuing. sahara -

HWID: 0x000910e100510000 (MSM_ID:0x000910e1,OEM_ID:0x0051,MODEL_ID:0x0000) CPU detected: "SDM670" PK_HASH: 0x91057040b895b1d63f856124589c22adc2ece0ce5b15fc1bd925541c683115b9 Serial: 0x7769a139

sahara sahara - [LIB]: Couldn't find a loader for given hwid and pkhash (000910e100510000_91057040b895b1d6_[FHPRG/ENPRG].bin) :( Device is in an unknown sahara state, resetting resp={'cmd': 1, 'len': 48, 'version': 2, 'version_min': 1, 'max_cmd_len': 1024, 'mode': 0, 'res1': 0, 'res2': 0, 'res3': 0, 'res4': 0, 'res5': 0, 'res6': 0, 'object_size': 48, 'raw_data': bytearray(b'\x01\x00\x00\x000\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x00\x04\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00')}`

ruckusman avatar Sep 15 '21 03:09 ruckusman

Hi, I guess I can upload the firehose loader, but sorry to say, the oppo devices I know use VIP programming, so even if you have a firehose loader, chances are high you can't do anything as all transactions have to be signed.

bkerler avatar Sep 15 '21 06:09 bkerler

Thank you

I've just run ./fhloaderparse.py ~/Desktop/oppo/R17/R17/firmware-update ../examples

It doesn't seem to yield any useful binaries, but this output seems promising

The PK hash is correct at least

OEM:Foxconn/Sony MODEL:0000 HWID:6004000000010000 SWID:000000000000000B SWSIZE:00000020 PK_HASH:91057040b895b1d63f856124589c22adc2ece0ce5b15fc1bd925541c683115b9 ~/Desktop/oppo/R17/R17/firmware-update/xbl.img 3160792 OEMVER:ubuntu-16 QCVER:BOOT.XF.2.1-00119-SDM710LZB-1 VAR:SDM670LA

ruckusman avatar Sep 15 '21 06:09 ruckusman

Hi, I guess I can upload the firehose loader, but sorry to say, the oppo devices I know use VIP programming, so even if you have a firehose loader, chances are high you can't do anything as all transactions have to be signed.

There are also some interesting certificates in the decrypted and decompressed firmware file that I downloaded.

I know in all of the other threads that I researched before posting that it is the issue with the Oppo phones

I don't know if it's of assistance...

Screen Shot 2021-09-16 at 2 27 37 am

ruckusman avatar Sep 15 '21 16:09 ruckusman

Hi Bjoern,

I don't know if this is a clue, however I have noticed that looking into the firmware images and elf binaries there is - see qupv3fw.img - the data strings in that binary USE_SERIAL_NUMBER_IN_SIGNING

I'm just groping in the dark really, but it seems logical to me that for an OTA firmware to install, there would need to be the validation calculation done at install time

Glenn

On Wed, Sep 15, 2021 at 4:31 PM Bjoern Kerler @.***> wrote:

Hi, I guess I can upload the firehose loader, but sorry to say, the oppo devices I know use VIP programming, so even if you have a firehose loader, chances are high you can't do anything as all transactions have to be signed.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/bkerler/edl/issues/149#issuecomment-919738559, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJZIX3WCZNS47C2LNT5GPDUCA4SPANCNFSM5EALKM7A . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

ruckusman avatar Sep 17 '21 06:09 ruckusman