[RECOVERY][EXYNOS] TWRP 3.5.2_9 for S10e|S10|S10+ (UPDATE: 2021-06-07)

Search This thread

modpunk

Inactive Recognized Contributor
Oct 14, 2011
1,718
6,647
Sony Xperia XZ1 Compact
Samsung Galaxy S10
[RECOVERY][EXYNOS] TWRP 3.5.2_9 for S10e|S10|S10+ (UPDATE: 2021-06-07)

This project provides the TWRP recovery for the Samsung Galaxy S10e (SM-G970F, beyond0lte), S10 (SM-G973F, beyond1lte) and S10+ (SM-G975F, beyond2lte).

teamwin-recovery-project-twrp-logo.jpg


This recovery supports FBE decryption of AOSP based ROMs like LineageOS, OmniROM etc. There is no support for Samsung ODE in TWRP yet. If you're interested, help to provide it is welcome.

FEATURES

  • File-Based Encryption (FBE) support
  • MTP and ADB support
  • EXT4 support
  • F2FS support
  • EXFAT support
  • Provides unzip
  • Additional languages

KNOWN ISSUES

  • If you decrypt /data with TWRP, the trustzone thinks this is a failed unlock attempt and will lock the storage for 1d
  • 'adb sideload' doesn't work

DOWNLOAD

Make sure you download the .img.xz and corresponding .asc.txt file (see INTEGRITY)! You can decompress the the recovery image using p7zip or xz.

You can always find the latest version of the recovery under the follwing links:

S10e
S10
S10+

INTEGRETY

The recovery images also come with an GPG armor file (.asc). With that file you verify that the image I created hasn't been altered.

How do you do that?

  1. Download my gpg keyring here: https://cryptomilk.org/gpgkey-8DFF53E18F2ABC8D8F3C92237EE0FC4DCC014E3D.gpg.
  2. Download the recovery.img.xz and recovery.img.xz.asc.txt file
  3. Rename the recovery.img.xz.asc.txt file to recovery.img.xz.asc
  4. Verfiy the signature using the following command:
    Code:
    gpg --keyring ./gpgkey-8DFF53E18F2ABC8D8F3C92237EE0FC4DCC014E3D.gpg --verify recovery.img.xz.asc

A good tutorial is: How to verify signatures for packages from the Tor Project.

SECURITY ADVICE


Don't flash ROMs or Magisk modules which set SELinux to permissive or you open your device for malware!

What a Wurst!

Contributors

modpunk, derf elot
Source Code: https://github.com/whatawurst/android_device_samsung_beyond0lte/tree/twrp-9.0


Version Information
Status:
Stable
Current Stable Version: 3.4.0-0
Stable Release Date: 2020-06-12

Created 2020-03-16
Last Updated 2020-06-12
 
Last edited:

modpunk

Inactive Recognized Contributor
Oct 14, 2011
1,718
6,647
Sony Xperia XZ1 Compact
Samsung Galaxy S10
FAQ

How do boot into the bootloader/download mode?

Here are the steps:

  1. Turn off your phone
  2. Press and hold the volume down and bixby keys
  3. Connect a USB cable attached to your computer

The 'Bixby' button is the button below the volume keys.

How do boot into recovery mode?

  1. Turn off you phone
  2. Press and hold the volume up and bixby and power key

You can also do the above when you reboot the phone, once the screen turn black press the buttons.

How do I reboot my phone?

Press and hold the volume down and power key for at least 7 seconds.

How do I unlock my device?

Not that if you unlock your device, your phone will be factory reset! Make sure to make backups.

To unlock your device:

  1. Go to Settings -> About Phone and find the "Build Number"
  2. Tab the build number several times till it tells you that you unlocked the Deverloper Settings
  3. Go to Settings -> System -> Advanded -> Developer Settings
  4. Enable "OEM Unlock"
  5. Reboot to bootloader mode (see above)
  6. Follow the instruction displayed on screen and unlock your device

How do I flash the recovery?

After you unlocked the bootloader:

  1. Boot into download mode (see above)
  2. Flash recovery.img and vbmeta-disabled.img using Odin or Heimdall.

What is VBMETA?

Your phone has a partition for storing cryptographic hashes to verify the validity of the flashed software to all the partitions on your system. This is called Android Verified Boot.

In order to flash a recovery.img you need to replace the VBMETA image with a custom image to disable the checks. You can find a vbmeta-disabled.img here.
 
Last edited:

angela5246

Senior Member
Mar 27, 2020
62
13
@modpunk

Thanks a lot. I was waiting for this for some time now.

Two questions:
1) FBE: Do i need to come from stock to have FBE working? Or is it ok to format /data from within TWRP to activate FBE with the right settings in fstab? I am using Lineage. Did you try that combination? I tried to keep FBE in the past but upon rebooting LineageOS TWRP kept stuck in the splash screen because it was not able to handle FBE.

2) Would it be possible to provide the build steps or would you consider pushing your work on FBE into the official repo? As i can see Ianmac's TWRP version isnt capable of dealing with FBE yet so it would be great to have it official.

Thanks for all your hard work. Much appreciated.
 

modpunk

Inactive Recognized Contributor
Oct 14, 2011
1,718
6,647
Sony Xperia XZ1 Compact
Samsung Galaxy S10
@modpunk

Thanks a lot. I was waiting for this for some time now.

Two questions:
1) FBE: Do i need to come from stock to have FBE working? Or is it ok to format /data from within TWRP to activate FBE with the right settings in fstab? I am using Lineage. Did you try that combination? I tried to keep FBE in the past but upon rebooting LineageOS TWRP kept stuck in the splash screen because it was not able to handle FBE.

Normally, LineageOS sets up FBE by default if the fstab is configured to use FBE. I'm currently working on a LineageOS ROM for the S10e and FBE is working just fine. Normally all you have to to is to format /data. I dunno which ROM you're using and if it has FBE turned on by default.


lineage_trust_beyond0lte.png



2) Would it be possible to provide the build steps or would you consider pushing your work on FBE into the official repo? As i can see Ianmac's TWRP version isnt capable of dealing with FBE yet so it would be great to have it official.

Thanks for all your hard work. Much appreciated.

Take a look at https://github.com/whatawurst and check the corresponding twrp-9.0 branches (Kernel, platform, device).
 
Last edited:

angela5246

Senior Member
Mar 27, 2020
62
13
I see.

So just for clarification: Do you say FBE should work in theory with LOS or did you try it actually? Let me tell you about my experience.

I came from stock to LOS 17 provided by Ivan. Kept the original fstab which has FBE enabled. Didnt format /data so FBE was kept. After flashing LOS from within TWRP i booted into LOS. All fine. But on the first reboot or shutdown the phone automatically goes to TWRP. And there it stucks at the splash screen. At that point only flashing to stock is helping. So Ianmac's TWRP is not able to handle FBE. Are you sure this is different with yours?
 

Top Liked Posts

  • There are no posts matching your filters.
  • 23
    [RECOVERY][EXYNOS] TWRP 3.5.2_9 for S10e|S10|S10+ (UPDATE: 2021-06-07)

    This project provides the TWRP recovery for the Samsung Galaxy S10e (SM-G970F, beyond0lte), S10 (SM-G973F, beyond1lte) and S10+ (SM-G975F, beyond2lte).

    teamwin-recovery-project-twrp-logo.jpg


    This recovery supports FBE decryption of AOSP based ROMs like LineageOS, OmniROM etc. There is no support for Samsung ODE in TWRP yet. If you're interested, help to provide it is welcome.

    FEATURES

    • File-Based Encryption (FBE) support
    • MTP and ADB support
    • EXT4 support
    • F2FS support
    • EXFAT support
    • Provides unzip
    • Additional languages

    KNOWN ISSUES

    • If you decrypt /data with TWRP, the trustzone thinks this is a failed unlock attempt and will lock the storage for 1d
    • 'adb sideload' doesn't work

    DOWNLOAD

    Make sure you download the .img.xz and corresponding .asc.txt file (see INTEGRITY)! You can decompress the the recovery image using p7zip or xz.

    You can always find the latest version of the recovery under the follwing links:

    S10e
    S10
    S10+

    INTEGRETY

    The recovery images also come with an GPG armor file (.asc). With that file you verify that the image I created hasn't been altered.

    How do you do that?

    1. Download my gpg keyring here: https://cryptomilk.org/gpgkey-8DFF53E18F2ABC8D8F3C92237EE0FC4DCC014E3D.gpg.
    2. Download the recovery.img.xz and recovery.img.xz.asc.txt file
    3. Rename the recovery.img.xz.asc.txt file to recovery.img.xz.asc
    4. Verfiy the signature using the following command:
      Code:
      gpg --keyring ./gpgkey-8DFF53E18F2ABC8D8F3C92237EE0FC4DCC014E3D.gpg --verify recovery.img.xz.asc

    A good tutorial is: How to verify signatures for packages from the Tor Project.

    SECURITY ADVICE


    Don't flash ROMs or Magisk modules which set SELinux to permissive or you open your device for malware!

    What a Wurst!

    Contributors

    modpunk, derf elot
    Source Code: https://github.com/whatawurst/android_device_samsung_beyond0lte/tree/twrp-9.0


    Version Information
    Status:
    Stable
    Current Stable Version: 3.4.0-0
    Stable Release Date: 2020-06-12

    Created 2020-03-16
    Last Updated 2020-06-12
    13
    FAQ

    How do boot into the bootloader/download mode?

    Here are the steps:

    1. Turn off your phone
    2. Press and hold the volume down and bixby keys
    3. Connect a USB cable attached to your computer

    The 'Bixby' button is the button below the volume keys.

    How do boot into recovery mode?

    1. Turn off you phone
    2. Press and hold the volume up and bixby and power key

    You can also do the above when you reboot the phone, once the screen turn black press the buttons.

    How do I reboot my phone?

    Press and hold the volume down and power key for at least 7 seconds.

    How do I unlock my device?

    Not that if you unlock your device, your phone will be factory reset! Make sure to make backups.

    To unlock your device:

    1. Go to Settings -> About Phone and find the "Build Number"
    2. Tab the build number several times till it tells you that you unlocked the Deverloper Settings
    3. Go to Settings -> System -> Advanded -> Developer Settings
    4. Enable "OEM Unlock"
    5. Reboot to bootloader mode (see above)
    6. Follow the instruction displayed on screen and unlock your device

    How do I flash the recovery?

    After you unlocked the bootloader:

    1. Boot into download mode (see above)
    2. Flash recovery.img and vbmeta-disabled.img using Odin or Heimdall.

    What is VBMETA?

    Your phone has a partition for storing cryptographic hashes to verify the validity of the flashed software to all the partitions on your system. This is called Android Verified Boot.

    In order to flash a recovery.img you need to replace the VBMETA image with a custom image to disable the checks. You can find a vbmeta-disabled.img here.
    13
    Hello!
    Could you edit your post and detail how you flashed twrp and vbmeta?
    Thanks a lot.
    I still find it confusing

    Disclaimer by @Ivan_Meler:

    Code:
     /*
     * Your warranty is now void.
     *
     * I am not responsible for bricked devices, dead SD cards,
     * thermonuclear war, or you getting fired because the alarm app failed. Please
     * do some research if you have any concerns before flashing!
     * YOU are choosing to make these modifications, and if
     * you point the finger at me for messing up your device, I will laugh at you.
     *


    The instuctions below asume you have an unlocked bootloader, which is mandatory, and if your bootloader isn't unlocked, please look here how to unlock it, and if the OEM unlock button is missing, also look here.


    To flash modpunk's TWRP and vbmeta on S10e SM-970F Exynos international version, you need to:
    1) Download the latest TWRP here.
    2) Download vbmeta disabled image here.
    3) Extract twrp-3.3.1-0-android-10.0-beyond0lte-5.img from the twrp-3.3.1-0-android-10.0-beyond0lte-5.img.xz with 7zip to fx. Desktop. 7zip can be found here.
    4) Rename twrp-3.3.1-0-android-10.0-beyond0lte-5.img to recovery.img.
    5) Rename vbmeta-disabled.img to vbmeta.img.
    6) Place vbmeta.img in same place as recovery.img.
    7) Open 7zip, and navigate to where vbmeta.img and recovery.img is placed.
    8) Archieve vbmeta.img and recovery.img in one arhieve of .tar format (fx. TWRP.tar), and use "Compression level": Store.
    9) Turn of your device
    10) Press and hold the volume down and bixby (Not power!), and keep holding it, while connecting the USB cable between phone and PC.
    11) When the download mode warning screen appear, release all buttons, and follow the instructions on the download mode warning screen.
    12) Open up Odin3 v3.13.1 as admin, and you should se a message saying "Added" in the log, and a blue flag above ID:COM, together with a port number. Odin can be found here, or direct link here.
    13) Press on AP in Odin, and navigate to where TWRP.tar is placed, and select it, so AP becomes checked, and the path to TWRP.tar is viewable in the AP slot.
    14) Navigate to options in Odin, and make sure that "Auto Reboot" is NOT selected, and navigate back to the Log tab.
    15) Press start to flash TWRP.tar.
    16) When a success message is stated in the log, then exit download mode by pressing volume down and power.
    17) When the screen turns of, you need to immediately press the recovery combo (VolumeUp, Bixby and Power), and keep holding it, until the secondary warning appears (The one with warning about unlocked bootloader), then release Bixby and Power, but keep holding volume up, until the TWRP logo is seen.
    18) If you have entered TWRP, then go to bulletpoint 20.
    19) If the phone fails to turn on after 10 seconds, then push power first and immediately after press bixby and volume up as well, until the secondary warning appears (The one with warning about unlocked bootloader), then release Bixby and Power, but keep holding volume up, until the TWRP logo is seen.
    20) In TWRP, swipe slider to allow modification.

    Since @modpunk's TWRP support FBE, you wont be able to see your files through TWRP, until you format data, so:
    1) Go to "Wipe" > "Format Data" in TWRP.
    2) Enter "Yes" in the field to format the data partition/factory reset the device.
    3) Go to the "Reboot" menu in TWRP and select "Recovery" to reboot your Samsung Galaxy S10e.
    4) If the phone boots to TWRP again, then go to "Reboot" menu in TWRP and select "System".

    If you also want to instal LineageOS as well, then:
    1) Make sure the LineageOS flashable .zip file is placed on an external SD card.
    and flash it while you are in TWRP, otherwise it will be wiped when formating the data partition/factory resetting the device.
    2) Go to "Install" > "Select Storage" > "Micro SD card".
    3) Navigate to where LineageOS flashable .zip file is placed, and press to flash.
    4) Confim by sliding the slider.
    5) After successful flash, then =>
    a) If comming from stock or uncompatible ROM, do a full wipe (ART, Cache, Data).
    b) If comming from same developper LineageOS, wipe (ART, Cache).

    Just to have everything in one place, and to gain Magisk root by modpunk's Magisk boot image, then:
    1) Download Magisk boot image for S10e to PC from (magisk_boot_ctc9_beta1.img.xz) here
    2) Extract magisk_boot_ctc9_beta1.img from magisk_boot_ctc9_beta1.img.xz with 7zip, and place the magisk_boot_ctc9_beta1.img in root of your SD card on the phone.
    3) Download Magisk Manager 7.5.1 from here, or direct link here.
    4) Install Magisk Manager 7.5.1 on S10e, and don't wory about it not being instaled, when Magisk is fired up.
    5) Turn of the phone.
    6) When the screen turns of, you need to turn on the phone by pressing the recovery combo (VolumeUp, Bixby and Power), and keep holding it, until the secondary warning appears (The one with warning about unlocked bootloader), then release Bixby and Power, but keep holding volume up, until the TWRP logo is seen.
    7) If you have entered TWRP, then go to bulletpoint 9.
    8) If the phone fails to turn on after 10 seconds, then push power first and immediately after press bixby and volume up as well, until the secondary warning appears (The one with warning about unlocked bootloader), then release Bixby and Power, but keep holding volume up, until the TWRP logo is seen.
    9) Navigate by pressing "Instal" > "Select Storage" > "SD card".
    10) Press "Install Image" to be able to flash an .img file.
    11) Navigate to where the magisk_boot_ctc9_beta1.img is placed, and select it.
    12) Flash magisk_boot_ctc9_beta1.img by swiping the slider.
    13) When flashing is complete, DO NOT do any other modification, navigate back to main screen, and select "Reboot" > "System".
    14) Phone phone is started, enter Magisk Manager.
    15) Magisk Manager will ask to do additional setup, and select yes to to confirm.

    After auto reboot, there is no need for recovery combo to enter rooted system, that is now no longer needed.

    Hope it helps :)
    These are windows instruction, but I still hope someone can share knowledge about Heimdal.
    7
    I've released a new TWRP. Update to 3.4.0 of TWRP and to the latest Linux Kernel we use in LineageOS. I also fixed a small adb bug.
    6
    CHANGELOG

    2020-07-24
    • Update to Linux Kernel 4.14.189
    • Updated to CTF3 blobs
    • Removed TWRP app

    2020-06-09
    • Update to TWRP 3.4 (Fixes for SAR and multi user decryption)
    • Update to Linux Kernel 4.14.183
    • Fixed ADB only mode