Frustrated and about to give up - Have to ask for help

Search This thread

bennylava

Member
Sep 28, 2011
39
0
And here's another one lol

ga9XpAx.png
 

bennylava

Member
Sep 28, 2011
39
0
Use the files provided by codefire , Launch UPPERCUT which will then hook into and launch LGUP automatically (All it does is make LGUP work without errors)


Yes I'm using the files you recommended, provided by codefire. Uppercut does not appear to launch LG UP for me, but maybe it's trying to.

However, when I tried to launch LG UP BEFORE running uppercut for the first time, it wouldn't even start. After running uppercut once, now LG UP will start. I verified that on two computers. But LG UP always gives that error in the pic above. "Invalid KDZ file" or whatever the excuse is.

If I try to use Uppercut to launch LG UP now, it gives me the error below:

PkajA0U.png
 

bennylava

Member
Sep 28, 2011
39
0
It looks like you're running UPPERCUT from the zip file, did you extract the contents of the ZIP file to a folder first?

You were correct, I was trying to flash the wrong one. I was able to flash 20a instead of 30c. It flashed 30c successfully. Now under my "Software Version" in the settings, it says H83030c. So now it's time to Dirtycow, correct? I will now try to use dirtycow.

Do you happen to have a link to that thread, or a thread that you'd recommend that I follow to use the dirtycow exploit?

I was just going to follow this thread here:

 
Last edited:

bennylava

Member
Sep 28, 2011
39
0
Last edited:

bennylava

Member
Sep 28, 2011
39
0
The phone can be in fastboot, or even in the regular OS when sending ADB commands. I recommend this tutorial for using dirtyc0w. Also a quick clarification, do flash 20A and follow the guide.

So I've made it to all the way to dirtycow, and it's time to use this exploit to gain control so I can flash TWRP recovery. I'm following the guide linked below. I'm somewhat intimidated by giving all these commands, as I don't know what most of them do. So I'll just post it up, and place my question in bold italics to the right of each command I don't understand. Hopefully someone here can clear it up for me. From the guide in the link:



adb push dirtycow /data/local/tmp
adb push recowvery-applypatch /data/local/tmp
adb push recowvery-app_process64 /data/local/tmp <-- I think I understand all this. You just put
adb push recowvery-run-as /data/local/tmp all these files in a folder somewhere and
cd to that folder then start using adb to push them to the phone right?


adb shell <-- Switching to a different shell? Weren't we already using the adb shell? Why do this?

$ cd /data/local/tmp <-- Why are we doing this?
$ chmod 0777 * <-- No idea what this is
$ ./dirtycow /system/bin/applypatch recowvery-applypatch <-- Didn't we do all this with the adb push stuff above?
"<wait for completion>"
$ ./dirtycow /system/bin/app_process64 recowvery-app_process64
"<wait for completion, your phone will look like it's crashing>"
$ exit

adb logcat -s recowvery <-- I understand this because I understand using
"<wait for it to tell you it was successful>" adb to issue commands to the phone
"[CTRL+C]"

adb shell reboot recovery
"<wait for phone to boot up again, your recovery will be reflashed to stock>" <-- Ok no problem

adb shell <-- Again, I thought we were already using the adb shell for all this

$ getenforce <-- No idea...?
"<it should say Permissive, adjust source and build for your device!>"

$ cd /data/local/tmp <-- Same question again I guess... the guide never said to place anything in there
$ ./dirtycow /system/bin/run-as recowvery-run-as
$ run-as exec ./recowvery-applypatch boot
"<wait for it to flash your boot image this time>"

$ run-as su <-- I think I understand this.. Super User. Run the next thing as root. Correct?

(You need to rename the twrp img to "twrp.img" and put in the root of your internal storage, OR you can use this adb push command. The next two steps wont be neccessary if already done so.) <-- Ok that won't be a problem I'll just use the adb push command

adb push twrp-3.0.2-x-xxxx.img /sdcard/twrp.img <-- No problem here
adb shell <-- same question as before - Thought we were already using the adb shell?

run-as exec dd if=/sdcard/twrp.img of=/dev/block/bootdevice/by-name/recovery
"<wait for it to complete>" <-- Sounds like it's going to install TWRP now I guess..
$ reboot recovery <-- I understand this.
---
You should be in TWRP now, <-- OK Great finally!
flash supersu and the verity 4.1 zips. <-- How exactly? More adb push commands? I'm a pretty big newb, I honestly don't know what to do here. Fastboot flash? It knows how to unpack a .zip and exactly where to install everything?

[Format Data] will remove internal storage encryption. so back up everything you need to with nandroid. lg backup, or titanium. (So i saw that they have updated verity zips but i just used 4.1)
I prefer lg backup, its easiest.
<--I don't need to save anything

After you format data reflash supersu and verity zips for the hell of it. (you dont have to i dont think but i just did anyway) <-- Since you don't have to, I'm not going to do this. So I guess I should have already put Lineage 17 on my SD card by now? And since I'm already in the TWRP custom recovery, I can just tell it to install Lineage... Correct? If I find that after I've completed all these steps, I'm not in TWRP recovery, do I just power off the phone and hold Volume Up while plugging in the USB C connector, as normal? To get me into TWRP.

Thank you and your help is greatly appreciated!
 
Nov 29, 2020
30
8
Start your adb session in the folder you created that has the 4 items from here

adb shell is different as before you were issuing commands, now you'll be in the shell, like the terminal/command prompt of the device

getenforce checks the status to make sure everything is going properly

cd changes the directory you're in

chmod 0777 * sets the file permissions to allow read/write

"flash supersu and the verity 4.1 zips" none of that is actually necessary (and is actually out of date, once you have TWRP working, if you want root you should flash Magisk, superSU shouldn't be used unless you're running an old Android OS version for something special)

Once you get into TWRP, format/wipe data and the system and slap on the latest Lineage OS

Don't be afraid to try these steps/commands, nothing here would permanently damage your device.

Since I have to redo dirtyc0w on one of my devices, if you still have issues i'll create a video just demonstrating the process.
 
Last edited:

bennylava

Member
Sep 28, 2011
39
0
Since I have to redo dirtyc0w on one of my devices, if you still have issues i'll create a video just demonstrating the process.

It would be wonderful to create a video. It would probably negate the whole reason for this thread lol. If it's not too much trouble, I would greatly appreciate a video!

I'm curious though, which version of Lineage are you running on your G5?

With all of Google's bloat ripped out, maybe these old LG G5 phones are capable of running the latest and greatest version of android? Or is Lineage 17 simply a modified version of 8.0 Oreo?
 
Nov 29, 2020
30
8
Lineage 17.1 runs Android 10, Lineage 18.1 runs Android 11, both very recent and modern mobile OS'.

I'm personally running 17.1 on both LG G5's. Do try the instructions and if you still face issues i'll work out the video.
 

bennylava

Member
Sep 28, 2011
39
0
Lineage 17.1 runs Android 10, Lineage 18.1 runs Android 11, both very recent and modern mobile OS'.

I'm personally running 17.1 on both LG G5's. Do try the instructions and if you still face issues i'll work out the video.

Well I worked on it for a few hours yesterday and a good long while today. I've finally had some time off work to do so. It's not going well, so if it's not too much trouble, yes I would like to ask if you'll make the video. I think the video would serve other people in the future as well.

I know there won't be a ton of people just itching to get an LG G5 like there would've been if this was 2016, but if there are easy instructions to installing lineage, there are bound to be people who would take advantage of a good inexpensive phone like the G5.
 

bennylava

Member
Sep 28, 2011
39
0
I just followed the process on my spare G5 and will be making the video shortly, out of curiosity, what part are you getting stuck at?
Sorry my work schedule prevents me from keeping up with this in a timely manner. I work in the oilfield and I'm gone for weeks at a time sometimes. Been using the phone with old 7.0 lol

Do you have a link to the video you created?
 

bennylava

Member
Sep 28, 2011
39
0
I've been busy, luckily the video is not hard to make. Within the next few days i'll post it. What steps are you still having issues with?

Well it's been about two months since I made the attempt, so I'd probably have to go back and try again to remember exactly what I ending up sticking on. IIRC it had something to do with my uncertainty of what one of the commands did, and thus what exactly to do following that. I remember being unsure so I deemed it unsafe to continue. I was afraid of a brick.

But at this point instead of continuing to struggle, I'll probably just go buy a phone that's proven easy to install Calyx. I would say lineage, but if I'm getting a new phone I might as well close the bootloader security hole while I'm at it.