How to edit builf prop using adb - Xiaomi Redmi Note 3 Questions & Answers

I have a Redmi note 3 and I wanted to edit my build prop to enable camera api. I'm not rooted neither want to. Locked bootloader and no custom recovery.
Can someone give me detailed adb instructions to mount system as rw and edit build prop using adb
Thanks in advance

Can not be done without root or you need custom recovery!
How to Edit Build.prop Without Root using ADB in TWRP recovery
https://www.theandroidsoul.com/edit-build-prop-without-root-using-adb-in-twrp-recovery/

Actually you can.
You can boot into twrp without installing it using fastboot.
I did this ages ago on MIU to change lcd density, but I guess it should work with other ROMs.
I documented it at en.miui.com/thread-424347-1-1.HTML
EDIT: And here: https://forum.xda-developers.com/showpost.php?p=71646330&postcount=3

Related

[Q] Porting Recovery and Flash_Image missing

This doesn’t relate to the EVO LTE directly but hoping you guys can help.
Background:
I have a Tablet, that has very little Development support. There are no recoveries currently available for it. I followed a number of guides and managed to get latest version of TWRP compiled, I also followed the steps to boot the recovery image on a virtual device and so far things seem good.
Questions:
1. If the recovery I compiled doesn’t work, I am guessing that the device will still boot, so I can flash the backup image of the stock recovery , Is that correct.?
2. The TWRP recovery I compiled is 7 mb, and the Stock one is 16mb is it normal for such a size difference?
3. I attempted to flash the recovery image with the following commands from adb shell:
Su
flash_image recovery /sdcard/flex_tab/twrp/recovery.img
I am getting flash_image not found. I am guessing I need to add the Flash_image binary to the device. The little bit of searching has led me to a couple different versions and none with very current timestamps. I need one that will work on a 4.1.1 device. How would I go about getting the binary and just to double check I would copy it to /system/bin and fix permissions and owner
I tried flashing the image with fastboot as well and kept getting waiting for device, so I think something isn’t quite right with fastboot.
4. Any one familiar with porting recoveries do you have any gottcha’s that I should check before flashing, I really don’t want to brick the tablet.
Thanks,
Bump, wish I could help. I hope you got it. If not, hopefully someone who knows will see this.
Sent from my EVO 4G LTE using XDA Premium 4 mobile app

[Q] Creating a method to manually root a device

Are there any tutorials to learn creating one's own rooting method via PC?
I mean, the devs who create methods to root a device manually, where do they learn it to do it?
Hey, from what I know these are some methods that moonbutt74 told me. Be aware that I and he never got to the point of trying them.
1st you need to know if you have a locked bootloader. If yes, then I can't help you here
Method 1.
Set up your ADB shell. Once thats done run :
Code:
cat /proc/cpuinfo
Collect your processor specs and look if you can peg the device on kernel "family" source and GPU family.
Now this is where you will fake it and most likely soft brick. Do a comparison of a similar device and find out if chainfire has a cd-autoroot for the comparison device. You will need to be able to compile a working kernel for the mystery device, then you will need to break down the cf-autoroot package and modify it. It gets stranger from here. As best as I understand the layout, chainfire build a "generic" recovery / kernel for the device in question [Samsung] when the image flashes, it writes to cache and when the device reboots, it begins executing predefined instructions from cache, backs up the stock recovery, writes cf-autoroot recovery, roots the device and then reflashes the stock recovery.
Method 2.
Pull the stock recovery.img or boot.img via adb from your phone.
If you can get the boot.img or the recovery.img successfully, find out how to unpack it and ONLY CHANGE THE DEFAULT PROP ENTRY FOR
Code:
ro.secure=1
to
Code:
ro.secure=0
and the same for
Code:
ro.adb.secure=1
to
Code:
ro.adb.secure=0
Then repack the with the signature key intact. DO NOT LOOSE THE ORIGINAL STOCK IMG (srsly don't. You will end up begging in the forum for a new one). If you succeed with that and successfully write back the img without boot.img or recovery.img being broken, you can then access the device trough a unsecured recovery.img via adb and hopefully push a good su binary to system/xbin. The permission of the su binary should be set to 6754 or 6744.
Now this all depends on if you have the tools for writing to the device and find out if fastboot is accessible etc.
You are most likely going to brick of you slam head first into it. Take one step and see where it takes you and take Notes.
Method 3.
While this had been mentioned in method 2. you can build or port a custom recovery for your device. Tough I yet didn't take the time to learn how that works. Once you got the custom recovery, download supersu.zip and flash it via custom recovery.
Good luck

C6802 unlocked bootloader 14.6.a.1.236, unable to mount R/W

Hi.
I have C6802, unlocked bootloader from official sony website. then flashed TWRP 3.0.2-0 on recovery using fastboot., and install superSU v2.82. It seems the device is rooted, but I can not mount root folder or system folder as R/W. HELP PLZ.
If you are on stock rom rooted you need to disable ric, set selinux to permissive and install busybox.
To disable ric look in this thread at step 5.
https://forum.xda-developers.com/crossdevice-dev/sony/root-root-stock-firmware-modern-sony-t3558904
I found out that the disable_ric.zip file don't work on latest stock rom that injects an sh file in system folder like in older stock roms.
So you have to follow the guide in the thread I linked above.
To set selinux permissive on every boot you can edit the kernel in a hexeditor and then flash the kernel in fastboot. Or you can use the selinux changer app.
SELinuxModeChanger app: https://f-droid.org/packages/com.mrbimc.selinux/
How to automatically set selinux to permissive on boot: https://forum.xda-developers.com/xposed/how-to-set-selinux-to-permissive-boot-t3034245/page3
Setting selinux to permissive on every reboot gets old..if you get tired of doing it. You can follow the guide in the thread I linked above.
This only applies to sony stock rom. Because stock rom reverts selinux to enforced everytime the device reboots...
Any other custom rom keeps this setting so it will stay on permissive even after a reboot.
SUPERUSER said:
If you are on stock rom rooted you need to disable ric, set selinux to permissive and install busybox.
To disable ric look in this thread at step 5.
https://forum.xda-developers.com/crossdevice-dev/sony/root-root-stock-firmware-modern-sony-t3558904
I found out that the disable_ric.zip file don't work on latest stock rom that injects an sh file in system folder like in older stock roms.
So you have to follow the guide in the thread I linked above.
Click to expand...
Click to collapse
Worked. Thank you very much.
aminacc said:
Worked. Thank you very much.
Click to expand...
Click to collapse
I'm glad I could help
How did u get recovery?
aminacc said:
Hi.
I have C6802, unlocked bootloader from official sony website. then flashed TWRP 3.0.2-0 on recovery using fastboot., and install superSU v2.82. It seems the device is rooted, but I can not mount root folder or system folder as R/W. HELP PLZ.
Click to expand...
Click to collapse
Did u update bootloader or flashed to fora kernel or zu-dual recovery by Nut or something else please tell me the steps Cuz I am stuck to start revovery.
Thank you

Flash Build.prop in fastboot or using zip

Hey developers. I am currently using Moto X Force XT1580 bought in India with Android 7.0 July 1 2017 Security Patch. I extracted the build.prop file using adb but the problem is I can't push it back. I edited the build.prop to enable Camera2 Api. The issue is I don't want to unlock boot loader and root because it always shows ugly message showing unlocked bootloader in Motorola. Next to use Android Pay we need locked bootloader and to lock bootloader again I need to flash stock firmware again. This makes the editing buil.prop and pushing thing moot. . So I thought only method is via fastboot or using Zip. So help me experts because I have no idea on how to push that new build.prop. If there is way to do this without unlocking bootloader then amazing. Also if anyone can provide me Stock ROM of Android 7.0 for XT1580 Indian model.
Thanks in advance
You are stuck then. As you need root to push a file to the system partition where that file goes.
zelendel said:
You are stuck then. As you need root to push a file to the system partition where that file goes.
Click to expand...
Click to collapse
But fastboot flashing doesn't need root, or does it? Isn't there any way of flashing via fastboot or creating any zip like those OTA update zip files

Help to Root Oppo K3

What would i Do after Unlocking Bootloader?
Please provide Required file Links
Thanks in Advance
Bump :fingers-crossed:
@blanksh07
To root Android unlocking device's boot-loader is NOT needed: You always can obtain a temporary root by patching adbd.
0
The above link didn't worked for rooting.
Anyone else tell me how to root this device or how to add it to xda device list?
@blanksh07
The Oppo K3 is based on Android 9, hence I think it has dm-verity/AVB enabled by default. As long as this lock isn't got disabled NOTHING will work as expected.
@jwoegerbauer
How can I disable this and is there any twrp available for this phone so I can flash magisk..!?
blanksh07 said:
@jwoegerbauer
How can I disable this and is there any twrp available for this phone so I can flash magisk..!?
Click to expand...
Click to collapse
1.
Code:
adb devices
adb disable-verity
adb reboot
2.
I never installed TWRP nor Magisk in order to root a phone. Yes, this may in the end lead to a positive result, but is in my opinion an unnecessary overkill with regards to get installed 1 ( ONE ) binary in Android - the su binary what is ~100 KB of size.
BTW: You compile TWRP by yourself. How-to is described here.
1. I have tried above abd commands and got an erro "verity cannot be disabled/enabled - USER build".
2. When I try to reboot to bootloader, the fastboot screen flash for 2 seconds and rebooted to system , any help with that?
you can see tutorial in here.
https://www.getdroidtips.com/root-oppo-k3/
0
No luck!

Categories

Resources