Issue Description
For an account with no configured disk quota, WebDAV reports DAV:quota-available-bytes as though the account had a maximum quota of u32::MAX bytes.
Current main uses u32::MAX as u64 as the fallback quota when neither the account nor its tenant has a disk quota. The used quota is then subtracted from this value.
As a result, an unlimited account appears to WebDAV clients to have slightly less than 4 GiB available.
Expected Behavior
An account with unlimited storage should not be advertised as having an artificial ~4 GiB limit.
RFC 4331 §3 allows DAV:quota-available-bytes to be omitted for resources with infinite limits, or recommends returning an appropriate capacity value.
Actual Behavior
DAV:quota-available-bytes is reported as:
4294967295 - quota-used-bytes
for an account without a configured disk quota.
Reproduction Steps
- Create an account without a disk quota and, if applicable, without a tenant disk quota.
- Authenticate as that account.
- Send a depth-0
PROPFINDfor a DAV collection requestingDAV:quota-available-bytesandDAV:quota-used-bytes. - Observe that
quota-available-bytesis below4294967296, despite the account having no quota.
For example:
curl -u '[email protected]:password' \
-X PROPFIND 'https://mail.example.com/dav/cal/user%40example.com/' \
-H 'Depth: 0' \
-H 'Content-Type: application/xml' \
--data '<?xml version="1.0"?><D:propfind xmlns:D="DAV:"><D:prop><D:quota-available-bytes/><D:quota-used-bytes/></D:prop></D:propfind>'
Relevant Log Output
No error is logged. The request succeeds with 207 Multi-Status; the incorrect value is returned in DAV:quota-available-bytes.
Stalwart Version
v0.16.x
Installation Method
Built from source
Database Backend
RocksDB
Blob Storage
RocksDB
Search Engine
Internal
Directory Backend
Internal
I have reviewed the documentation and FAQ and confirm that my issue is NOT addressed there.
on
I have searched this support forum (open and closed topics) and confirm this is not a duplicate.
on
I understand that topics in this category are triaged by a bot first but a human reply will follow up. If I’d prefer a human-only reply, I’ll add the no-ai tag to my topic.
on