folder permissions, security concern

hello guys

i am a total linux noob but syncthing is running great on my ubuntu desktop server PC. https (lets encrypt) and reverse proxy (caddy). i am able to sync my 3 clients when i’m at home, and even when connected over vpn to my home network.

my concern right now is security due to folder permissions:

drwxrwxrwx 1 root root   4096 Sep 18 19:28 kamera_lg
drwxrwxrwx 1 root root   4096 Okt  5 18:55 sync_important
drwxrwxrwx 1 root root      0 Sep 17 19:35 viber_lg
drwxrwxrwx 1 root root 188416 Okt  5 17:14 whatsapp_lg

the folders are owned by root (which i think is wrong) and on top of that all permissions are enabled.

my question is how i can correct this without breaking the functionality of the setup?

would appreciate some guidance very much

cheers and stay safe

I don’t think it’s a syncthing specific question, as there are plenty of information out there on the internet how linux permissions and ownership works.

The only thing you need to care about is that syncthing process runs under the user that has the required permissions to interact with those folders.

ok… it might not be a specific syncthing question, but there might be a general recommendation on how to set this up… thats why i asked here…

i am not happy that it is running under root…

but ok, i will look somewhere else for help.


Files will be created as the user running Syncthing, with the permissions copied from the other side. If the other side doesn’t have usable permissions you can set ignore permissions on the folder – Syncthing will then instead follow the system umask. So you can control both the owner and the permissions.