Full Changelog: v1.2.1...v1.2.2
Changes 4/21/2025 v1.2.2
Added
src/webdav/CurrentUser.php
– Introduces aCurrentUser
singleton to capture and expose the authenticated WebDAV username for use in other components.
Changed
-
src/webdav/FileRiseDirectory.php
– Constructor now takes three parameters ($path
,$user
,$folderOnly
).
– Implements “folder‑only” mode: non‑admin users only see their own subfolder under the uploads root.
– Passes the current user through toFileRiseFile
so that uploads/deletions are attributed correctly. -
src/webdav/FileRiseFile.php
– UsesCurrentUser::get()
when writing metadata to populate theuploader
field.
– Metadata helper (updateMetadata
) now records both upload and modified timestamps along with the actual username. -
public/webdav.php
– Adds a header‐shim at the top to pull Basic‑Auth credentials out ofAuthorization
for all HTTP methods.
– In the auth callback, sets theCurrentUser
for the rest of the request.- Admins & unrestricted users see the full
/uploads
directory. - “Folder‑only” users are scoped to
/uploads/{username}
.
– Configures SabreDAV with the newFileRiseDirectory($rootPath, $user, $folderOnly)
signature and sets the base URI to/webdav.php/
.
- Admins & unrestricted users see the full