yashsingh1/xdaforums huggingface dataset:
[Android Q&A, Help & Troubleshooting] xracerx123:
I need advise on the following as I am doing mobile application security and testing.

I most of the time I use Burpsuite/Magisk/Objection/Frida for testing purpose

Some of the constraints I am facing;

1) How do I set a permanent alias to the phone itself

2) How do I issue remote command like adb shell "cd /" and show the responses as successful

3) What are some of the ways to bypass root detection and ssl pinning (I already know there is Magisk Denylist - but its not effective at times)

4) I am also involved in IOS related testing and such, is there a wall to post IOS related stuff here.

While I was working on IOS, I find that apt-get command is quite useful but it is not available on android phone, I want to have a lot of useful software in the phone like nano, which I installed using magisk etc.
[Realme C2] HappyAarav:
Hi everyone, I have been experiencing lag in the game brawl stars. I would like some help what should I do. I have also made swap file from the app swap no root. Please suggest se ways. I have also installed Niagara launcher. I'm on the 2gb variant of realme c2.
[Realme C2] HappyAarav:
Please reply
[Realme C2] johnNeoREALME:
Go and restore. In mobile shot
[Android Apps and Games] Dzung Dev:
NeonArt photo editor gives you the best photo editing experience with dozens of neon effects and neon spirals. Your amazing photos will get all the attention with neon sketch art. Get ready for a new generation of photo editing experience with shiny stickers and stylish text. Editing images is easy and fun with NeonArt. Collage your beautiful photos with glow photo grid collage maker. Photo editor gives fun to your photos with gradient line art. Combine beautiful sketch art with cool drip effects. Try out stylish glowing sketches and cute stickers, then share your artwork on Instagram, Facebook, Snapchat, Twitter, VK and TikTok to get more likes :).

FEATURES :

●Neon Photo Effect: Add neon light effect around photo. Different colors to decorate photo with neon effect.

●Black and white photo editor: Make black and white photos with different filters

●Remove Background: Remove background easily with Remover Tool

●Drip Photo Effects: We have added trending drip effects to photo edits. Create amazing drip effect.

●Unlimited Stickers: Sticker Packs with different categories and higher resolutions.

●Photo Blur- DSLR Effect: Focus on the subject and create a background blur effect.

●Preset Photo Filters: Filter photos with different effects.

DOWNLOAD:

View attachment 5802981View attachment 5802983View attachment 5802985View attachment 5802987View attachment 5802989View attachment 5802991
[Android Apps and Games] yipai121:
THANK YOU
[Moto G8 Plus Questions & Answers] Rockel:
I have a rooted Moto G8 Plus with stock ROM. And today I was trying to remove Cerberus, which I had installed as an hidden system app with root.

When hidden, Cerberus is shown as an application "System Framework". But I had troubles getting it removed the normall way, so I've tried my chances with "System app remover" from the app store.

I had removed this "System Framework" app. but then after checking I noticed that it was still there in the app menu, and that it had another install size of the one I had removed. My phone was still working so no problems so far. Unless I've decided to reboot. Now it's stuck on start up. So it seems I accidentally had removed the wrong app called "System Framework", not being aware of it that there was another one of it.

Seems I'm stuck on a "Fastboot Flash Mode (Secure)" acreen now, asking to connect a USB data cable.

View attachment 5803017

Does annyone knows how to repair this and acces still acces my phone and data?

Thanks in advance!
[Moto G8 Plus Questions & Answers] alecxs:
- connect phone in fastboot mode usb to PC

- install Android Bootloader Interface drivers

- download platform-tools

- download TWRP recovery

- type in cmd.exe

fastboot devices
fastboot boot twrp-3.4.0-0-doha-mauronofrio.img

- decrypt /data (unlock pin/pattern)

- create backup of /data from menu

- install Android ADB Interface drivers

- pull all files /sdcard to PC

adb devices
adb pull -a /sdcard

- flash /system_image
[Moto G8 Plus Questions & Answers] Rockel:
Thanks!

This is for copying content from the internal memory to a PC?

Could I also repair it by reloading "System Framework" and acces the phone and my data in a normall way too?

Still have the same image somewhere on my PC that I've used to flash with while booting. Could I still do something with that?
[Moto G8 Plus Questions & Answers] alecxs:
you can try anything you want - after you saved that backup to PC
[Moto G8 Plus Questions & Answers] Rockel:
Yes, you're right with that. Maybe it's the safest step to do first.

I'm no pro with ADB etc. Just used it once in a while to root evices and needed somekind of guides then first.

But this: "adb pull -a /sdcard" is copying the internal storage to the PC? Where is it getting coppied to? I suspose somekind of default dir in C:\ or so?
[Moto G8 Plus Questions & Answers] alecxs:
right. you can specify target path as last argument. with no path given, current dir is used.

type 'adb help' for usage

device commands:
adb push <local>... <remote>
- copy files/dirs to device
adb pull [-a] <remote>... <local>
- copy files/dirs from device
(-a preserves file timestamp and mode)
[Moto G8 Plus Questions & Answers] Rockel:
I'm somehow a bit stuck.

I've managed to do the first part. Everything was still installed and the TWRP image was the same as used the first time. Still had the file of it in the Fastboot folder.

After doing the first part:

Code:

fastboot devices

fastboot boot twrp-3.4.0-0-doha-mauronofrio.img

My cmd screen shows that the file is uploaded and that that the phone is restarting. The phone actually restarts.

View attachment 5806255

And it returns to the fastboot screen of the image above.

But after that I'm stuck.

I think the seccond part is about the TWRP configuration?

But it seems I'm not able to enter TWRP.

Powering on while holding volume-up and power is not doing annything. And when selecting "recovery mode" from fastboot it's resulting in a black screen with an Android with the text "no command"

View attachment 5806257
[Moto G8 Plus Questions & Answers] alecxs:
Do you mean fastbootd from within TWRP? Or did you mean it simply returned to normal fastboot mode (fastboot boot didn't work)?
[Moto G8 Plus Questions & Answers] Rockel:
It returns to this screen when selecting "recovery mode":
[Moto G8 Plus Questions & Answers] alecxs:
I got confused with the word 'image' for 'picture' ;) please use latest platform-tools from link above. the no command screen is part of stock recovery. booting with Volume key won't work, it requires TWRP to be installed in boot.img recovery_ramdisk (you don't have)

in case fastboot boot cmd is not working, this leaves no option other than flashing TWRP into boot partition. however, this will soft-brick device until boot.img is restored. do you still have magisk patched boot.img matching current buildno?

fastboot getvar ro.build.fingerprint
[Moto G8 Plus Questions & Answers] Rockel:
Well yes, but "volume-down & power" was used to enter fastboot mode if I remember correctly. And I thought I was accesing TWRP with "volume-up & power. So when I suppose I should be able to enter TWRP this way now when everything should have been ok?

I'm still having a stock ROM on my PC, it's from this specific phone and I believe I've used it for rooting back then.

Fastboot is displaying XT2019-1, which is a common name of my backed up ROM file on the PC. So I asume it's the same. I believe I even had to use this file for the unlock proces.
[Moto G8 Plus Questions & Answers] alecxs:
wait.. you already installed TWRP before the bootloop?
[Moto G8 Plus Questions & Answers] Rockel:
Yes, I had completely rooted my phone. Unlocked bootloader, installed exactly the same TWRP version as you linked above and used it to load Magisk.

The only thing I've done so far now is accidentally removing the real "System Framework" which had started to cause this after reboot, and tried to re-load the exact same version of TWRP as you discribed above.

Still having all the files used in the booting proces. So all the files I use should be exactly te same now.

C:\Program Files (x86)\Minimal ADB and Fastboot>fastboot devices
ZY227HDV34 fastboot

C:\Program Files (x86)\Minimal ADB and Fastboot>fastboot boot twrp-3.4.0-0-doha-mauronofrio.img
downloading 'boot.img'...
OKAY [ 0.738s]
booting...
OKAY [ 10.280s]
finished. total time: 11.030s

C:\Program Files (x86)\Minimal ADB and Fastboot>
[Moto G8 Plus Questions & Answers] alecxs:
you are sure you previously installed TWRP already, then you can boot into TWRP recovery with "volume-up & power" (or press + keep holding Vol Up while rebooting from fastboot reboot) then provide lock screen pin/pattern to TWRP so it can decrypt files (TWRP will ask for in case device is encrypted).

in case TWRP is not installed, kindly answer post #10 + following cmds

fastboot getvar securestate
fastboot getvar verity-state
fastboot getvar current-slot

(please note that Minimal ADB and Fastboot is not recommended anymore, it won't work nice with new fastbootd, for example 'fastboot reboot recovery')
[Moto G8 Plus Questions & Answers] Rockel:
Volume-up & power isn't working. Holding down volume-up while booting with fastboot is also not.

It's 2 years ago already since I rooted this device. But always backup the orriginal files used in the rooting process, just in case I will need them on a later moment.

I'm not working with this fastboot, ADB or TWRP etc on regular base. Therefore I forgot about TWRP and I didn't tried it to enter before post #2. So I can't tell if it was working before reloading TWRP through fastboot. However I do not know if loading the exact same version of TWRP using fastboot is causing something to brick?

When using the code in post #10 it shows me:

C:\Program Files (x86)\Minimal ADB and Fastboot>fastboot getvar ro.build.fingerprint[0]
(bootloader) ro.build.fingerprint[0]: not found
getvar:ro.build.fingerprint[0] FAILED (remote failure)
finished. total time: 0.116s

When using codes in post #14:

C:\Program Files (x86)\Minimal ADB and Fastboot>fastboot getvar securestate
securestate: flashing_unlocked
finished. total time: 0.003s

C:\Program Files (x86)\Minimal ADB and Fastboot>fastboot getvar verity-state
verity-state: enforcing (0)
finished. total time: 0.007s

C:\Program Files (x86)\Minimal ADB and Fastboot>fastboot getvar current-slot
current-slot: a
finished. total time: 0.001s
[Moto G8 Plus Questions & Answers] alecxs:
Note that fastboot boot cmd only boot file from PC, it does not install anything.

kindly check what files you have on PC

✓ boot.img

✓ magisk_patched.img

✓ twrp-3.4.0-0-doha-mauronofrio.img

if not, try to get buildno without [0] maybe?

fastboot getvar ro.build.fingerprint
[Moto G8 Plus Questions & Answers] Rockel:
Oh this code did not install or overwrite annything?

fastboot boot twrp-3.4.0-0-doha-mauronofrio.img

I notice the "boot" command now in it. I thought it was installing/ overwriting TWRP.

I still have the following files on my PC:

Magisk:

- boot.img

- magisk_patched.img

Others:

- twrp-3.4.0-0-doha-mauronofrio.img

- XT2019-1_DOHA_RETEU_10_QPI30.28-Q3-28-26-3_subsidy-DEFAULT_regulatory-DEFAULT_CFC.xml.zip

Without [0] worked :)

C:\Program Files (x86)\Minimal ADB and Fastboot>fastboot getvar ro.build.fingerprint
(bootloader) ro.build.fingerprint[0]: motorola/doha_reteu_n/doha_n:10/QP
(bootloader) ro.build.fingerprint[1]: I30.28-Q3-28-26-3/a320d:user/relea
(bootloader) ro.build.fingerprint[2]: se-keys
ro.build.fingerprint: Done
finished. total time: 0.022s
[Moto G8 Plus Questions & Answers] alecxs:
good, buildno matches the already downloaded stock ROM. then most likely the files are matching, too. let's start with flashing...

first flash TWRP into boot partition. then reboot phone, it now has no way to boot into android anymore, but will boot into TWRP instead.

use current-slot: a

fastboot devices
fastboot flash boot_a twrp-3.4.0-0-doha-mauronofrio.img
fastboot reboot

TWRP will now ask for pin/pattern (if required)

first thing to do in TWRP, restore boot partition from adb to restore its bootable state.

(may require adb drivers re-installed)

adb devices
adb push magisk_patched.img /tmp
adb shell
# dd if=/tmp/magisk_patched.img of=/dev/block/bootdevice/by-name/boot_a
# exit

now you've been temporary booted into TWRP. you can now proceed with backup (post #2).

for installing TWRP, download Magisk, add suffix zip to file name, then install this order (I recommend older previously installed Magisk version, latest is not always best):

adb devices
adb push boot.img /tmp
adb push twrp-3.4.0-0-doha-mauronofrio.img /tmp
adb push Magisk-v25.2.apk.zip /tmp
adb shell
# dd if=/tmp/boot.img of=/dev/block/bootdevice/by-name/boot_a
# echo 'KEEPVERITY=false' >/cache/.magisk
# echo 'KEEPFORCEENCRYPT=true' >>/cache/.magisk
# exit

(last line depends wether phone is currently encrypted or not)

1) install TWRP into stock boot ramdisk via TWRP menu (refer to TWRP Other Install guide)

- TWRP > Advanced > Install Recovery Ramdisk

- navigate to /tmp, choose twrp-3.4.0-0-doha-mauronofrio.img

- swipe to install TWRP

2) Now re-install Magisk into boot partition

- TWRP > Install

- choose /tmp/Magisk-v25.2.apk.zip

- swipe to install

assuming everything went well, you have successfully installed TWRP and should now be able to boot into TWRP recovery with Volume Up + Power Buttons any time*

*use TWRP A/B Retention Module on each OTA/Magisk update to preserve TWRP ramdisk in both slots
[Moto G8 Plus Questions & Answers] Rockel:
Ah thanks!

Yes, it should actually be the same ROM as was installed on the phone at the moment. Can't remember exactly, but I needed it in the root proces. I believe for unlocking. That's why I still have the file on my PC. Should be exactly the same.

I see I was using the wrong term "loading" before. But (re) flashing (the same version) TWRP or anything else does still keep the data intact or accessable (if still the case)?

Retrieving the data has my priority now. Since I already have a new phone. So "unbricking" is less important now. Although it will be necessary to retrieve the data I suppose.
[Moto G8 Plus Questions & Answers] alecxs:
the goal is to backup data. it depends on

- TWRP is booting

- device is encrypted or not

- TWRP is able to decrypt or not

in case something does not work, we still have other options without TWRP
[Moto G8 Plus Questions & Answers] Rockel:
Oh cool! So I can safely follow those steps without loosing or corrupt data anny more as it already is?
[Moto G8 Plus Questions & Answers] alecxs:
yes, that is what is intended for. although untested, I don't know if flashing to current slot works like this.

Once you have backup on PC, you can flash all system.img_sparsechunk.* files straight from fastboot to restore stock ROM, or just copy the apk from stock ROM after extracting with simg2img (android-tools-fsutils)

sudo apt install android-tools-fsutils
simg2img system.img_sparsechunk.? system_a.img
sudo mount -t ext4 -o loop,ro,noexec,noload,noatime system_a.img system_root

Spoiler content hidden.

What is the name of the apk you deleted?

/system/product/priv-app/SystemUI/SystemUI.apk
/system/framework/framework-res.apk

Assuming apk was deleted you can push file to /system from TWRP adb shell, only if system partition is mounted rw.

(example)

adb shell mount /system -w
adb push framework-res.apk /system/system/framework

But most likely it isn't that easy - Magisk is systemless root method, it's very unlikely that system partition was modified at all. I don't know what the app used have done to your system app. But in case the app was only disabled, then you need to enable it again. get a copy of the package-restrictions.xml file and edit with Notepad++ only.

adb pull /data/system/users/0/package-restrictions.xml

search for the pkg name= and delete the whole enabled= and enabledCaller= attributes for this app completely. save a copy of the file and push it back to device. in order to preserve file metadata (perm, uid/gid, secontext) use > stdout to redirect file content only (instead of replacing file).

adb push package-restrictions2.xml /tmp
adb shell
# cd /data/system/users/0
# cat /tmp/package-restrictions2.xml > package-restrictions.xml

(Note: it is also safe to delete the whole package-restrictions.xml)

if you still can't fix boot-loop, I will tell you how to insecure enable adb logging and capture adb logcat during startup/boot-loop for further analysis.
[Moto G8 Plus Questions & Answers] Rockel:
I started with the first step. Copied the lines exactly as they were typed, but I got into a boot loop now. Showing the folowing screen:

C:\Program Files (x86)\Minimal ADB and Fastboot>fastboot devices
ZY227HDV34 fastboot

C:\Program Files (x86)\Minimal ADB and Fastboot>fastboot flash boot_a twrp-3.4.0-0-doha-mauronofrio.img
target reported max download size of 805273600 bytes
sending 'boot_a' (34200 KB)...
OKAY [ 0.798s]
writing 'boot_a'...
OKAY [ 0.328s]
finished. total time: 1.134s

C:\Program Files (x86)\Minimal ADB and Fastboot>fastboot reboot
rebooting...

finished. total time: 0.002s

C:\Program Files (x86)\Minimal ADB and Fastboot>

Don't know what to do now. Even don't get it to be turned off, once I press or hold the power button it gets in this boot loop again.

Edit:

Playing around with the buttons brought me back to the normall fastboot screen when holding down "volume-down".

View attachment 5808249
[Moto G8 Plus Questions & Answers] alecxs:
okay, you have successfully flashed TWRP into slot a, but TWRP boot failed. Either that TWRP does not work or it's because of verity-state: enforcing (0). You can flash TWRP into both slots boot_ab. If still no success try with official TWRP instead. (not available)

you can undo by flashing magisk patched boot.img from fastboot.

fastboot flash boot_ab magisk_patched.img
fastboot --set-active=a

edit: after reading whole TWRP support thread, Android 10 is not supported yet. guess you were on Android 9 when installing TWRP. that will explain you losed TWRP because of the upgrade to Android 10.

there is another TWRP for Android 10 in post #115 however it's only zip installer for boot ramdisk. If you share your boot.img + magisk_patched.img I can make twrp.img for you.

or try OrangeFox recovery maybe it is Android 10 ready? unzip recovery.img and try to boot from fastboot.

regarding verity-state: enforcing (0) you can disable avb/dm-verity from fastboot by flashing stock vbmeta.img with additional flags

fastboot flash --disable-verity --disable-verification vbmeta_ab vbmeta.img
[Moto G8 Plus Questions & Answers] Rockel:
Did not seemed to work, so I tried putting it in "b" seperately (it already was in "a"?).

But doing so for "b" also, leaves me with the same exact bootloop as mentioned in post #23

I believe I never updated annymore after rooting. Got some messages of available updates, but I was never able to install because of the unlocked bootloader.
[Moto G8 Plus Questions & Answers] alecxs:
try this TWRP for Android 10 (@Electimon has fixed dead links)

https://xdaforums.com/t/recovery-twrp-twrp-3-4-for-doha.4221243

if fastboot does not understand boot_ab on this phone, repeat the flashing for boot_a and boot_b separately (not sure it's a xiaomi thing, though). Don't forget to set slot a active.

please use latest platform-tools (not minimal adb and fastboot)

edit: it seems for fastboot boot the choice of slot is also important (should not concern flashing trick, though)
[Moto G8 Plus Questions & Answers] Rockel:
Thanks again!

But I was wondering, does it not increase the chance of bricking the phone (and more important the data) by trying experimenting flashing all kind of TWRP versions etc? Or is TWRP installed in a different "partitin" and thus not affecting the ROM and its contained data?

I'm just afraid of messing up and not being able to reach my data at all (for how much it will be still possible).
[Moto G8 Plus Questions & Answers] alecxs:
you can flash boot, system, vendor, vbmeta partition, flashing itself does not concern* userdata partition.

https://xdaforums.com/t/info-android-device-partitions-and-filesystems.3586565

*in case one flash another ROM with higher OS version that may upgrade encryption keys. once upgraded, there is no way to decrypt on older ROM anymore because of the version binding.

You are very lucky bootloader is unlocked already, you can easily access partitions without the need of EDL mode! all it needs is to boot into TWRP.

(on unlocked bootloader) there are two ways to decrypt userdata:

- boot into android

- boot into TWRP recovery

upgrade of encryption keys can only happen during boot into android. you can safely boot into TWRP recovery. for this, either boot the image from 'marked as bootable' slot, or flash the image into active slot (you can set active on choice). please note that installing TWRP is optional.

once in TWRP you will know if userdata partition is encrypted or not, and if TWRP is able to decrypt or not.

when done, restore the magisk_patched (boot) image back into boot_a partition to revert back into the same state as you opened the thread.

I recommend to read the whole thread again. you should know what you're doing. in case you don't understand any command, don't do it.
[Moto G8 Plus Questions & Answers] Rockel:
Oh wow! Manny thanks for explaining! This link was verry informative.

I was actually expecting something like this, but I liked being sure of it before making the complete data useless.

So I could see TWRP actually as somekind of "bootloader" in a seperate MBR partition. And the /data partition where the data is stored, stays untouched.

I actually noticed before that there're a lot of sections on an Android system when I rooted devices (with some help of some guides and figuring out some missing things). Or when scrolling in filemanagers on rooted devices. Sections like /data, / system etc. But never knew it were actually all seperated partitions. Always thought they were somekind of hidden system directories.

That's why I stopped experimenting and first asked if it could not do much more harm, but thanks a lot of explaining. It makes things a lot clearer now. I should get more into this, to understand how the Android file systems works. But don't have much time for it now unfortunately (lot of things on my mind).

Yes, it was the first thing in the rooting proces I did. But when the phone wasn't rooted, then I also would not had this problem now, since there was probably not an easy way to uninstall (the real) "System Framework" then haha :)

So the first thing I'm going to try now, is to get TWRP working. Good to know that I can't mess things up because it's a seperated partition I'm altering here. Gives a relieve to try further! :)

I'm reading through the whole proces now as when I rooted the phone. As noted before I actually had saved all the files and links used. And even made myself a custom manual with all the steps I had followed (because several manuals I'd found weren't complete or did not work for me. So I had to figure some things out myself).

But as far as I can find back in this manual, It already was on Android 10 when rooted. I could remember that it was updated, because all updates were blocked by the Android filesystem (because of the unlocked bootloader).

So basically the Android system and the files stored should be the same at the moment of "bricking" as it was on the time of rooting? Correct?