[RECOVERY][ROOT][TWRP 3.1.1-1] Galaxy A3 - SM-A320F/FL/Y (2017)

Search This thread

zogoibi

Senior Member
Aug 18, 2011
419
76
A little question:
I've TWRP'ed my device according to this thread. Afterwards, I've installed a custom ROM. Now, whenever I boot into Recovery, Samsung's splash screen is normal, BUT!: if I boot into System, I get the red message on top left of splash screen: "kernel is not seandroid enforcing".
I know this is not an issue, since we're supposed to get that message when the device detects a non-stock ROM. However, I'm curious why there is no such message if I boot to Recovery?
Someone knows? Thank you.
 
Last edited:

ashyx

Inactive Recognized Contributor
Oct 14, 2012
15,055
9,944
A little question:
I've TWRP'ed my device according to this thread. Afterwards, I've installed a custom ROM. Now, whenever I boot into Recovery, Samsung's splash screen is normal, BUT!: if I boot into System, I get the red message on top left of splash screen: "recovery is not seandroid enforcing".
I know this is not an issue, since we're supposed to get that message when the device detects a non-stock ROM. However, I'm curious why there is no such message if I boot to Recovery?
Someone knows? Thank you.
Are you sure you're not getting that back to front?
You would get it booting to recovery not system.
Booting to system would say 'kernel is not seandroid enforcing".
 
  • Like
Reactions: McFy

zogoibi

Senior Member
Aug 18, 2011
419
76
Are you sure you're not getting that back to front?
You would get it booting to recovery not system.
Booting to system would say 'kernel is not seandroid enforcing".

That's correct. But anyways, I get no message when booting to custom recovery. Only to custom ROM. How so? Just curious.
 

ashyx

Inactive Recognized Contributor
Oct 14, 2012
15,055
9,944
@ashyx did you manage to look at the boot.img files that @AK2H posted for the disable forced-encryption patching on Oreo?
My bad I forgot to come back to this. I can fix it but give me time as it's not an easy fix.
I need the boot.img from the latest Oreo firmware.
 
  • Like
Reactions: Pat750

zogoibi

Senior Member
Aug 18, 2011
419
76
Hello all.
Suppose my phone has stock Nougat and this TWRP.
Suppose now I want to update to stock Oreo.
Since the phone already has a working bootloader, a working modem and a working recovery with which I'm happy, and since this TWRP can flash .img files, can I simply extract system.img and flash it with TWRP? Would that work? Should I need to flash some other .img files from stock?
Or is this totally wrong?
My idea is to avoid the Odin thing altogether (flash stock, reflash twrp, etc), if possible, while at the same time preserving my data and skipping the risk of getting RMM locked if something goes wrong the Odin way before I can apply the RMM-bypass patch.
Thank you in advance.
 
Last edited:

Pat750

Senior Member
Sep 12, 2016
587
259
Hello all.
Suppose my phone has stock Nougat and this TWRP.
Suppose now I want to update to stock Oreo.
Since the phone already has a working bootloader, a working modem and a working recovery with which I'm happy, and since this TWRP can flash .img files, can I simply extract system.img.lz4 and flash it with TWRP? Would that work? Should I need to flash some other .img.lz4 files from stock?
Or is this totally wrong?
My idea is to avoid the Odin thing altogether (flash stock, reflash twrp, etc), if possible, while at the same time preserving my data and skipping the risk of getting RMM locked if something goes wrong the Odin way before I can apply the RMM-bypass patch.
Thank you in advance.
I really don't know if this would work, but it doesn't sound totally wrong, but it could be...
All I know is that lz4 files are compressed too. To uncompress I used (with PC) 7zip with modern 7zip extension. Then the img file can be flashed with TWRP.
Edit. There is more info about flashing img files in OP first page.
 
Last edited:

zogoibi

Senior Member
Aug 18, 2011
419
76
I really don't know if this would work, but it doesn't sound totally wrong, but it could be...
All I know is that lz4 files are compressed too. To uncompress I used (with PC) 7zip with modern 7zip extension. Then the img file can be flashed with TWRP.
Edit. There is more info about flashing img files in OP first page.

Hi again, @Pat750! :)

Yes. I've read that info, but I need to know a couple more things, like for instance: what's the meta-data folder for?, do I need it? I can't do anything in TRWP with it, so if it's necessary, then that's the end.

True, I've realized that lz4 files are compressed, but easy to decompress as you point out.

Generally, the idea makes sense to me. The main question here is: can the Oreo system boot off a Nougat bootloader? I.e., does Oreo feature a "bootloader checker" ready to abort the boot process? Likely so. At least, were I the engineer, I'd do it that way.

Anyhow I guess I'll just try. Not much to lose: at worst, I can always enter recovery and flash my nandroid backup.
 

potyqa

Senior Member
May 27, 2017
148
40
Hi again, @Pat750! :)

Yes. I've read that info, but I need to know a couple more things, like for instance: what's the meta-data folder for?, do I need it? I can't do anything in TRWP with it, so if it's necessary, then that's the end.

True, I've realized that lz4 files are compressed, but easy to decompress as you point out.

Generally, the idea makes sense to me. The main question here is: can the Oreo system boot off a Nougat bootloader? I.e., does Oreo feature a "bootloader checker" ready to abort the boot process? Likely so. At least, were I the engineer, I'd do it that way.

Anyhow I guess I'll just try. Not much to lose: at worst, I can always enter recovery and flash my nandroid backup.
I'm happy to tell you that Nougat and Oreo use the same bootloader! And by the way I don't think there's a checker because I've managed to boot stock Marshmallow with the Nougat/Oreo bootloader?
 

zogoibi

Senior Member
Aug 18, 2011
419
76
I'm happy to tell you that Nougat and Oreo use the same bootloader! And by the way I don't think there's a checker because I've managed to boot stock Marshmallow with the Nougat/Oreo bootloader?

Thank you! But that puzzles me: if Nougat and Oreo share bootloaders, then, where has Samsung installed the RMM/FRM lock thingie? Is that in the system itself? In such case, after System I should definitely flash the RMM-bypass, right?
 
Last edited:

Top Liked Posts

  • There are no posts matching your filters.
  • 47
    Unofficial release -TWRP recovery for the Galaxy A3 SM-A320F/FL/Y, Exynos7870

    teamwin-recovery-project-twrp-logo.jpg


    Update 11/9/2017
    TWRP 3.1.1-1 MM build released.

    Current status: BETA

    Features:

    MTP
    ADB
    SEANDROID warning fix
    TWRP and Kernel built from latest source
    Factory Image flashing(see below)
    NTFS support
    F2FS support >> To be added
    TWRP Official APP support

    New feature available in TWRP v3 is system image backup and restore and factory image flashing (see TWRP changelog for details)
    Basically this means factory images from the official firmware can now be flashed with TWRP instead of ODIN. I have extended this feature to include BOOT, RECOVERY, SYSTEM, CACHE, HIDDEN and RADIO(MODEM) partitions.
    This feature can be found under INSTALL >> INSTALL IMAGE >> select image to flash >> select partition.
    NOTE: To flash the modem, first it needs to be renamed to modem.bin.img




    You flash this at your own risk. Please ensure you have the stock ROM to hand downloaded from SAMMOBILE in case of problems. This will trip the knox counter.


    Instructions:


    Flash with ODIN 3.10.7 in the AP slot.
    Put your device in DOWNLOAD mode.
    Uncheck Auto reboot.
    Load the respective file below into the AP slot and hit start.
    After flashing and ODIN reports PASS immediately reboot to recovery by holding POWER + HOME + VOL DOWN.
    As soon as the screen goes blank change to VOL UP whilst still holding POWER + HOME.
    You should now see TWRP recovery.


    NOTE: ON SOME ANDROID 5.1.1/6.0 DEVICES IT IS NECESSARY TO GO TO:
    Settings -> Developer Options -> OEM unlocking
    AND ENABLE OEM UNLOCK FIRST OR YOU MAY ENCOUNTER 'BLOCKED BY FRP LOCK' WHEN FLASHING.


    DOWNLOAD:
    twrp_3.1.1-1_sm-a320f_11917


    To Root:
    Flash the latest SuperSU release with TWRP:
    https://xdaforums.com/apps/supersu/2014-09-02-supersu-v2-05-t2868133/

    To disable forced encryption and mount internal storage:
    (Note this MUST be flashed after SuperSU if you intend to root)

    1. Boot to Twrp
    2. Format Data partition using FORMAT DATA button under Wipe options.
    (Note: This will wipe the internal storage)
    3. Check DATA is mountable.
    4. Install SuperSU (if root is required)
    5. Install boot image patch below.
    6. Reboot

    Boot image patch
    no-verity-no-encrypt_ashyx




    Twrp Source : https://github.com/omnirom/android_bootable_recovery

    Kernel source : http://opensource.samsung.com/reception/receptionSub.do?method=sub&sub=F&searchValue=Sm-a320f


    PLEASE DO *NOT* DIRECT LINK TO THESE FILES. PLEASE LINK TO THIS POST

    Screenshot_2016_03_05_08_13_44_1.png


    DnoCrqh.png


    VAm49c4.png


    ytBFf13.png


    ONLSkMi.png



    Credits: Me, Teamwin
    Please note I don't own this device and spend a lot of my free time bringing these builds for you to use and benefit from.

    FEEDBACK IS APPRECIATED PLEASE.
    THANKS.


    DONATE ME HERE IF YOU WANT TO BUY ME A BEER OR HIT THE THANKS BUTTON IF I HELPED YOU



    .
    .
    9
    TWRP on SM-A320 with working /data (no encryption)

    For anyone else struggling with inability to mount data in TWRP, I thought I would share the following info.

    The key bit of information I was missing was:
    The current latest version of TWRP on the offical site (TWRP for a3y17lte; twrp-3.2.3-0) does not support mounting volumes with "quota" enabled. Therefore if you retain the original stock boot.img which includes quota on the /data partition, it will not mount in TWRP. See https://xdaforums.com/galaxy-s7/help/twrp-issue-t3878565

    Additionally the data partition is encrypted on first boot unless you disabled this.

    Luckily Zackptg5 has made a package which can perform both actions (remove quota and encryption) and also prepare for installing Magisk. https://xdaforums.com/android/software/universal-dm-verity-forceencrypt-t3817389 / https://zackptg5.com/android.php#disverfe. Rename the zip file to include "quota" somewhere in the file name in order to remove quota form the data partition.

    The sequence I used (not all these steps may be strictly necessary, this just gives the configuration I wanted):

    1. Flash stock firmware; A320FLXXS3CRK3_A320FLBTU3CRL1_BTU, using ODIN v3.13.1. Flash HOME_CSC to wipe data. Allow to reboot
    2. Install TWRP using ODIN; flash in AP using older version Odin3 v3.12.10. Untick auto reboot, when complete power off with vol down + power, then force to recovery using vol up, home and power
    3. Wipe data
    4. Flash RMM-State_Bypass_Mesa_v2 (may not be necessary, but doesn't seem to cause any problems so better safe than sorry)
    5. Rename Universal DM-Verity, ForceEncrypt, Disk Quota Disabler to include "quota" in the zip name (download from: https://zackptg5.com/android.php#disverfe)
    6. Flash renamed Universal DM-Verity, ForceEncrypt, Disk Quota Disablers; Do not reboot after!
    7. Flash Magisk 18.1
    8. Flash Busybox (TWRP); https://xdaforums.com/android/software-hacking/tool-busybox-flashable-archs-t3348543
    9. Reboot to system
    10. Set up phone and restore backups
    11. Install Magisk 18.1 manager app

    Hope this helps anyone looking for information on why data cannot be mounted in TWRP for this phone!

    Jack
    5
    D
    Deleted member 3370907
    Since I'm porting LineageOS to this device I'd very much like to have a look at the source code of this.
    3
    Ok; so: TWRP, superuser and no-verity patch applied. So far, so good; yet there's a little problem:

    I'm experiencing the unlock screen lag issue to the point that I can only unlock using my fingerprint (which is lightning fast); because if I try to unlock with pattern (or PIN) and battery-saver is on, the lag is such that the lockscreen doesn't ever unlock.

    Now, searching around I've read that this issue might be related to Superuser and/or no-verity patch; so I think: no harm in trying Magisk.

    But for that, I have a few doubts:

    1.- For going the Magisk way, do I still need the no-encrypt-no-verity patch? I read people here writing about the "patched Superuser", but I don't know whether, by that, they mean the Superuser+no-verity-patch coupling, or whether the Superuser link in the OP's instructions is somehow already patched, AND the no-verity-patch is yet another patch for attaining a non-encrypted internal storage.
    In other words, does Magisk by itself prevent stock's enforced encryption?

    2.- Since I'm already on Superuser+no-verity-patch, for going the Magisk way can I simply and merrily now install the Magisk zip via TWRP, or must I fisrt uninstall Superuser? Must I ALSO uninstall the no-verity-patch?

    3.- In case I must uninstall Superuser/no-verity (or both), is there any way of doing it without having first to full wipe?

    4.- This is merely a curiosity, but of some relevance: According to the OP, the no-verity-no-encrypt patch is needed for preventing forced encryption and making possible TWRP backups; however, according to this post in this thread, TWRP is able to mount and read internal storage, and do backups, without having applied the famous patch. Both assertions seem to contradict one another. Which one is true?

    Thanks in advance.
    As far as I know the unlock screen lag issue is related to new versions of SuperSU, I'm not sure about Superuser.

    1. Magisk has it's own no-dm-verity patch enabled.

    2. I really think you should delete Superuser first, not sure about no-verity patch.

    3. The best thing to do is take a backup for the (Data) partition in TWRP --> Flash the AP part of the ROM via Odin so you get a clean System and Boot --> Flash TWRP again via Odin --> Format the (Data) partition as instructed in OP --> Install Magisk.zip (now you have root and no-verity patch) --> Restore the Data partition backup.
    P.S your internal storage will be wiped during these steps!

    4. Disabling dm-verity is mandatory to disable forced encryption and making possible TWRP backups.
    3
    Hi @ashyx I don't want to bother you and maybe you already know about this qouta support thing TKKG1994 wrote here
    https://xdaforums.com/s7-edge/development/recovery-official-twrp-hero2lte-3-0-0-0-t3334084/page223
    Maybe that's why our TWRP can't mount data on Oreo Stock ROMs with Magisk?
    My knowledge is too limited to understand this.
    Would be so cool if you or @McFy could take a look at this (don't know how much you guys work together though).
    Please ignore this post if it is useless.
    Hello, I yet tought about adding it due to force encrypt, It's an oreo flag for fstab, I planned to add it for my twrp build because as I fixed encryption in lineage I took a look around twrp as well, but I have no Idea about stock oreo, I never flashed it .. but problem could be solved by this, wait next twrp offiical build.
    Sorry to make ads about mine version, it's not the aim :) , and no, ashyx sources are not released so mine trees are totally different,
    Regards