android 11 again: permission denied while receiving files on the phone
See original GitHub issueIntroduction: If you have issues with this fork, feel free to post them. I’ll look into them if a good reproducer or log is provided.
Description of the issue
I’m using the version linked here because of the reasons described in the other bug report: https://github.com/Catfriend1/syncthing-android/issues/704#issuecomment-732749149 things are working good, syncthing keeps shoveling my pictures off the phone to the private storage. I shared another directory that should be kept in sync over many devices, data goes to and fro this time. but file will not roll in. directories are created though.
Reproducer
have a folder X on device B (any) share it with device A (Android 11, oneplus 8 in my case). put a new file in X on B. wait for it to show up on A A gets permission denied.
actual error message from the web gui on the phone:
syncing: opening temp file: open /storage/emulated/0/Bunny Squad Common/Murmeltier/.syncthing.murmel_2020-12-24T04:59:06.mp3.tmp: operation not permitted
Notice: the directory was created, the file was not. unix permissions seem to be in order: 660/770, root:everybody
GF’s oneplus 8, kept on android 10 does not show this problem.
Version Information
App Version: 1.12.0.0
Syncthing Version: v1.12.0-preview.3
Android Version: Android 11
Device manufacturer: Oneplus
Device model: 8 (256gig)
Device platform info
adb shell "getprop | grep ro.product"
[ro.product.board]: [kona]
[ro.product.brand]: [OnePlus]
[ro.product.build.date]: [Thu Nov 19 01:17:19 CST 2020]
[ro.product.build.date.utc]: [1605719839]
[ro.product.build.fingerprint]: [OnePlus/OnePlus8_EEA/OnePlus8:11/RP1A.201005.001/2011190109:user/release-keys]
[ro.product.build.id]: [RP1A.201005.001]
[ro.product.build.tags]: [release-keys]
[ro.product.build.type]: [user]
[ro.product.build.version.incremental]: [2011190109]
[ro.product.build.version.release]: [11]
[ro.product.build.version.release_or_codename]: [11]
[ro.product.build.version.sdk]: [30]
[ro.product.cpu.abi]: [arm64-v8a]
[ro.product.cpu.abilist]: [arm64-v8a,armeabi-v7a,armeabi]
[ro.product.cpu.abilist32]: [armeabi-v7a,armeabi]
[ro.product.cpu.abilist64]: [arm64-v8a]
[ro.product.device]: [OnePlus8]
[ro.product.first_api_level]: [29]
[ro.product.locale]: [en-US]
[ro.product.manufacturer]: [OnePlus]
[ro.product.model]: [IN2013]
[ro.product.name]: [OnePlus8_EEA]
[ro.product.odm.brand]: [OnePlus]
[ro.product.odm.device]: [OnePlus8]
[ro.product.odm.manufacturer]: [OnePlus]
[ro.product.odm.model]: [IN2013]
[ro.product.odm.name]: [OnePlus8_EEA]
[ro.product.product.brand]: [OnePlus]
[ro.product.product.device]: [OnePlus8]
[ro.product.product.manufacturer]: [OnePlus]
[ro.product.product.model]: [IN2013]
[ro.product.product.name]: [OnePlus8_EEA]
[ro.product.property_source_order]: [odm,vendor,product,system_ext,system]
[ro.product.system.brand]: [OnePlus]
[ro.product.system.device]: [OnePlus8]
[ro.product.system.manufacturer]: [OnePlus]
[ro.product.system.model]: [IN2013]
[ro.product.system.name]: [OnePlus8_EEA]
[ro.product.system_ext.name]: [qssi]
[ro.product.vendor.brand]: [OnePlus]
[ro.product.vendor.device]: [OnePlus8]
[ro.product.vendor.manufacturer]: [OnePlus]
[ro.product.vendor.model]: [IN2013]
[ro.product.vendor.name]: [OnePlus8_EEA]
[ro.product.vndk.version]: [30]
Android Log
adb logcat v
or MatLog (search on GitHub) output
this should be the relevant part:
12-28 13:30:06.580 8651 8651 W libsyncthingnat: type=1400 audit(0.0:132622): avc: denied { bind } for scontext=u:r:untrusted_app:s0:c244,c257,c512,c768 tcontext=u:r:untrusted_app:s0:c244,c257,c512,c768 tclass=netlink_route_socket permissive=0 b/155595000 app=com.github.catfriend1.syncthingandroid
12-28 13:30:06.911 2442 2442 E EventProcessor: onItemFinished: Error "opening temp file: open /storage/emulated/0/Bunny Squad Common/Murmeltier/.syncthing.murmel_2020-12-25T04:59:07.mp3.tmp: operation not permitted" reported on file: /storage/emulated/0/Bunny Squad Common/Murmeltier/murmel_2020-12-25T04:59:07.mp3
12-28 13:30:06.913 2442 2442 E EventProcessor: onItemFinished: Error "opening temp file: open /storage/emulated/0/Bunny Squad Common/Murmeltier/.syncthing.murmel_2020-12-26T04:59:06.mp3.tmp: operation not permitted" reported on file: /storage/emulated/0/Bunny Squad Common/Murmeltier/murmel_2020-12-26T04:59:06.mp3
12-28 13:30:06.916 2442 2442 E EventProcessor: onItemFinished: Error "opening temp file: open /storage/emulated/0/Bunny Squad Common/Murmeltier/.syncthing.murmel_2020-12-27T08:16:59.mp3.tmp: operation not permitted" reported on file: /storage/emulated/0/Bunny Squad Common/Murmeltier/murmel_2020-12-27T08:16:59.mp3
Issue Analytics
- State:
- Created 3 years ago
- Comments:14 (7 by maintainers)
@oliver Don’t use special chars and feel safe 😃
solution is found, problem is solved: https://forum.syncthing.net/t/permission-denied-on-syncthing-tmp-files-on-android/16096/5
tl;dr android 11 apparently now uses a table to allocate files because it doesn’t like colons in filenames any more.