[Q] Insecure ADB - HTC Flyer, EVO View 4G

Is anyone aware of a ROM, or even a basic mod/patch that enables an insecure boot? I'd like 'adb remount' back

You have to install a rom that has it edited/enabled.

Right
Yes, I understand that -- Though strictly speaking no, you can just replace the right bits yourself to allow it. Regardless, that's why I asked - I am not seeing a ROM with it, but there aren't exactly a ton of ROMs for this one just yet...

That's a surprise since most of the roms in the dev section are created using dsixdas kitchen and part of the rooting process in the kitchen involves editing the boot.img for exactly what you are asking for.
Regardless, it's better to have the rom have the boot unsecure then to replace the bits. At least with the edited boot it will always be unsecure even after a reboot.

Related

Imaging tools

Where are all the tools for the vibrant kernels, for mt3g it was easy to build kernels, mkbootimg, then sign and flash.
For acer liquid I needed an adjustment for the mkbootimg source, since they used different offsets, then could flash boot.img via fastboot, good enough (never built kernel, just lulled boot.img, unpacked, added superuser, su, then repacked to have root on new rom)
Ok, fast forward, for Samsung Vibrant, I see people build kernels, but google finds nothing about modules outside kernel tree, mkbootimg/signing/*
Where is the stuff, I hope for user error, but can't find where I went wrong in search.
Sent from my Vibrant.
morfic said:
Where are all the tools for the vibrant kernels, for mt3g it was easy to build kernels, mkbootimg, then sign and flash.
For acer liquid I needed an adjustment for the mkbootimg source, since they used different offsets, then could flash boot.img via fastboot, good enough (never built kernel, just lulled boot.img, unpacked, added superuser, su, then repacked to have root on new rom)
Ok, fast forward, for Samsung Vibrant, I see people build kernels, but google finds nothing about modules outside kernel tree, mkbootimg/signing/*
Where is the stuff, I hope for user error, but can't find where I went wrong in search.
Sent from my Vibrant.
Click to expand...
Click to collapse
We are waiting for Samsung to release an OTA update that updates the kernel. That way we can see how they replace a kernel w/o using ODIN, and we can do the same (we all hate ODIN lol). Pretty much, we dont know how to do it yet.
There is an Update Agent on the original Galaxy S http://forum.xda-developers.com/showthread.php?t=765724 so that might be the engine behind the OTA update.
I will see if it is avail on the Vibrant.
EDIT: The same is available on the Vibrant, at least this part looks the same LOL
Moved to Q&A.

[Q] How do I build and deploy my own kernel?

I'm sure this has been covered before, but I can't get any answers. (When I search, I keep finding threads asking the same question and being told to search...)
I know I've seen a thread somewhere with some info. If anybody knows where this is and can post a link...
I've downloaded the kernel source for 2.1 from samsung and have been able to compile it. I took a voodoo kernel zip and unzipped it - replaced zImage with mine, and zipped it back up. When I use clockwork to flash the zip file, it goes into a reboot cycle. I figure this should work since the kernel versions are the same and my kernel should just use the existing modules, (in the same way it appears the voodoo kernel does).
I'm guessing I'm packaging it wrong, but I'd like to see a whole build procedure to make sure I didn't miss anything.
EDIT: Also, I'm running Ubuntu and its getting annoying to boot back and forth between Linux/Windows to use ODIN. Are there better ways to test kernels?
Thanks in advance.
Did you add the ramdisk? I use odin in virtualbox under ubuntu. There's a thread in the i9000 development forum that explains how to do it.
The ramdisk is finicky as hell. It's much simpler to start from a known good one. The voodoo project has one posted. You can also extract one from a working kernel.
Damn that ramdisk. It seems that only one way of adding it to the kernel works. I could never get the gzipped cpio file to go into the kernel. Have to ungzip/cpio and create the stupid list. But thats probably your issue.
http://forum.xda-developers.com/showthread.php?t=697938
This should have all the info you need to get started, need further help or clarification, can ask a dev. or do a google search
Thanks guys for the quick responses. I'm going to try and pack intramfs with my kernel and try again. I'll let you know how it goes.
A friend of mine found this link as well - I'll be trying to use that as well.
forum.xda-developers.[com]/showthread.php?t=777380
Why Samsung chose to write a Linux ROM flasher in Windows boggles my mind. It won't even run under WINE. What were they thinking?
dattaway said:
Why Samsung chose to write a Linux ROM flasher in Windows boggles my mind. It won't even run under WINE. What were they thinking?
Click to expand...
Click to collapse
They were probably thinking that most people run Windows...which would be a safe assumption.

[Q] first android first root, some questions

so i have the i777 and i rooted using a guide on the android central forum
basically i downloaded kies, odin, cwm, and superoneclick
i put the cwm.tar file through odin, and than ran superoneclick, and i was rooted pretty easily
i than downloaded rom manager and through there i flashed CWM. I tried to make a back up using rom manager but that failed, no biggie i hear other people have the same problem. I boot up into CWM using rom manager and it says stuff like "failed to verify whole file signature"
im not sure if this means i rooted incorrectly?
i made a back up just fine using CWM. However i found out this stuff about flash increments and how i flashed a custom CWM kernal or something (sorry my definitions in this subject are still noob)
i decided i want to get rid of the yellow triangle + i9100 message every boot, no biggie but i am here to learn and i figure might as well if i can. I read a couple threads here and im not sure if this is my answer but i think it is please advise
my plan is to go back completely as if i never rooted and than root by using a stock rom/kernal so i dont get the error triangle message as well as the incorrect international i9100 display
i think this is my solution
"2b.) How to root by flashing Entropy512's Return/Unbrick to Stock, Kernel + Rooted System Package from the command line using Heimdall (Linux and Mac OS)
* Tested on Linux, should work on Mac OS
* Download and install the latest version of Heimdall Command Line for your operating system from here. (Latest version 1.3.1 at this writing.)
* Download Entropy512's Return/Unbrick to Stock, Kernel + Rooted System Package from here. Extract the PDA.tar file from this package to a directory on your hard disk drive, then extract the two component files from the tar - zImage and factoryfs.img.
* Place zImage and factoryfs.img both in the directory where you have the Heimdall command line executable, and enter the following at the command prompt:
Code:
heimdall flash --kernel zImage --factoryfs factoryfs.img
* Reboot the phone. Success. You're Rooted.
"
i am under the impression that if i flash the .tar file that is 200+mb (why so big) that i will be RE ROOTED and COMPLETELY stock, therefore no error message and no international thing popping up
also, no more flash counter increments ? << this one is also important as this is one major reason i want to re root
im not really sure but i think that by flashing this new .tar it will over ride my custom.tar file that i do not want any more, i dont know how to get rid of it so this is the only thing i can think of
im worried because i dont know if i have to UNROOT before i install entropys thing or if it will just over ride
thanks so much to any one who can give me advice
Really the best instructions are in creepncrawly's write up on how to return to stock. It covers any question you could have:
http://forum.xda-developers.com/showthread.php?t=1313659
And for doing it right:
http://forum.xda-developers.com/showthread.php?t=1311081
Plus new tools:
http://forum.xda-developers.com/showthread.php?t=1367319
The write ups he does are top notch and should be mandatory reading for first time visitors.
The file is so big because it contains the entire android os.
The issues you're having in cwm sound like clockworkmod needs to be reflashed.
The triangle will be removed simply by the stock kernel being replaced. The flash counter as of now can only be reset by a usb jig ~ less than $10.
Though a few have reported returning the phone for warranty issues and they did not check the flash counter.
The only way the flash counter is tripped is by using pc Odin to flash a non stock kernel.
Sent from my páhhōniē
ok thanks for the help, tomorow im gona read the links you posted thoroughly but i was wondering
if i flash a stock kernal, than how am i rooted
i am not even really sure what "roots" my phone but i thought that it was installing CWM because its a recovery tool which allows more options "superuser"
thanks again! cant wait to waste all day tom reading more about rooting
DroidBehavior said:
ok thanks for the help, tomorow im gona read the links you posted thoroughly but i was wondering
if i flash a stock kernal, than how am i rooted
i am not even really sure what "roots" my phone but i thought that it was installing CWM because its a recovery tool which allows more options "superuser"
thanks again! cant wait to waste all day tom reading more about rooting
Click to expand...
Click to collapse
There's a stock plus root package. One of the best ways to root in my opinion.
Root means installing SuperUser.apk, su, and busybox. That's it. The stock + root package has those already included, but also gives you the bone stock kernel.
You install a custom kernel to, among other things, get ClockworkMod Recovery.
DroidBehavior said:
ok thanks for the help, tomorow im gona read the links you posted thoroughly but i was wondering
if i flash a stock kernal, than how am i rooted
i am not even really sure what "roots" my phone but i thought that it was installing CWM because its a recovery tool which allows more options "superuser"
thanks again! cant wait to waste all day tom reading more about rooting
Click to expand...
Click to collapse
in reality, 'rooting' your phone is nothing more than placing 2 files on the /system (only one is really needed, since you can download Superuser from the market)
what happens is this:
android version release (say 2.3.5)
extremely smart people find way to exploit a memory hole in the OS, and create a 'rooting' method. what this method does is exploit that hole, which allows for a 'temp root' while it injects the needed files for root
needed files for root:
/system/bin/su <- this is the binary that allows you to retain root access
/system/app/Superuser.apk
without root access, /system is a read-only partition. utilizing the exploit, it will create temp root, then remount the /system partition as read/write, allowing your rooting tool to inject the required files into /system
rooting actually has nothing to do with the device at a true hardware level. it is all within the OS itself. anything outside the OS (recovery, boot, bootloaders, etc) dont get 'rooted' because root is only access to the /system within the OS
samsungs have this awesome ability to be easily rooted via CWM. its extremely easy with ODIN or heimdall to flash recovery/new kernel with recovery built in, and use a cwm zip file to inject the needed files into /system rather than relying on an exploit to do it for you.
its a common misconception that i hate to see when people associate rooting with access to anything outside the OS itself.
'i am having problems flashing this rom/kernel/mod in cwm'
'are you sure you are rooted? try re-rooting'
asinine logic...to say the least
^^
That needs to be stickied in every android forum on xda.
Sent from my páhhōniē
ok im back, i read a lot of the guides n a lot of pages and i successfully rooted using entropys 2a method return to stock + root
now i have a 2-3 second delay in my home button, and an additional 1 second delay when i turn my phone ion with the power button to show my display
i also added CWM by using the android terminal and that worked
but im regretting all this because of the delay, my error message is gone so thats good but now i have a delay
what could be the problem? i dont remember any one mentioning this issue and if im the only one than i dont know what to do, also i noticed the flash counter is still at 1 so i know i did everything right
DroidBehavior said:
ok im back, i read a lot of the guides n a lot of pages and i successfully rooted using entropys 2a method return to stock + root
now i have a 2-3 second delay in my home button, and an additional 1 second delay when i turn my phone ion with the power button to show my display
i also added CWM by using the android terminal and that worked
but im regretting all this because of the delay, my error message is gone so thats good but now i have a delay
what could be the problem? i dont remember any one mentioning this issue and if im the only one than i dont know what to do, also i noticed the flash counter is still at 1 so i know i did everything right
Click to expand...
Click to collapse
Sounds like you still have reading to do. And kudos to you for taking what they said as constructive criticism.
The flash counter can only be reset by a usb jig. Mobile Tech videos make some very good quality ones.
The delay from the home button is due to the vlingo app shortcut being tied to the home button (double tap home button) so it's waiting to see if you hit it twice before it takes you to the home screen. Cusom roms remove the vlingo app from being there which helps cut down on the delay.
But you may notice it more since what you did. And you should. By adding cwm you likely flashed Entropy512's kernel. Which is an awesome kernel. One of the ways that kernel helps battery life is by setting the cpu govener to conservative. It slows the cpu from jumping too high too quick. That explains why you may have not noticed the delay before you did anything. As well as the delay from unlocking the phone.
For me the extra battery life is worth it. If you don't like the delay one of the easier ways to set it back to ondemand (stock) is to use the app SetCpu:
https://market.android.com/details?id=com.mhuang.overclocking&hl=en
Hope that explains everything.
Sent from my páhhōniē
yeah that makes perfect sense thanks for the explanation
right now i installed miui and i ****ing love it! the interface is so smooth and sexy its like iphone spliced with android
minimalistic ftw
the interface was so much smoother i ran quadrant but the score was the same heh, but still its impressively smooth

[Kernel Discussion] root without recompiling the kernel

NOTE: This thread is for the discussion of kernel development. If you don't recompile kernels, please don't post/reply.
After a couple years playing with nexus devices, I'm coming back over to Samsung (until I get bored) and I'm seeing that no one has managed to root a Note 5 device without a recompiled kernel. Why? Because using the stock kernel seems to result in just boot loops.
From what I've been able to observe, the custom kernels all have one thing in common in regards to allowing root to work: They are all changing sepolicy to run permissive instead of making modifications to allow 'su' to work in enforcing mode.
Why?
I have to be honest in saying that I haven't studied how @Chainfire had managed to get su working on the nexus devices while retaining sepolicy in enforcing mode, but it seems that this would be a far better solution than just neutering sepolicy all together.
Has anyone yet attempting to get a sepolicy enforcing kernel working with root? If so, are you willing to share what you tried and how things worked out?
My end-goal is probably to throw together a "as stock as possible" kernel that's root-able. If at all possible, I'm hoping that just some modifications to the ramdisk would be enough to get things working. However, I'd like to take advantage of any previous work done (if any) to get this working.
Thanks
Gary
Edit:
FOR CLARIFICATION. THIS THREAD IS NOT FOR GENERAL USER DISCUSSION. THIS IS FOR DEVELOPERS TO DISCUSS SELINUX, THE NOTE 5 KERNEL, AND METHODS BY WHICH ROOT CAN BE ACHIEVED WITHOUT CHANGING SELINUX TO PERMISSIVE.
Reminder,
Read the OP and stay on topic.
Thanks.
The_Merovingian
Forum Moderator
I have to ask my friend. Since I'm back to Samsung at the same time as you it seems. I see very little advantage of running root atm but I see none of running Selinux non permissive. Also these devices being exynos you will not find much support for it.
I may be wrong but Selinux non permissive has been a problem on samsung custom roms from day one guys just disabled it and be done with I've never seen anyone complain ;p
DAGr8 said:
I have to ask my friend. Since I'm back to Samsung at the same time as you it seems. I see very little advantage of running root atm but I see none of running Selinux non permissive. Also these devices being exynos you will not find much support for it.
I may be wrong but Selinux non permissive has been a problem on samsung custom roms from day one guys just disabled it and be done with I've never seen anyone complain ;p
Click to expand...
Click to collapse
I'm in the process of trying to modify the sepolicy in the stock boot image ramdisk to see if that allows root to work with the stock kernel (modified ramdisk.)
Wish me luck.
Dammit - all of my tools are out of date. Have to recompile mkbootimg, unpackbootimg, etc.
Okay, so I'm finding out all kinds of Fun Things that Samsung has done with this device...
First, at least some versions of this phone (mine is a 920i) have something in the stock firmware kernel(?) that restores factory recovery on first boot. This is my first sammy device in several years, but I seem to remember reading that other samsung devices have done this as well. (This is the reason that people are having to not allow ODIN to auto-reboot the phone.)
What's really pissing me off, however, is that if I allow TWRP to modify the system partition (based on the prompt on the initial boot) and don't actually make any system changes, the normal stock kernel won't boot... it gets stuck in a boot loop. (pre-bootanimation)
This is similar to the reports people are having of boot loops if they install root without changing the kernel. I'm starting to think it has nothing to do with actually being rooted, but that ANY system partition change is causing the bootloop. (Surprise!)
So, I decided to try something a bit different: I restored stock firmware (tar.md5 via odin) and after the reboot, I went back into ODIN mode. This time, I flashed TWRP and rebooted immediately back into ODIN and a flashed kernel with a modified sepolicy in the ramdisk. I then booted normally. My kernel loaded. I used adb to reboot to recovery. TWRP loaded. From TWRP, reboot normally.. it worked. Good start. adb reboot recovery, and this time I uncheck the option to "only mount system R/O." (It's in the "mount" section of TWRP.) Reboot system... and... BOOTLOOP.
(This has nothing to do with root. I'm not installing root... )
Time to start digging in the kernel ramdisk to try and figure this one out...
Tried the same as above, but with Philz compiled by @arter97. This time, I was stuck in a bootloop after the first time recovery ran. I'm guessing that this particular recovery will ALWAYS touch the system partition without first asking? Not sure... Philz did ask if I wanted to install root when I chose the option to reboot, but I declined.
Note to self:
http://forum.xda-developers.com/showpost.php?p=61542104&postcount=433
Just remove support_scfs,verify from the fstab and altering system will work.
Click to expand...
Click to collapse
I have NFC what "support_scfs" is, but I'll have to spend some time with google to figure it out. Perhaps a bit of SourceDiving. Won't have a chance to test this until tomorrow evening.
I love replying to myself. The truth is, I'm probably one of the few people who could stand talking to me. Of course, even I feel like killing me every now and then. It gets complicated.
Oh.. anyway.. I got it. A stock kernel with a modified ramdisk running selinux in enforcing mode and root-able. I want to spend a day running tests, but will post results of the results in about 20 hours. (assuming I get to sleep tonight...)
As well as gaining the enforcing selinux security (somewhat degraded by being rootable), this also ensures all hardware is working even if samsung "cheats" in posting source code.
(see attached screenshot... it's really the stock kernel and still enforcing SE for Android. )
Edit:
Then again, there's no harm in posting the boot image now. This is from a n920i device using the N920IDVU1AOH6 firmware. I'm attaching a file that can be unzipped and flashed with ODIN (AP slot.) Someone fluent should be able to pull the boot image out of the tarball and flash it directly with TWRP or even via 'dd' (assuming you're already rooted.)
(If you try to flash the .zip file directly, you deserve whatever horrible things happen to your phone.)
THIS IS NOT A RELEASE. THIS IS FOR DEVELOPERS WHO KNOW WHAT THEY ARE DOING TO FIND FLAWS WITH IN REGARDS TO ROOT AND SELINUX. I can't claim this would work for any device without the above mentioned firmware. If you don't know exactly how to recover from Bad Things, don't even download the attachment.
No support. No help. If you have to ask how to flash this or anything of the sort, this isn't for you.
Changes from stock ramdisk:
1. Modify sepolicy as @Chainfire documented (ironically using an unrooted note 5) to allow supersu to work it's magic.
2. Modify fstab to remove support_scfs,verify from the mount options for the system partition. (this solves the boot loops)
That's IT.
One warning, though: This is using supersu beta 2.51. That's not released. Actually, I think it's flagged as a work in progress.
garyd9 said:
Changes from stock ramdisk:
1. Modify sepolicy as @Chainfire documented (ironically using an unrooted note 5) to allow supersu to work it's magic.
2. Modify fstab to remove support_scfs,verify from the mount options for the system partition. (this solves the boot loops)
That's IT.
One warning, though: This is using supersu beta 2.51. That's not released. Actually, I think it's flagged as a work in progress.
Click to expand...
Click to collapse
Please, publish original boot.img from N920IDVU1AOH6
svadev said:
Please, publish original boot.img from N920IDVU1AOH6
Click to expand...
Click to collapse
Did you not bother to read any of the posts in this thread? There are known locations for stock images. This thread isn't one of them.
Read the very first line in the first post.
I made it for my SM-N9208, and it is really works with supersu 2.50 .
Thanks!
garyd9 said:
Changes from stock ramdisk:
1. Modify sepolicy as @Chainfire documented (ironically using an unrooted note 5) to allow supersu to work it's magic.
2. Modify fstab to remove support_scfs,verify from the mount options for the system partition. (this solves the boot loops)
That's IT.
One warning, though: This is using supersu beta 2.51. That's not released. Actually, I think it's flagged as a work in progress.
Click to expand...
Click to collapse
Hi
Could you please post a more detailed guide ? I want to do it myself for my n920c.
Thanks
geek78 said:
Could you please post a more detailed guide ? I want to do it myself for my n920c.
Click to expand...
Click to collapse
yeah. well, at least assuming you know how to unpack and repack boot images... (Because this stuff is very experimental at this point, and still very much a work in progress, you should have a certain level of proficiency before mucking with it. I can't and won't hold anyone's hand for this stuff at this point.)
you need to unpack the boot image. Get the boot.img and unpack. Open the ramdisk. In the ramdisk is a file called 'sepolicy.'
Start with this post to figure out how to change it:
http://forum.xda-developers.com/showpost.php?p=63190351&postcount=2071
Find the reply to that post from Chainfire to see how it can be done without a "reference" device.
You'll also have to change the proper fstab as I documented already in this thread.
Then pack up the ramdisk and repack the boot image.
Thanks. Perfect !
DAGr8 said:
I have to ask my friend. Since I'm back to Samsung at the same time as you it seems. I see very little advantage of running root atm but I see none of running Selinux non permissive. Also these devices being exynos you will not find much support for it.
I may be wrong but Selinux non permissive has been a problem on samsung custom roms from day one guys just disabled it and be done with I've never seen anyone complain ;p
Click to expand...
Click to collapse
I'm trying to place your name. Do I know you from SGS2 days or Note2 days?
Anyway, I'm not happy with settling. Never have been...
Edit:
Note or Note 2. Must have been Note2. You were doing smali edits for enabling tablet mode. That was pre-xposed days.
Edit 2:
To answer the question: enforcing selinux adds a layer of security on the device and blocks many security infractions. Basically, if you haven't been given permission to do something, you can't do it. Even as root. In theory, selinux could block the stagefright security issues. When a device is in "permissive" mode, selinux is there, but isn't actually blocking anything. It just logs violations and then ignores them.
In other words, permissive mode completely negates having the se extensions at all. Permissive was a mode that devs could run in to see what might break and what might not.
"root" access is, of course, a hole in the scheme. Chainfire, with supersu, has done quite a bit to ensure that the hole is controlled, but it's still a hole. However, a rooted device with an enforcing selinux kernel is still significantly more secure than a non-rooted permissive selinux kernel.
Another edit:
Here's some links:
https://su.chainfire.eu/#selinux
http://linux.die.net/man/8/selinux
<sarcasm> Wow, I almost forgot how much JOY and FUN it is working with Samsung sh!t kernels. </sarcasm>
So, in testing this (yes, I really DO test things.. imagine that) I found that my device wasn't going into deep sleep. Wow. How interesting. Oh, and not a single wakelock. WTF?!
Instead of google'ing first, I reverted to being a kernel dev (that is now trying to debug a kernel that he hasn't even compiled.) The first thing a kernel dev looks at: "dmesg" So, I copy dmesg to a file and transfer it my PC. (BTW, Notepad++ is God's gift to windows editors.) I search for various strings like "error" and "fail" and "suspend." What I end up seeing is a crapload of messages like this:
Code:
[0: system_server: 3858] PM: Device 0:0:0:x failed to suspend: error -5
(replace x with 1, 2, or 3)
Huh? So, before I dive into the code (because I really don't believe that samsung actually shares the kernel code that they use for themselves), I decided to google around a bit. I finally had enough search terms to hopefully narrow down the search results.
Guess what I found? People having the exact same problem on another samsung device: the S6 (and edge.) Here's the best of the threads:
http://forum.xda-developers.com/galaxy-s6-edge/help/deep-sleep-t3079705
It gets into some interesting detail around page 4 and 5. You'll have to skip past all the clueless people preaching about turning off wifi, downloading snake oil, and worshipping recycled NiCad batteries.
To make a long story short, the stock kernel (or perhaps the bootloader? That shouldn't be possible...) marks a few block devices as read-only if you're using a modified device. (If it's rooted, it's modified. If KNOX is tripped, it's modified, etc.) The kernel from Sammy is trying to flush caches to those devices (which is ironic when you consider they are marked read-only) before going into the suspend. The flush fails, so the entire suspend process fails. It seems that on the SGS6, there were only two devices like this. On the Note5, it seems to be 3 (everything except sda)
In that thread, @HomerSp not only tracked down the problem there, but also (thankfully) figured out that writes to a file in the /sys tree could work around the issue. Thankfully, because the entire point of THIS thread is to use the stock compiled kernel (with a modified ramdisk) to make life Happy. With 3 writes to the /sys tree, magically the device goes to sleep.
(Yes, I'll be taking care of it... and documenting it better...)
What a pain... for some reason, I couldn't write to the cache_type files from within the init.rc structure. No clue why not. Ended up having to add a "service" to the init structure
Anyway...
If you're following along at home, add the following lines to the bottom of init.rc:
Code:
service fix_cache_types /system/bin/sh /sbin/fix_cache_types.sh
class core
user root
oneshot
Then add a new file in the ramdisk's sbin directory called (I bet you guessed this already): fix_cache_types.sh
That file should have perms of 0750 and contain the following:
Code:
#!/system/bin/sh
echo 'temporary none' > /sys/class/scsi_disk/0:0:0:1/cache_type
echo 'temporary none' > /sys/class/scsi_disk/0:0:0:2/cache_type
echo 'temporary none' > /sys/class/scsi_disk/0:0:0:3/cache_type
If you're using the same kernel as I am (n920i), I've attached an updated image. Same rules, conditions, instructions as the last one I posted earlier in this thread. Except this one lets the device take naps. It helps the battery life.
Tomorrow (or Sunday) I'll see if this all works with xposed or not. (I seem to remember something about xposed not working with selinux enforcing kernels, but I could be wrong.) After that, if nothing prevents it (or me), I'll repackage this stuff again, and also throw together an n920c kernel (based on N920CXXU1AOH6) for general use.
BTW, at least on my n920i, I've confirmed that I don't reboot when getting a call (or making one), that NFC works, that bluetooth works, that I can wirelessly charge and quick charge. I'm trying to ensure all the "common" complaints with non-stock boot images are non-issues before giving this out... The whole purpose of using the stock kernel is to retain enforcing selinux and retain completely functional hardware.
garyd9 said:
yeah. well, at least assuming you know how to unpack and repack boot images... (Because this stuff is very experimental at this point, and still very much a work in progress, you should have a certain level of proficiency before mucking with it. I can't and won't hold anyone's hand for this stuff at this point.)
you need to unpack the boot image. Get the boot.img and unpack. Open the ramdisk. In the ramdisk is a file called 'sepolicy.'
Start with this post to figure out how to change it:
http://forum.xda-developers.com/showpost.php?p=63190351&postcount=2071
Find the reply to that post from Chainfire to see how it can be done without a "reference" device.
You'll also have to change the proper fstab as I documented already in this thread.
Then pack up the ramdisk and repack the boot image.
Click to expand...
Click to collapse
Hi
I have unpacked my boot.img. So I can see my sepolicy file in ramdisk/, I have patched it with my rooted Nubia Z9 but I don't understand next steps. Do you have time to explain a little more ?
For the fstab mods I have done it in fstab.samsungexynos7420 and fstab.samsungexynos7420.fwup. Is it ok ?
Thanks.
garyd9 said:
No support. No help. If you have to ask how to flash this or anything of the sort, this isn't for you.
Click to expand...
Click to collapse
garyd9 said:
I can't and won't hold anyone's hand for this stuff at this point.)
Click to expand...
Click to collapse
garyd9 said:
Same rules, conditions, instructions as the last one I posted earlier in this thread.
Click to expand...
Click to collapse
geek78 said:
Do you have time to explain a little more ?
Click to expand...
Click to collapse
Need I say more?

Question Google-less Linux based Rom for this phone

Hello,
Anybody know of any good resources that can help me compile the kernel from my phone with a Linux base ROM/IMG like LineageOS or KaliNethunter? I can do the leg work, If I can find some solid documentation. The phone is rooted, bootloader unlocked, and carrier unlocked. I imagine you can compile the image, by using the Kernel from the stock image, and somehow using ADB to decompile and recompile the images?
I am new to this terminology, but not to jail breaking and rooting. The main thing is compiling systems with kernels, I've done it in Linux before, but the concept is still foreign. I'll understand more about it by the time I read a reply.
Thank you for any help or suggestions on where to start.
Edit:
Also, so long as I'm flashing images with fastboot, do I still run the risk of bricking the phone? I know there is always a risk, but it's safer than microsd updates, yes? Just keep a stock IMG file, and flash it if the kernel doesn't compile correctly?
Found this after posting https://forum.xda-developers.com/t/reference-how-to-compile-an-android-kernel.3627297/ . Going to add resources here. Multiple people have requested this, would like to get it working for everyone.

Categories

Resources