yashsingh1/xdaforums huggingface dataset:
[LG Optimus G Pro] MrDSL:
@djrbliss successfully ported Loki to the Optimus G Pro, allowing flashing custom kernels and recoveries. If you believe this satisfies the bounty, please contribute your pledge to his PayPal account at goo.gl/zBGb0. [MENTION=1157052]thecubed[/MENTION] is continuing work on this device, including porting CWM recovery. If you feel his work is deserving of donations, I encourage you to donate, but please realize this work is separate from the bootloader unlocking bounty.

If you want to pledge/donate to thecubed's Paypal email which you can find in his profile I linked.

If you see any errors please let me know. Thank you for your pledge and big thanks to thecubed for working on this :victory:

Total so far = $895

MrDSL $50

MrNa5ty $20

dnorthington $15

ricco333 $40

3_D $20

RaptorMD $25

CXENTE $20

Funk2641 $40

idle0095 $50

ReggieSmith $20

z28tovette $10

morgej $25

barondebxl $40

jprosek $15

smaybe $20

jwiskowski $50

zxaz $20

trooper1414 $20

willdeng $20

buff31 $25

st1114g $50

merkyone $20

singhjay $25

lessthanzach $10

inkdrink $25

nthknd $20

scottypimpin636 $10

mrfeuss $20

martinezma99 $50

Dancingrock $10

rougetor $100 (hope its legit)

Timisone $10
[LG Optimus G Pro] scottypimpin636:
Add me for $10
[LG Optimus G Pro] mrfeuss:
$20 from me!
[LG Optimus G Pro] z28tovette:
I'm really pulling for you guys,hope the bootloader gets unlocked and this support comes from a note 2 owner.

sent from a CARBON fiber NOTE 2
[LG Optimus G Pro] nthknd:
Just sent my payment thanks so much for your work
[LG Optimus G Pro] thecubed:
Should I start posting over here now?

I'm going to try a custom kernel today to see if I can get tethered booting working... but before that I think I'll have a special screenshot for y'all :)

(I have verified that Loki does indeed work on this phone. I've been able to overwrite LK strings with a specially crafted boot.img file, however the kernel is the issue now)
[LG Optimus G Pro] MrDSL:
yes please and thank you :)
[LG Optimus G Pro] Jasbo:
Excellent news!
[LG Optimus G Pro] martinezma99:
Add me for $20.00
[LG Optimus G Pro] Dancingrock:
Put me down for 10 dollars!
[LG Optimus G Pro] Jammol:
Guys please instead of pledging, just send it to cubed.
[LG Optimus G Pro] merkyone:
Sent mine.
[LG Optimus G Pro] thecubed:
I <3 all of you guys. Thanks much!

It's been a busy day at work today, and the power went out at my house, so I wasn't able to finish my IDA disassembly work remotely on my home PC's VM...

All of my servers are linux based, and my copy of IDA is for windows, so...

I threw together a box at work and put windows server on it. I've forgotten how much of a windows server noob I am haha.

Anyway, that said, I now have an IDA box that me and Shelnutt2 can share. I'm going to try damn hard to get you guys a 'victory-in-progress' screenshot here soon... I'm 100% confident that I can make Loki work, the real issue here is kernel.

An idea that I've been toying with is a neat way to actually root/install all of this at once.

I've created a python replacement for LGNPST, which we can bundle with the root/unlocker-- put the phone in LGNPST mode and you'll end up with a rooted and CWM/TWRP'd phone.

This would be to solve the issue of a lack of fastboot under normal circumstances, since there's no way to enter fastboot without nuking boot or recovery.

Another option is to compile my own version of Moboot (LK) and put it in place of the boot partition. On boot, the phone would boot another bootloader, and we could store our boot.img files in /cache, since that's rarely used.

All of that would be an interim solution until I can get SBL3 unlocked so we can just replace LG's weird-ass bootloader altogether.

Anyway, lemme know what you guys think is the best option. I'm going to try to get a screenshot up for y'all tonight.
[LG Optimus G Pro] evanrwolfe:
I think that rooting and installing all at once would be the best option for now. At least it sounds the best to me. Thanks
[LG Optimus G Pro] kevinwzh:
Hi Cube,

My phone is F240L, your solution can be working on it?
[LG Optimus G Pro] andygold:
If you store the imags in cache, what happens if we run one of the commonly available "housecleaning" programs like Clean Master that clears the cache? Would we lose the images we need?
[LG Optimus G Pro] thecubed:
Indeed you would. However, in my experience, cache isn't used for much and doesn't need to be cleaned anyway (for most problems, that is).

Doesn't look like I'm going to have a screenshot up tonight. I'm heading to bed now.

Finally got my IDA box working, but the IDA db wouldn't load, so I'll have to figure that out tomorrow.

Thanks for sticking with me, guys!
[LG Optimus G Pro] ywj3567:
:good:
[LG Optimus G Pro] bttfpromo:
To be fair, he hasn't completed the work, so there's a reason people are pledging and not sending.

Not to mention that it is a bounty. Someone could post on here in 5 minutes a complete method before thecubed does, and they would deserve the money.
[LG Optimus G Pro] Gotroot:
Yo cube im with you something is broke inside the kernel.After decompressing it and tring to recompile the kernel is flawed.Even do it with the opensource..IDK what to think I will keep plugging away.
[LG Optimus G Pro] Gotroot:
Ya def not booting to CWM been tring for a while not. it transfer the file but when I shut down and reboot alls I get it factory recovery...

thanks
[LG Optimus G Pro] thecubed:
Hey, I've got a CWM image that I've built that'll work for you. Gimme a few hours and I'll PM you a link (the only tested one I have around is on my work computer).

ALSO, please don't flash with the mmcblkX numbers, we've got GPT on this device, so flashing to /dev/block/platform/msm_sdcc.1/by-name/recovery will work too (it's a link to the proper mmcblkX device).

In regards to what you said earlier about the bounty -- I support what you said. You've put most of the work into finding your exploit and creating the Loki tool. I really hate bounties since it tends to make this uneasy competition between talented devs and it fractures the community, however at this point, I just want what you think is best. I am indeed a beginner when it comes to hardcore assembly reversing in IDA, so yeah, finding offsets and things like that do take quite some time for me. That said, I do have a rather strong grasp on how you're accomplishing your exploit, I just lack IDA experience with the subtleties of reversing.

In regards to testing-- here's the best way to do it:

0. copy / pull boot and recovery to your desktop

1. back up your MISC partition and pull it to your desktop

2. copy boot to recovery

3. wipe recovery

4. adb reboot

5. fastboot flash boot <testing.img>

Then, if this doesnt boot, you can simply hold the buttons to get into recovery, it'll go into android like normally. From there, you can restore your MISC partition.

I've got a script I used when I ported CWM to the LG Revolution 4g that does the cleansing of the boot command, so I'll roll it into a CWM image.

Please if you have any questions ask me, I'm willing to help out.
[LG Optimus G Pro] nthknd:
Thanks for all the work everyone's putting in. The bounty almost seems to be creating some division which I hate. I donate to the cube and ill do the same to dan.. I believe that's fair from my side. Also I just want to say lets not treat people like we treat our phones.. as soon as the next "best" thing comes out we discards the other. Lets reward people for the loyalty and hard work. Just my 2 cent.
[LG Optimus G Pro] apascual89:
[MENTION=1157052]thecubed[/MENTION] Dan doesn't do Pm AFAIK.
[LG Optimus G Pro] thecubed:
Alright, I'll post it here.

However, I just realized that the only confirmed copy I have (the one from the video) is on my work PC. I have an untested one (can test easily by fastboot booting it).

I'll post the tested one when I get to work.

Here it is:

http://downloads.codefi.re/thecubed/lgoptimusg_pro/recoveries/gkatt-cwm_recovery.img

It should boot just fine if you fastboot boot it per my instructions. DO NOT FLASH IT!

This has my patched kernel (the one from my github) and a JB_4.2 CWM recovery, unlike the video which has the same kernel as the one in my github, but was an ICS recovery.

The fstab in here is actually correct, so it indeed will be usable as a recovery (barring the MISC flag issue) for the time being.
[LG Optimus G Pro] andygold:
Haven't chimed in yet on this one. I fully understand about bounties and I recognize that in the corporate world requests for proposals are put out and many companies might spend hard earned resources into mocking up equipment, and using time towards coming up with a viable solution to the proposal.....

I also realize that the devs here are not corporations, with funds/time set aside to work on proposals that they might not win.

With that said, when the bootloader is unlocked, and a newbie such as myself has a tutorial on how to use the tools that the developers come up with, I will be donating some funds. But I will donate not just to the entity that solves the problem, but to the other(s) who helped along in the process.

IMHO someone who has put forth the effort to help us (bounty or no bounty) should be rewarded in some fashion! I look at it like this...why would a developer even attempt to put forth the effort, when one more-knowledgeable can come along at the last moment and take it all. Yes, that's the idea behind a bounty, but I think it can also cause developers to say "why bother", because so and so might step in at the last minute and all my work was for naught!...

Bounties are a driving force, but they also can cause apathy/pessimism in those that might not be at the highest ranks of the game. Then the problem is that those at the highest ranks either might not be interested in our devices, or might not have the time to develop for us. And we are left with no development!

So, as stated above, I will make efforts to reward those who have taken the initiative to do what I myself could not.

Ok, I'm off my soapbox! :p
[LG Optimus G Pro] Gotroot:
16948+0 records in

16948+0 records out

8677376 bytes transferred in 1.573

that's what terminal pops up after sending
[LG Optimus G Pro] madmack:
I'm starting to think that volume down + menu + power might not be booting recovery. Anyone knows for sure what hardware combo will get the bootloader to load the recovery partition?
[LG Optimus G Pro] shabbypenguin:
we hit a similar issue on the lg motion, trying to figure it all out :/
[LG Optimus G Pro] Gotroot:
well I have the 2nd recovery installed and to get to it you hold up and power until you see lg logo. then when the lg logo pops back up press the power button again while still holding up will put you into 2nd CWM
[LG Optimus G Pro] madmack:
if you haven't flashed the loki images yet and you're on stock, can you type "adb reboot recovery" and see what you get? I'm getting a dead android image but I'm wondering whether this is happening because I messed up with some other partitions. I'm getting this exclamation mark even when I flash back the 'stock recovery'.
[LG Optimus G Pro] Gotroot:
Ya I already put the loki file over with dd but I can try to boot the adb recovery reboot see what happens
[LG Optimus G Pro] madmack:
Got somewhere

First of all, as I suspected. volume down + home + power is NOT booting the recovery partition. Also, "adb reboot recovery" will not work even with stock recovery. I'm not sure how to programmatically get in.

Instead, you should shut down the device, then volume UP + home + power. Keep pressing this combo, the LG logo will flash on and off a few times and then the notification LED will glow with different colors and the screen will remain black. That is our recovery. "adb devices" recognized it as such and I was actually able to get in and even "su" with the stock recovery.

So.. Now I flash the recovery.lok image that Dan supplied earlier. Shut down, then do the new buttons combo. The first few LG logo gave a weird message on top that made no sense at all:

====

secure booting error.

cause: device unlock so boot success!!!

====

Yea I know :rolleyes:

But here is the cool thing, the device continued to boot and got into recovery just fine ! the same old blank screen with glowing LEDs recovery.

If someone flashed the cwm-recovery.lok, now you need to shut down your device, then volume UP + home + power until you get into recovery. Let us know if CWM shows up, and if your device was factory resetted.
[LG Optimus G Pro] Gotroot:
Just done this and I am in CWM 6.0.3.3 what all needs to be dumped ?
[LG Optimus G Pro] autoprime:
there are more variants... I put this together awhile ago.. there may even be more since then..

the original optimus g had around 20 varients... not all named "optimus g" but indeed the same phone... the pro is the same..

E980 - 2G: 850/900/1800/1900MHz 3G: 850/1900/2100MHz 4G: 700/1700MHz
North America
AT&T
Snapdragon 600 MDM9615/APQ8064T 1.7GHz

L-04E - 2G: 850/900/1800/1900MHz 3G: 850/1700/1900/2100MHz 4G: 850MHz
Asia
NTT Docomo
Snapdragon S4 Pro MDM9615/APQ8064 1.7GHz

L-05E - 2G: 850/900/1800/1900MHz 3G: 850/1700/1900/2100MHz 4G: 850MHz
Asia
NTT Docomo
Snapdragon 600 MDM9615/APQ8064T 1.7GHz

F220K - 2G: 850/900/1800/1900MHz 3G: 850/1700/1900/2100MHz 4G: 900/1800MHz
Asia
KT
Snapdragon 600 MDM9615/APQ8064T 1.7GHz // Optimus GK 5"

F240K - 2G: 900/1800/1900MHz 3G: 2100MHz 4G: 900/1800MHz
Asia
KT
Snapdragon 600 MDM9615/APQ8064T 1.7GHz

F240L - 2G: 900/1800/1900MHz 3G: 2100MHz EVDO: 1700MHz 4G: 850/2100MHz
Asia
LG U+
Snapdragon 600 MDM9615/APQ8064T 1.7GHz

F240S - 2G: 900/1800/1900MHz 3G: 2100MHz 4G: 850/1800MHz
Asia
SK TELECOM
Snapdragon 600 MDM9615/APQ8064T 1.7GHz
[LG Optimus G Pro] Gotroot:
I need a recovery driver for windows alls that is showing up in CWM when connted to usb is geefhd.. And I tried the lg driver pack
[LG Optimus G Pro] mrfeuss:
See below-geefhd is our device's codename.
[LG Optimus G Pro] Gotroot:
yes but can someone a driver for cwm so I can pull the misc folder+

BTW it did not rest my phone to factory
[LG Optimus G Pro] madmack:
Can you reboot and see if it factory resets your device? If not, then we might not even need that misc partition.
[LG Optimus G Pro] Gotroot:
no it did not reset the phone at all... but I did try to install a zip and it gave me this error

E:unknown volume for path [/sdcard/clockworkmod/.recovery_version
[LG Optimus G Pro] madmack:
This has nothing to do with the bootloader. We'll fix the recovery later. You should not attempt to flash or wipe anything with it. It is a test recovery and all we want to do is make sure that it boots.

I think Dan successfully ported Loki to our device ladies and gents. :good::good::good:

I wanna try flashing a recovery that wasn't patched with loki and see if our device boots it?

---------- Post added at 03:49 PM ---------- Previous post was at 03:45 PM ----------

@shabbypenguin, do you have the recovery image sans loki ?
[LG Optimus G Pro] Gotroot:
Well im here to help if anyone has anything to test let me know

BTW would like to clam the fist with loki cwm HAHAHA lol
[LG Optimus G Pro] shabbypenguin:
www.shabbypenguin.com/OUDstuff/LG/ATT/geefhd/recovery.img here is nonloki'd

glad to hear its working i passed the info onto the motion testers

and yea it was more of lets see if this works, i can fixed up sdcard's later
[LG Optimus G Pro] Gotroot:
Oh its np if I can help buy testing np.... When all said in done I will start helping port Been eye balling beanstalk lol
[LG Optimus G Pro] turilo:
Glad to see you here also m8 you did some serious work on the ATT note 2 :D
[LG Optimus G Pro] sabre31:
Agreed I am glad madmack is here. Hopefully he can port cm10.1 for us like he did for note 2 to this phone. Glad to see devs coming on board for this phone we need it.
[LG Optimus G Pro] madmack:
aaaand it doesn't boot. I actually locked myself out.. silly me.

As soon as I press the power button, I get "Secure booting Error! Cause: boot certification verify".

Time to download mode and factory reset. :crying:

Dan, thank you for this. You literally got us loki unlock in less than an hour. Madness. I'll be sending some donation your way in any case.
[LG Optimus G Pro] shabbypenguin:
www.shabbypenguin.com/OUDstuff/LG/ATT/geefhd/geefhd-CWM-Test-2.lok

here is a version with teh sdcard enabled (internal and external)

ok so ill remove that link just so no one else tries it confused about which one :)
[LG Optimus G Pro] 1Zero3forlife:
Wow, this moved fast.

Yes, they hang low
[LG Optimus G Pro] Gotroot:
Yes internal and external show up in CWM now
[LG Optimus G Pro] shabbypenguin:
you test backing up and flashing anything? :P
[LG Optimus G Pro] djrbliss:
The Optimus G Pro is now officially supported by Loki. Please use the following thread for all questions and support requests:

http://xdaforums.com/showthread.php?t=2358871
[LG Optimus G Pro] Gotroot:
No but I will rightnow
[LG Optimus G Pro] turilo:
hows it all working out so far? I still can't believe how fast this all hit over, purely awesome! guess thats what happens when you get some serious brains all in one place :laugh::victory:
[LG Optimus G Pro] Gotroot:
I was able to backup and restore ... But external doesn't mount ... soon as it reboots I will test flashing something...but that's all I got so far

---------- Post added at 06:06 PM ---------- Previous post was at 05:55 PM ----------

When I get home I will try flashing the deox from I made
[LG Optimus G Pro] turilo:
Excellent keep us updated, i'd hit the thanks button but seems i used all my 8 up rather quickly :laugh::good:
[LG Optimus G Pro] Gotroot:
Do I need to patch my deox rom with loki tool sense it a factory kernel and from?
[LG Optimus G Pro] thecubed:
Well, it sure looks like my thunder has been stolen ;)

I'll patch up a properly working CWM, and I'll remove 'wallpaper' from the boot.img here shortly.

That is, if I don't get beaten to it first too...
[LG Optimus G Pro] shabbypenguin:
cwm is all you man, trying to get oudhs recovery working :)

on exit it runs a auto loki script that takes the currently flashed boot.img, loki patches it and then flashes it on the fly. so you are sure to never have issues flashing a kernel (with regards to loki).
[LG Optimus G Pro] apascual89:
No bro keep it up! Now we can look at bringing cm to it!
[LG Optimus G Pro] Gotroot:
I for one am thankful for ur work.. hell hang around le ts makes some awesome roms
[LG Optimus G Pro] thecubed:
Alright, I'll get CWM all patched up with the postrecoveryboot.sh script for fixing MISC if you enter recovery with the key combo.

My device tree should have enough you need to build any recovery too.

I think now that djrbliss has the offsets figured out, I think I'm also going to port Moboot to this phone, so we don't have do deal with Loki images besides the second bootloader.

I'd call that an 'unlock'.

We also still have other avenues to actually get this phone unlocked too, since Loki qualifies as a workaround (don't get me wrong, it's still awesome!)
[LG Optimus G Pro] Gotroot:
Awesome .... about home so I can test my deox
[LG Optimus G Pro] buff31:
Still LUV your dedication and follow through. It is developers like you that keep us uneducated masses informed... Thanks 'Cubed'
[LG Optimus G Pro] apascual89:
What's needed in your device tree to build cm?
[LG Optimus G Pro] Gotroot:
Ok just got home where can I help?

Whats the mounting points for

/system

/data

/cache

I know that recovery is mmcblk0p28
[LG Optimus G Pro] martinezma99:
Will the new ATT "Value Pack" upgrade change anything? I don't want to do the software upgrade if it will cause problems.
[LG Optimus G Pro] shabbypenguin:
/boot emmc /dev/block/platform/msm_sdcc.1/by-name/boot
/recovery emmc /dev/block/platform/msm_sdcc.1/by-name/recovery
/system ext4 /dev/block/platform/msm_sdcc.1/by-name/system
/data ext4 /dev/block/platform/msm_sdcc.1/by-name/userdata length=-16384
/cache ext4 /dev/block/platform/msm_sdcc.1/by-name/cache

there are your mount points
[LG Optimus G Pro] Gotroot:
Guess I asked the wrong question lol

<mount>run_program("/sbin/mount", "/dev/block/mmcblk0p15", "/system");</mount>

<mount>run_program("/sbin/mount", "/dev/block/mmcblk0p17", "/data");</mount>

<mount>run_program("/sbin/mount", "/dev/block/mmcblk0p16", "/cache");</mount>

<umount>run_program("/sbin/umount", "/system");</umount>

<umount>run_program("/sbin/umount", "/data");</umount>

<umount>run_program("/sbin/umount", "/cache");</umount>

would that be right for edify ?
[LG Optimus G Pro] thecubed:
Nooooo please do not use mmcblk0X numbers... use the /dev/block/platform/msm_sdcc.1/by-name/[partitionname] schema!

If you don't... bad things will happen. Just trust me. (You'll make my life hell when I try to port moboot to the phone)
[LG Optimus G Pro] 1Zero3forlife:
No, It should not

Yes, they hang low
[LG Optimus G Pro] Gotroot:
Well the problem that im having when I try to flash this deox is that it says I need to update to edify... so im kinda lost here is my updater.script from the kitchen
[LG Optimus G Pro] shabbypenguin:
your issue is you are relying on a kitchen, when something breaks you dont know what went wrong :/

that isnt edify thats your problem
[LG Optimus G Pro] Gotroot:
just notice lol im going threw it now

have to forgive me I haven't been in this hell sense I was helping nfsfan with htc touch 6900 but that a whole other ball game
[LG Optimus G Pro] 1Zero3forlife:
Should I root my phone with the current CWM or wait for something to unfold. I am leaving on vacation soon and want to get tethering working so I don't lose my unlimited plan.

Thanks

Yes, they hang low
[LG Optimus G Pro] apascual89:
Stock Recovery?

How could I restore the stock recovery on the phone?
[LG Optimus G Pro] Gotroot:
http://xdaforums.com/showthread.php?t=2272177
[LG Optimus G Pro] Gotroot:
Fyi if your unlocked with loki you can use quick reboot to boot into recovery... just tested it works great
[LG Optimus G Pro] apascual89:
Reboot to Recovery

Ok, I flashed the recovery in this post using the dd method http://xdaforums.com/showpost.php?p=43460298&postcount=208

The value pack was trying to download on my phone and instead of cancel, I pressed install. Now the phone only boots into that recovery. I have everything from the op downloaded, but instead of download mode it only boots into the recovery, any ideas?

When it boots up, It says the following for a couple of seconds:

Secure booting error
Cause: Device Unlock, so boot success!!

I posted this in the other thread about fixing soft bricks.....
[LG Optimus G Pro] Gotroot:
Dang did you use the tot to go back to factory?
[LG Optimus G Pro] apascual89:
No man it doesn't get into download mode, if I plug in the usb and hold volume down, it just boots back into recovery
[LG Optimus G Pro] Gotroot:
Any time I wanted downloader mode I had to hold both vol up and down and power. And when I see the lg logo I let go of power.. when the lg logo pops back up I would tap the power again
[LG Optimus G Pro] apascual89:
It boots right into recovery
[LG Optimus G Pro] Gotroot:
**** wish I knew how to make a cwm rom from that tot for you...

Wonder if that update had something in it
[LG Optimus G Pro] apascual89:
At least I have another phone. I can wait to fix! Thanks for your replies.
[LG Optimus G Pro] thecubed:
The reason for this is your MISC now has a flag set to only boot to recovery.

If you can still get to CWM, I can fix. Hit me up on IRC and let's talk.

Also, I'm about to post my flashable and bootable CWM image.. look for it shortly!
[LG Optimus G Pro] Gotroot:
Weird I just tries to get to downloader mode and can't ether... I did find to get to cwm all I have to do is hold vol up and power until I was in cwm... I will keep playing with this... I could zip up a nand backup for you if that would help
[LG Optimus G Pro] acejoker25000:
Anybody else have success getting into cwm or with dd,?
[LG Optimus G Pro] Gotroot:
Getting to cwm is not a problem ..
[LG Optimus G Pro] apascual89:
Thanks man, just logged in to irc

---------- Post added at 11:16 PM ---------- Previous post was at 11:15 PM ----------

Yes, I can't get out of cwm, LOL

---------- Post added at 11:17 PM ---------- Previous post was at 11:16 PM ----------

thanks, but I have a backup, it just doesn't boot it?