mirror of
https://github.com/sigoden/dufs.git
synced 2026-06-07 15:59:03 +03:00
[PR #689] [MERGED] fix: tweak auth logic #4086
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/sigoden/dufs/pull/689
Author: @sigoden
Created: 4/25/2026
Status: ✅ Merged
Merged: 4/25/2026
Merged by: @sigoden
Base:
main← Head:fix📝 Commits (1)
db54ca8fix: tweak auth logic📊 Changes
2 files changed (+58 additions, -23 deletions)
View changed files
📝
src/auth.rs(+46 -22)📝
tests/auth.rs(+12 -1)📄 Description
For the same auth paths, permissions defined for deeper directory paths take precedence.
e.g., if
/dir1:rwand/dir1/dir2:roare configured,/dir1/dir2will be read-only.e.g., if
/dir1:roand/dir1/dir2:rware configured,/dir1/dir2will be read-write.When both user-specific and anonymous paths exist, the one granting higher (more permissive) access takes precedence.
e.g., if
user:pass@/dir1:rwand@/dir1/dir2:roare configured,/dir1/dir2will be read-write for that user, and the@/dir1/dir2:rorule can be ignored.Close #676 Revert #521
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.