ADB + SSH refuse operation when Encryption is enabled on old devices

  • Device: any device with kernels below 5.4
  • Channel: any
  • Build: any

Steps to reproduce

  • Enable encryption on the device
  • Execute:
alfredneumayer@MacBook-Air-von-Alfred quake2touch % adb shell cat /home/phablet/fscrypt_recovery_readme.txt
cat: /home/phablet/fscrypt_recovery_readme.txt: Required key not available

Expected behavior

SSH and ADB work

Actual behavior

They refuse operation because of known issues in the fscrypt issue tracker. Any action taken needs to be by integration of PAM into the respective service or application. Docker User Home Access won't work easily.

Luckily for ADB we have been able to mitigate this issue with MR ubports/development/core/packaging/adbd!10 (merged) but only for interactive sessions, noninteractive ones like you can see above don't work yet.

Devices with Kernels of 5.4 are not susceptible to this issue.

Logfiles and additional information

Edited by Alfred Neumayer