bkerler / edl

Inofficial Qualcomm Firehose / Sahara / Streaming / Diag Tools :)
GNU General Public License v3.0
1.59k stars 372 forks source link

OEM UNLOCK ENABLE NOT WORKING #476

Open saduncan084 opened 10 months ago

saduncan084 commented 10 months ago

I have a Oneplus 9 and get the following error when trying to execute the oemunlock module: saduncan@mac edl % ./edl modules oemunlock enable Qualcomm Sahara / Firehose Client V3.62 (c) B.Kerler 2018-2023. main - Trying with no loader given ... main - Waiting for the device ...... main - Hint: Press and hold vol up+dwn, connect usb. For some, only use vol up. main - Xiaomi: Press and hold vol dwn + pwr, in fastboot mode connect usb. Run "./fastpwn oem edl". main - Other: Run "adb reboot edl".

main - Device detected :) sahara - Protocol version: 2, Version supported: 1 main - Mode detected: sahara sahara - Version 0x2

HWID: 0x001350e100514d67 (MSM_ID:0x001350e1,OEM_ID:0x0051,MODEL_ID:0x4d67) CPU detected: "lahaina" PK_HASH: 0xa26bc25799770106f32c2856606a87ad9c1e997d25b5e80ff30b0e47e4c85e1510d65d26540e3faf0a01f65c1e115652000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 Serial: 0x15d89c6a

sahara - Detected loader: /Users/saduncan/edl/edlclient/../Loaders/oneplus/001350e100514d67_a26bc25799770106_fhprg_op9.bin sahara - Protocol version: 2, Version supported: 1 sahara - Uploading loader /Users/saduncan/edl/edlclient/../Loaders/oneplus/001350e100514d67_a26bc25799770106_fhprg_op9.bin ... sahara - 64-Bit mode detected. sahara - Firehose mode detected, uploading... sahara - Loader successfully uploaded. main - Trying to connect to firehose loader ... firehose - Binary build date: Apr 12 2021 @ 22:27:22 firehose - Binary build date: Apr 12 2021 @ 22:27:22 firehose - Chip serial num: 366517354 (0x15d89c6a) firehose - Supported Functions (15): firehose - program firehose - read firehose - nop firehose - patch firehose - configure firehose - setbootablestoragedrive firehose - erase firehose - power firehose - firmwarewrite firehose - getstorageinfo firehose - benchmark firehose - emmc firehose - ufs firehose - fixgpt firehose - getsha256digest firehose - End of supported functions 15 firehose_client firehose_client - [LIB]: No --memory option set, we assume "UFS" as default ..., if it fails, try using "--memory" with "UFS","NAND" or "spinor" instead ! firehose firehose - [LIB]: Couldn't detect MaxPayloadSizeFromTargetinBytes firehose firehose - [LIB]: Couldn't detect TargetName firehose - TargetName=Unknown firehose - MemoryName=UFS firehose - Version=1 firehose - Trying to read first storage sector... firehose - Running configure... firehose - {'ERROR': '[ffu]FWversion', 'UFS fInitialized': '0x1', 'UFS Current LUN Number: ': ' 0xd0', 'UFS Total Active LU': '0x6', 'UFS wManufacturerID': '0x1ce', 'UFS Boot Partition Enabled': '0x1', 'UFS Raw Device Capacity: ': ' 0xee64000', 'UFS Min Block Size': '0x8', 'UFS Erase Block Size': '0x2000', 'UFS Allocation Unit Size': '0x1', 'UFS RPMB ReadWrite Size: ': ' 0x40', 'UFS Number of Allocation Uint for This LU': '0x0', 'UFS Logical Block Size': '0x0', 'UFS Provisioning Type': '0x0', 'UFS LU Write Protect': '0x0', 'UFS Boot LUN ID: ': ' 0x0', 'UFS Memory Type': '0x0', 'UFS LU Total Blocks': '0x0', 'UFS Supported Memory Types': '0x800f', 'UFS dEnhanced1MaxNAllocU': '0x7732', 'UFS wEnhanced1CapAdjFac': '0x300', 'UFS dEnhanced2MaxNAllocU: ': ' 0x0', 'UFS wEnhanced2CapAdjFac': '0x0', 'UFS dEnhanced3MaxNAllocU': '0x0', 'UFS wEnhanced3CapAdjFac': '0x0', 'UFS dEnhanced4MaxNAllocU': '0x0', 'UFS wEnhanced4CapAdjFac': '0x0', 'UFS LUN Enable Bitmask': '0x3f', 'UFS Logical Block Count': '0x0', 'UFS bConfigDescrLock': '0x0', 'UFS iManufacturerName String Index': '0x0', 'UFS iProductName String Index': '0x1', 'UFS iSerialNumber String Index': '0x2', 'UFS iOemID String Index': '0x3', 'UFS_High_Priority_LUN': '0x0', 'UFS Inquiry Command Output': 'SAMSUNG KLUDG4UHDB-B2D1 1903 '} firehose - {'ERROR': '[ffu]FWversion', 'UFS fInitialized': '0x1', 'UFS Current LUN Number: ': ' 0xd0', 'UFS Total Active LU': '0x6', 'UFS wManufacturerID': '0x1ce', 'UFS Boot Partition Enabled': '0x1', 'UFS Raw Device Capacity: ': ' 0xee64000', 'UFS Min Block Size': '0x8', 'UFS Erase Block Size': '0x2000', 'UFS Allocation Unit Size': '0x1', 'UFS RPMB ReadWrite Size: ': ' 0x40', 'UFS Number of Allocation Uint for This LU': '0x0', 'UFS Logical Block Size': '0x0', 'UFS Provisioning Type': '0x0', 'UFS LU Write Protect': '0x0', 'UFS Boot LUN ID: ': ' 0x0', 'UFS Memory Type': '0x0', 'UFS LU Total Blocks': '0x0', 'UFS Supported Memory Types': '0x800f', 'UFS dEnhanced1MaxNAllocU': '0x7732', 'UFS wEnhanced1CapAdjFac': '0x300', 'UFS dEnhanced2MaxNAllocU: ': ' 0x0', 'UFS wEnhanced2CapAdjFac': '0x0', 'UFS dEnhanced3MaxNAllocU': '0x0', 'UFS wEnhanced3CapAdjFac': '0x0', 'UFS dEnhanced4MaxNAllocU': '0x0', 'UFS wEnhanced4CapAdjFac': '0x0', 'UFS LUN Enable Bitmask': '0x3f', 'UFS Logical Block Count': '0x0', 'UFS bConfigDescrLock': '0x0', 'UFS iManufacturerName String Index': '0x0', 'UFS iProductName String Index': '0x1', 'UFS iSerialNumber String Index': '0x2', 'UFS iOemID String Index': '0x3', 'UFS_High_Priority_LUN': '0x0', 'UFS Inquiry Command Output': 'SAMSUNG KLUDG4UHDB-B2D1 1903 '} firehose - 0x1 firehose_client - Supported functions:

program,read,nop,patch,configure,setbootablestoragedrive,erase,power,firmwarewrite,getstorageinfo,benchmark,emmc,ufs,fixgpt,getsha256digest oneplus - Oneplus protection with prjid 20854 detected firehose - Patch:

firehose - bytearray(b'<?xml version="1.0" encoding="UTF-8" ?>\n\n\n') firehose - Patch:

firehose - bytearray(b'<?xml version="1.0" encoding="UTF-8" ?>\n\n\n') Patched sector 722224, offset 16 with value 1, size in bytes 1. firehose - Reading from physical partition 4, sector 722224, sectors 1 Progress: |██████████| 100.0% Read (Sector 0x1 of 0x1, ) 2.63 MB/s Traceback (most recent call last): File "/Users/saduncan/edl/./edl", line 386, in base.run() File "/Users/saduncan/edl/./edl", line 381, in run fh.handle_firehose(cmd, options) File "/Users/saduncan/edl/edlclient/Library/firehose_client.py", line 901, in handle_firehose return self.firehose.modules.run(command=mcommand, args=moptions) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/saduncan/edl/edlclient/Library/Modules/init.py", line 115, in run return self.generic.oem_unlock(enable) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/saduncan/edl/edlclient/Library/Modules/generic.py", line 101, in oem_unlock if (len(data) > 0x7FFE20) and data[0x7FFE00:0x7FFE10] == b"ANDROID-BOOT!\x00\x00\x00": ^^^^^^^^^ TypeError: object of type 'response' has no len()