GrapheneOS for Motorola One Vision - Motorola One Vision Questions & Answers

Hello,
I want to build GrapheneOS for Motorola One Vision. I am already familiar with Java, Android Programing, C and Linux. I have never developed any ROM before that's why I would like your help. I have already setup environment with all the tools. I have downloaded GrapheneOS source code but I don't where to go from here. I would really appreciate your help. I have read few blogs and posts but they are currently not making sense to me. I already have the kernel extracted from the TWRP and Vendor Data.
Thank You

you're familiar with everything except that running grapheneos with locked bootloader is one of main purposes of this system, but yeah try to lock bootloader on this device with a custom rom installed XD

Related

D2G Security

Hello wonderful people of XDA! This is my first post, so I apologize in advance if I am asking obvious questions.
So everyone is talking about the "locked" bootloaders present on several of the new Droid phones, including my beloved new D2G. This has been cited as the reason that the bootloader, recovery menu, and android kernel on these phones cannot be replaced with unofficial code. I was wondering if anyone here knew the exact technical details of the security systems that actually make up this so called "lock".
One thread I read vaguely mentioned RSA keys, so I can only assume that something somewhere is signed. Is it the typical setup, with a bootloader that is signed with a key that is burned into the CPU, and a kernel that is signed with a key in the bootloader? Clearly the code on the /system partition is not signed, since I was able flash a custom ROM over it (not to mention install the bootstrap recovery).
Also, how much control does a root process really have? If it is possible to inject root code into the boot process just by modifying some things in init.rc (as the bootstrap recovery does), then shouldn't it be possible to manually load whatever we want into memory after that point, including a new kernel? If so, then couldn't we leave the (presumably) signed stock kernel in place, put our kernel in /system, and write some root code that copies it into memory and executes it (without checking any sigs)?
Forgive me if I have no idea what I am talking about. Like I said, I am new to the forum, and I just got my first Android phone a few months ago.
Thanks!
A guy by the name of Matthew Veety (aliasxerog on droidforums) is working on a kexec module to reboot a custom kernel after all the security checks. He has gotten it to boot, however, most of the hardware doesn't function as he needs drivers built for the new kernel. For now the project is focused on the DX, but they have mentioned the D2G as a "planned project."
More info at freemymoto.com
buryboi said:
A guy by the name of Matthew Veety (aliasxerog on droidforums) is working on a kexec module to reboot a custom kernel after all the security checks. He has gotten it to boot, however, most of the hardware doesn't function as he needs drivers built for the new kernel. For now the project is focused on the DX, but they have mentioned the D2G as a "planned project."
More info at freemymoto.com
Click to expand...
Click to collapse
Thanks for the info! I checked out that site and PMed the guy you mentioned on Droid Forums. We'll see if there is something I can do to help.
Any extra info anyone has is still appreciated!
Hi,
Punmaster did you find any more information concerning the locked bootloader. Any ideas to put another kernel?
If i understand well, the roms can only modify the application layer.
You seem to know linux dev, maybe you can help me with the usbnet problem?
Sent from my MotoA953 using XDA App

[Q] Mobile OS questions.

Hi,
I have a very basic question with regards to Android OS. Why can't we easily update the Android OS to newest version; just like we do it for say a Windows PC? I understand that there are hardware limitations for OS updates.. similar to say for example Win7 not supporting older hardware. But if want to update to the newest android version for my phone.. why are there "custom ROMs" posted in forums? What are the contents that go in these Custom ROM? I am interested in the programming part of this.
Also, second question is where do I get the say for example Jelly Bean ROM that I modify to suit for my phone?
Thanks.
--
M
PS:
Note: Please feel free to move this thread to appropriate category, if this does not belong here
MadhaviJ said:
Hi,
I have a very basic question with regards to Android OS. Why can't we easily update the Android OS to newest version; just like we do it for say a Windows PC? I understand that there are hardware limitations for OS updates.. similar to say for example Win7 not supporting older hardware. But if want to update to the newest android version for my phone.. why are there "custom ROMs" posted in forums? What are the contents that go in these Custom ROM? I am interested in the programming part of this.
Also, second question is where do I get the say for example Jelly Bean ROM that I modify to suit for my phone?
Thanks.
--
M
PS:
Note: Please feel free to move this thread to appropriate category, if this does not belong here
Click to expand...
Click to collapse
Well, it depends on a whole lot of things.
1) The bootloader on the atrix2 is locked. This means that you can not actually flash a custom kernel without using something like kexec. This also means that for ANY real android updates, that they MUST come from motorola, or at least be signed by motorola (like the leaked JB asia version we have, that will NOT run on at&t phones, without major and fairly dangerous work). And Motorola abandoned this phone after ICS for the most part.
2) You can flash any "custom" rom be it based on stock or a compiled ROM like cyanogenmod, AOKP, etc. they just can not use the kernel that comes with it, and there are some very special files and trickery to make that happen when compiling the ROM.
3) This phone is locked done at more than just the bootloader, there are other parts of the phone that they have signatures on that do not allow you to go up or down in versions of android, unless you have a special developer version, or one of the MEARET/SEARET versions of the phone, or you made that fairly dangerous mod, I mentioned before.
The Custom ROMs have some nice acceleration tweaks, UI tweaks, and removal of all the crap and bloat apps that come from most providers. These "Custom" Roms are usually all opensource, just like Linux/Android, and you have the chance to customize it even farther with some C code and Java, if you like.
Here is a link to the Cyanogenmod page, and a couple other "custom" ROM pages:
http://www.cyanogenmod.org/
http://en.miui.com/
http://aokp.co/
There are many many more ^^
Now to make a custom ROM you will need a Linux install someplace (a VM at least, but the compile may run way longer), some C++ and java knowledge (even just a small amount will help a little), be good at using google to fix your compile errors, and a whole lot of patience.
I always suggest a new person who would like to learn to dev, start easy and try their hand at a stock rom first using the kitchen it is much easier, and you can do some nice things and learn. Once you get that down, and learn the trouble shooting part of ROM building, you may try your hand at "custom" ROMs, or you can do what some have done and just jump into the "custom" ROM thing, but it is a little harder, and will take more time to get it down.
You can also do as a few other have done, and learn how to port roms from other like phones, but I never could get them to function as they should with ALL parts working, there was almost always something that did not work well enough for me to want to use a ROM I ported. Though others have had huge success with this, and you could PM them to ask their secrets.
Here is my post on where to get the tools needed to start working with your stock ROM, using the kitchen and other tools with Linux:
http://forum.xda-developers.com/showthread.php?t=1404442
jimbridgman said:
Well, it depends on a whole lot of things.
1) The bootloader on the atrix2 is locked. This means that you can not actually flash a custom kernel without using something like kexec. This also means that for ANY real android updates, that they MUST come from motorola, or at least be signed by motorola (like the leaked JB asia version we have, that will NOT run on at&t phones, without major and fairly dangerous work). And Motorola abandoned this phone after ICS for the most part.
2) You can flash any "custom" rom be it based on stock or a compiled ROM like cyanogenmod, AOKP, etc. they just can not use the kernel that comes with it, and there are some very special files and trickery to make that happen when compiling the ROM.
3) This phone is locked done at more than just the bootloader, there are other parts of the phone that they have signatures on that do not allow you to go up or down in versions of android, unless you have a special developer version, or one of the MEARET/SEARET versions of the phone, or you made that fairly dangerous mod, I mentioned before.
The Custom ROMs have some nice acceleration tweaks, UI tweaks, and removal of all the crap and bloat apps that come from most providers. These "Custom" Roms are usually all opensource, just like Linux/Android, and you have the chance to customize it even farther with some C code and Java, if you like.
Here is a link to the Cyanogenmod page, and a couple other "custom" ROM pages:
http://www.cyanogenmod.org/
http://en.miui.com/
http://aokp.co/
There are many many more ^^
Now to make a custom ROM you will need a Linux install someplace (a VM at least, but the compile may run way longer), some C++ and java knowledge (even just a small amount will help a little), be good at using google to fix your compile errors, and a whole lot of patience.
I always suggest a new person who would like to learn to dev, start easy and try their hand at a stock rom first using the kitchen it is much easier, and you can do some nice things and learn. Once you get that down, and learn the trouble shooting part of ROM building, you may try your hand at "custom" ROMs, or you can do what some have done and just jump into the "custom" ROM thing, but it is a little harder, and will take more time to get it down.
You can also do as a few other have done, and learn how to port roms from other like phones, but I never could get them to function as they should with ALL parts working, there was almost always something that did not work well enough for me to want to use a ROM I ported. Though others have had huge success with this, and you could PM them to ask their secrets.
Here is my post on where to get the tools needed to start working with your stock ROM, using the kitchen and other tools with Linux:
http://forum.xda-developers.com/showthread.php?t=1404442
Click to expand...
Click to collapse
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Thanks Jim. That was very helpful. I'm going through the links that you've provided and find them useful.
Any more questions... I'll post them in this thread.
--
M

[Completed] [Q] What is a recovery.img and what is it for?

Hey guys,
I was looking for a tutorial and a description about what is a recovery.img and if there is always the need to root any Android or Smartphone (even if it comes with Ubuntu mobile OS) to install a custom ROM.
My second question is about the Super User Apps:
I always see tutorials in which, after flashing the recovery.img they say we need to install a, i.e., CWM_SuperSU_xxx.zip. I do not know why to do that if I have my phone rooted and all I need to do is to boot it and go to the Play Store and install the latest SuperSU app by ChainFire, i.e.
All these questions have a single porpuse: To know what I am doing, because I do not like to perform tasks as an robot. I have a brain that loves to know and learn and be aware of what its doing.
Thank you very much for your help. Maybe you could point me to the documents I need to read to now all these questions.
By the way:
I rooted a year ago my HTC One-V and installed a Custom ROM before and It was working perfect until somebody stolen it from me.
My device now is a Samsung Galaxy GT-i9300. I am from PerĂº, and my Service Provider is Claro.
I use Ubuntu 14.04 and 12.04 and I have installed Heindall from the Ubuntu repositories. Until now I just read tutorials of how to root my phone, but I do not want to perform tasks without knowing what are them for.
So I want to wait before rooting my GT-i9300 until I know what I am really doing with my phone.
Thank you in advance!
Regarding Rooting, Please see [Q] What is rooting? Particularly #7
When it comes to Recovery, See XDA Wiki. Also See XDA University for Android Flashing Guide.
If your Device comes with Linux, then you should not use Android Rooting programs unless advised to do so. Weather Device Recovery works with Linux or not depends on Case by case basis.
In case of additional questions, please post in Android General
My device is a very popular one, a GS3 GT-i9300. It is an Android phone.
My PC, where I am going to connect my phone to root it that has Ubuntu Linux 14.04 and 12.04 installed.
Maybe you miss understood what I wrote.
Mauricio Mora
So if I want to use CWM Recovery, then I can look for the latest version? Or there is a special version for my phone. Afaik it is exactly like my PC when I install a dual boot with Windows. The bootloader (maybe Grub2) is like the Samnsung bootloader and Recovery and my Android are like Ubuntu and Windows dual booting. Is that right?
And hence I do not need a special CWM Recovery for my phone, it should be a simple recovery.img installer but versions differs in features and installed programs. Is that correct? And I just can look for the latest one.
Mauricio Mora
Thank you very much @Perseus71
Your links are very useful for my purpose.
Mauricio Mora
So...
In simple words, it is like my PC.
I inicially have a single OS, Android. Maybe a Recovery but installed by the manufacturer.
Then if I install a Custom Recovery, it is like creating a dual boot: Android and Recovery.
Then if I install a ROM it is like removing a Linux distribution in my PC and installing a new one.
Recovery gives me some tools like backup my personal settings and data and even my apps.
In those terms, there should be ways to install dual boot Android and Ubuntu Touch? Or which ever ROMs in dual boot?
Mauricio Mora
If you want to install CWM, please visit [RECOVERY] ClockworkMod Touch 6.0.3.2 for GT-I9300
Mind you that is for GSM Phone only.
Yes Bootloader = Grub but Linux/ubuntu do not have a concept of Recovery in traditional android sense. In that wany Grub does do the job of a recovery. You may want to google for "What is Android Recovery ?"
If you still have continued questions, please post them in Galaxy S III General forum.
The mission and purpose of XDA Assist is
The mission of XDA Assist is to provide basic help to those who have tried searching but can't find what they are looking for and need assistance. This is not a "helpdesk" providing technical assistance but more to point you in the correct direction with your problem. Perhaps you can't find posts on how to root your phone, install custom recovery or maybe you have questions about how to navigate and use features on the site.
Click to expand...
Click to collapse
Mine is GSM, @Perseus71.
Thank you very much again!
Mauricio Mora

[Completed] [Q] Several general questions about custom recovery and roms

Let me start by saying I am not completely new at this now and have unlocked, rooted, and installed some custom firmware (or is rom the preferred term?) on a few other more popular brand devices. Being as they were popular that made it super easy to find information, tutorials, and files. While I understand the basics of all the things I was doing and have learned a lot about using ADB and fastboot for instance I am still a bit lost on a couple key items.
So I recently however bought an iRulu V1 phone off of Amazon. While I was able to resolve how to root the device, which I can post about if anyone is interested, I can't seem to find enough information about custom recovery and roms. So here are some basic questions I have, which again I guess I should know since I dove in head first on my other devices, but I am still not sure when it comes to these things and really should understand them
1) Do I need a version of CWM or TWRP made for this device specifically or is there some generic that works for any device?
My device came with KitKat 4.4.2 no upgrade available form manufacturer currently to 4.4.4 or any update for Lollipop. I would love to install the latest version I can of course.
2) Similar to question #1, Is a custom rom needed to get any higher version of Android or can some generic version be installed?
3) On both question above, where does one begin to locate these generic or standard versions?
4) If there are generic versions of the recovery and/or Android rom, What are some of the caveats I might run into using them? More meaning what features might simply just not work?
5) I cannot find an image of the rom included with my phone from the manufacturer, What application or process could I use to be sure I have a complete backup I could restore should I do something stupid?
I tried an ADB backup and the image it created seemed way off in size even though I was using what I thought were proper parameters to get everything including the system.
I really have these questions as I still think of Android like one would of Linux for instance. If I have a computer Linux can run on, I can usually find a very generic ISO to get the OS installed and customize from there. I guess that is really what I am trying to do here, get as updated a version of Android as I can and then make everything work by loading modules or drivers as needed. I guess finally, Is that not really how it works with the Android OS ?
thanks so much for any answers or insight. I have thus far like many others found the info here invaluable while playing around with my various Android devices I have. I hope too that my post is falling into the proper format requested by this section, apologies if not.
LT
Hi, thank you for using XDA Assist. You're right, there is no information about your device on XDA. In general, only flash recoveries or roms that are specific to your device. There are no general ones. Flashing something that is not specific can brick your device. Your best bet is to ask specific questions about your device here, http://forum.xda-developers.com/android/help and hope someone else with your device can help.
Sorry I can't be of more help.
Thread closed.

Questions About Bootloader, Root and Roms

Looks like I'm gonna get a free P2 from my son. It maybe has 1 update left before Google abandons it. When I get it I want to root and put Lineage on it, or maybe a different rom based on opinions provided.
I have some questions:
1- I'm looking for the simplest method to unlock the bootloader and root, as I am not the most knowledgable Android/Linux user. I'm familiar with adb, although best if I can follow a written script. I would appreciate a recommendation on which method posted on XDA. I've seen Deuces and Nathanchance's methods. They seem easy enough to follow along with.
2- I'm a little confused about the Pixel factory images that folks mention in their posts. I see that Google has images catalogued on their site for downloading. How do you choose which one to flash to the phone after bootloader/root process? Does it matter? I'm located in Canada if that makes a difference.
3- I have used TWRP and never used Magisk for loading roms. I also see from one of the bootloader unlock/root methods that TWRP may not be all that reliable. Would TWRP be good enough to flash the factory image with, or should I get familiar with Magisk?
4- Am I correct in thinking that the Google image is flashed first to get the phone up and running, followed by Lineage (and gapps), or an different rom that would be flashed thereafter with TWRP/Magisk?
5- If I screw up during the unlock/root is there a recovery method available?
Thanks for any help provided.
jjcdennis said:
Looks like I'm gonna get a free P2 from my son. It maybe has 1 update left before Google abandons it. When I get it I want to root and put Lineage on it, or maybe a different rom based on opinions provided.
I have some questions:
1- I'm looking for the simplest method to unlock the bootloader and root, as I am not the most knowledgable Android/Linux user. I'm familiar with adb, although best if I can follow a written script. I would appreciate a recommendation on which method posted on XDA. I've seen Deuces and Nathanchance's methods. They seem easy enough to follow along with.
2- I'm a little confused about the Pixel factory images that folks mention in their posts. I see that Google has images catalogued on their site for downloading. How do you choose which one to flash to the phone after bootloader/root process? Does it matter? I'm located in Canada if that makes a difference.
3- I have used TWRP and never used Magisk for loading roms. I also see from one of the bootloader unlock/root methods that TWRP may not be all that reliable. Would TWRP be good enough to flash the factory image with, or should I get familiar with Magisk?
4- Am I correct in thinking that the Google image is flashed first to get the phone up and running, followed by Lineage (and gapps), or an different rom that would be flashed thereafter with TWRP/Magisk?
5- If I screw up during the unlock/root is there a recovery method available?
Thanks for any help provided.
Click to expand...
Click to collapse
Would appreciate some help...
Pixel 2 was updated to android 11, and will likely continue to to get monthly security updates until the release of android 12, so you should have about another year if staying stock.
As far as rooting, the xda guides as you mentioned are pretty straightforward and comprehensive.
Pixel factory images are the stock system images that are provided by google. They are what you would flash if you wanted to run a stock system, and also the means for 'resetting' the phone back to a factory state in the event of a screwup. On the site, you'll notice that google has each of the images organized by phone type (the Pixel 2 is walleye) and within each phone type is operating system version going from oldest at the top to newest at the bottom. Typically you'd want to flash the newest os version unless you have a special use case. There are also cases where a particular version is only for a particular carrier, in which case google will note it under the version number.
As far as flashing lineage, I'm not too sure. I run stock (rooted) on my P2, but lineage is it's own rom so would be flashed directly via twrp. I would image the lineage thread would have install instructions and q/a.
clcdev said:
Pixel 2 was updated to android 11, and will likely continue to to get monthly security updates until the release of android 12, so you should have about another year if staying stock.
As far as rooting, the xda guides as you mentioned are pretty straightforward and comprehensive.
Pixel factory images are the stock system images that are provided by google. They are what you would flash if you wanted to run a stock system, and also the means for 'resetting' the phone back to a factory state in the event of a screwup. On the site, you'll notice that google has each of the images organized by phone type (the Pixel 2 is walleye) and within each phone type is operating system version going from oldest at the top to newest at the bottom. Typically you'd want to flash the newest os version unless you have a special use case. There are also cases where a particular version is only for a particular carrier, in which case google will note it under the version number.
As far as flashing lineage, I'm not too sure. I run stock (rooted) on my P2, but lineage is it's own rom so would be flashed directly via twrp. I would image the lineage thread would have install instructions and q/a.
Click to expand...
Click to collapse
Thanks very much for the help.

Categories

Resources