Hi all,
I have gained temp root access on a japan phone, able to obtain rw access to all files & folders except /system. Edited default.prop file on ro.secure and ro.debuggable to 0 & 1, did setenforce to permissive but still unable to write on /system getting mount: permission denied, is there any advice anyone can give please?
On a seperate issue, this phone does not have fastboot or recovery mode, attempted to dd a modified boot.img to the dev/block/xxxxxxxxxx folder of where the original boot.img was resulting a bootloop, wondering under normal circumstances when there is no fastboot or recovery mode, dd a boot.img should achieve the same flash result of using fastboot?
Thanks in advance!
Related
So, I've gotten my SGS2 today and went ahead to root it. Flashed CF-Root matching my current version (KE7 PDA/KE4 baseband). I used the S2Root app posted here on the forum to get root and flashed a stock kernel back.
In either of these stages, I couldn't get ADB to run as root, needed for a modification i'm trying to do (can't write to /system/framework otherwise).
Is there a known way to get ADB to run as root?
(The issue at hand - /default.prop contains ro.secure=1 and ro.debuggable=0 - And i can't edit this file in order for it to persist after reboot)
even in CWM i can't get ADB to run as root and thus cannot copy files to /system/framework even though /system is mounted as r/w.
Thanks for the help.
ransagy said:
So, I've gotten my SGS2 today and went ahead to root it. Flashed CF-Root matching my current version (KE7 PDA/KE4 baseband). I used the S2Root app posted here on the forum to get root and flashed a stock kernel back.
In either of these stages, I couldn't get ADB to run as root, needed for a modification i'm trying to do (can't write to /system/framework otherwise).
Is there a known way to get ADB to run as root?
(The issue at hand - /default.prop contains ro.secure=1 and ro.debuggable=0 - And i can't edit this file in order for it to persist after reboot)
even in CWM i can't get ADB to run as root and thus cannot copy files to /system/framework even though /system is mounted as r/w.
Thanks for the help.
Click to expand...
Click to collapse
Try this:
adb shell mkdir /sdcard/temp/
adb push fileToPush /sdcard/temp/
adb shell
$ su
# cp /sdcard/temp/ /system/path/to/push/to/
ADB doesn't run as root, as it's not safe to, as you can bypass superuser security in a rogue app otherwise
I'll try it ASAP, Thanks.
Isn't there a way to edit /default.prop though?
I'd prefer to have adb run in root at the very least while running this mod, and then restore it.
the mod currently patches framework.jar/libwebcore.so for RTL issues, and relays on scripted access to adb and r/w access to /system.
I ended up discovering that i need a different ROM either way since stock is odexed.
I'll try making my own ROM based on stock with deodexed files and make the fix before hand.
Hello everybody,
i have gained root access to my phone via backup/restore method through adb where local.prop is stored in /data/. So when i log onto my phone with adb i have root access. I copied busybox, su and the superuser.apk to the right place and removed the local.prop file again. After a reboot I was hoping to remove some crapware off my phone but to my surprise the binaries i copied vanished from the filesystem. So the phone reverted the changes by itself. I did this process several times copying busybox and su to various places referred to by $PATH, but it´s everytime the same after i reboot. The files are gone.
After the first attempts failed i tried to make changes to my phone while logged in as root. I wanted to uninstall unnecessary packages with "pm uninstall" but that failed also. The command just responds "failed". Even when /system is mounted rw (it remounts itself to ro after a while though). I´ve also made changes to /init.rc but they are also gone after a reboot as other changes i´ve made. Basically i wasn´t able to accomplish anything with root access no matter what i did.
So what i want to know is how this black magic works andy why i cant do anything with root. I know how to achieve real root through htc dev and various other methods.
Thanks for reading!
nasenstueber said:
Hello everybody,
i have gained root access to my phone via backup/restore method through adb where local.prop is stored in /data/. So when i log onto my phone with adb i have root access. I copied busybox, su and the superuser.apk to the right place and removed the local.prop file again. After a reboot I was hoping to remove some crapware off my phone but to my surprise the binaries i copied vanished from the filesystem. So the phone reverted the changes by itself. I did this process several times copying busybox and su to various places referred to by $PATH, but it´s everytime the same after i reboot. The files are gone.
After the first attempts failed i tried to make changes to my phone while logged in as root. I wanted to uninstall unnecessary packages with "pm uninstall" but that failed also. The command just responds "failed". Even when /system is mounted rw (it remounts itself to ro after a while though). I´ve also made changes to /init.rc but they are also gone after a reboot as other changes i´ve made. Basically i wasn´t able to accomplish anything with root access no matter what i did.
So what i want to know is how this black magic works andy why i cant do anything with root. I know how to achieve real root through htc dev and various other methods.
Thanks for reading!
Click to expand...
Click to collapse
is your RECOVERY.img
and beside i dont really think your /system is fully mounted rw
mauricio.valladolid said:
is your RECOVERY.img
and beside i dont really think your /system is fully mounted rw
Click to expand...
Click to collapse
Thanks for the reply. i use mount -o remount,rw /system as mount command to get read/write permission on /system. If there is something more to do please let me know. And if the behavior i ve seen is caused by the recovery.img is there something i can do about it?
nasenstueber said:
Thanks for the reply. i use mount -o remount,rw /system as mount command to get read/write permission on /system. If there is something more to do please let me know. And if the behavior i ve seen is caused by the recovery.img is there something i can do about it?
Click to expand...
Click to collapse
why dont you just install ext4 recovery and flash supersu.zip?
I really dont get it why are you trying to do it the hard way
I want to flash my cube i7.
I achieved to set ro.secure=0 ; ro.adb.secure=0 and ro.debuggable=1 by splitting the boot image i use to boot with fastboot.
ADB allow me to enter in root mode (adb root) but when i want to mount the system in rw, permission denied.
No way neither to push a file.
I can enter in some folder, according the permissions specifics to each one of them, but since i'm a normal user, i can't write anythinx in order to push supersu.
Well, I think the cause is selinux policy preventing adb (or adbd) to gain administrator privilège.
So here the questions ?
Is there a way to mount system at boot time (what i did already with fstab) to allow me to modify it ???
Is there a way to disable selinux for just a boot ???
Can i split the file system at cold state, modify file system, and flash it again in memory with proper permission ???
Hello,
i have a Wiko PULP 3G, without a working root method.
I take a look at the Firmware files, there seems no CRC Protection. Even a Satellite Receiver or a TV Firmware have such.
I changed Text in the image with a HEX Editor(ro.sys.usb.storage.type) to get Massstorage. I flashed the modified image.
The Program just done it. Okay i have still no Massstorage. But on the Mobile i can see the build.prop has really changed
like i edit it.
I wonder if i can change Textfiles, it may possible to mount system as r/w.
Its a 1.9GB image difficult to find the Init/fstab.
Questions:
1. What do i need to modify to get mass_storage ?
2. How are the typical Textlines for a phone to make system read-only?
3. If i have write access to /system i can put a "su" file(any?) to system install SuperSU and have root?
Okay i have modified a boot.img, repack it and flashed it.
I set ro.secure=0, ro.debuggable=1 and massstorage in build.prop.
I got masstorage )))))
But how do i get the su to xbin. In the extracted Boot.img or Recovery.img there is no xbin.
Other .img files cant be xtracted.
With adb push this dont work, no permission.
Ideas?
If this is a raw system partition ext4 image, you can just mount it (with -o loop) on your Linux PC and modify the contents.
_that said:
If this is a raw system partition ext4 image, you can just mount it (with -o loop) on your Linux PC and modify the contents.
Click to expand...
Click to collapse
Thanks, but its not a raw image. I think its Android Sparse Image Format.
Linux cant mount it. Yaffey is not able to handle it.
I wonder why there i no tool where you can put a Firmware in and click on "Root it" and ready is the new one?!
Now i found tools to depack/pack the system image.
But the Phone dont boot, it starts and restart in Recovery.
If i do a root filecheck in Recovery it says 1 file added and 1 file changed - FAIL.
There must be something like a modify protection
Build.prop file accidentally got empty and haven't rebooted yet. Any ways to restore it?
Am i screwed?
You have a customer recovery? Then you can dirty flash your rom
I definitely would have done that if i did.
But TWRP was never released for my phone (poco x3 gt)
Depends the device and android version I guess...
I would do getprop and edit the output to build.prop form.
Notice to chmod the file correctly, 644 or whatever..
I think you can reboot safely because build.prop is inside super partition and therefore read-only.
of course you can download stock ROM from xiaomifirmwareupdater and extract build.prop from super.img, but it's more easy to flash super.img from fastboot.
aIecxs said:
I think you can reboot safely because build.prop is inside super partition and therefore read-only.
of course you can download stock ROM from xiaomifirmwareupdater and extract build.prop from super.img, but it's more easy to flash super.img from fastboot.
Click to expand...
Click to collapse
Nvm my phone just got an OTA update.
I just have to restore the root now
aIecxs said:
I think you can reboot safely because build.prop is inside super partition and therefore read-only.
Click to expand...
Click to collapse
And it's empty like how? Weird crap anyway... ok now, so who cares...
Idk but /system /vendor /product /system_ext /odm are ro dynamic partitions inside super partition, either OP did re-duplicate blocks with e2fsck -E unshare_blocks and disabled avb/dm-verity to allow remount rw / system_root (would break OTA), or it simply wasn't written to build.prop at all (magisk systemless overlay)? "empty" could also mean does not exist/no permissions...
https://github.com/Yuyuko1024/device_xiaomi_chopin/blob/lineage-18.1/rootdir/etc/fstab.mt6891
TWRP is available btw
https://forum.xda-developers.com/t/twrp-unofficial-3-6-0-poco-x3-gt-redmi-note-10-pro-5g.4369207