Webdav access control

The Basics

  • Nextcloud Server version : 33

Summary of the issue you are facing:

I don’t understand how I can restrict the access to a specific folder via webdav.

The documentation explains how to access files via webdav, by using Nextcloud username and application password, then using the URL : https://cloud.example.com/remote.php/dav/files/USERNAME/A_specific_folder/

And this works perfectly fine : A_specific_folder can be access via webDAV protocol.

But actually using all the same configuration and removing the trailing folder in the URL, i.e. https://cloud.example.com/remote.php/dav/files/USERNAME/ or putting a different folder like https://cloud.example.com/remote.php/dav/files/USERNAME/A_Folder_I_DO_NOT_want_be_accessed_via_webdav/ this can actually be done :confused: why ?

How could i set up webdav access to be restricted to ONE specific folder ?

Thanks for your help !

Guitch

Can you elaborate on your use case? Are you trying to lock down your own access or is this a scenario where you’re sharing files (which should be handled differently)?

My use case is that I am configuring Floccus to sync my navigator bookmarks via Webdav on my Nextcloud instance.

It is working fine BUT I have configured the Firefox plugin with the following settings :

  • webdav URL : https://[myNCservername]/remote.php/dav/files/[myNCusername]/FloccusWebDAV/
  • username and password

I would have much prefered for this username and password to be able to restrict the access to that FloccusWebDAV folder ONLY. My removing the folder in the setting, with the username and password, “the plugin” can access ALL the subfolder of that user…

I don’t know if I am missing something but it feels like I am as I am finding hard to explain it properly… but I hope it makes sense

Thanks for your help anyway !!

You could use a share instead then it wouldn’t be coupled to your credentials nor to your account’s access.