{"id":13753617,"url":"https://github.com/messense/dav-server-rs","last_synced_at":"2026-02-21T05:15:25.595Z","repository":{"id":41510574,"uuid":"443671503","full_name":"messense/dav-server-rs","owner":"messense","description":"Rust WebDAV server library. A fork of the webdav-handler crate.","archived":false,"fork":false,"pushed_at":"2026-02-09T15:46:57.000Z","size":800,"stargazers_count":211,"open_issues_count":6,"forks_count":42,"subscribers_count":7,"default_branch":"main","last_synced_at":"2026-02-09T19:53:43.819Z","etag":null,"topics":["webdav","webdav-server"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/messense.png","metadata":{"files":{"readme":"README.CalDAV.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2022-01-02T03:16:37.000Z","updated_at":"2026-02-09T15:47:02.000Z","dependencies_parsed_at":"2024-01-10T03:22:28.666Z","dependency_job_id":"652469b9-d9aa-4fb2-9021-172cfb2e6d29","html_url":"https://github.com/messense/dav-server-rs","commit_stats":{"total_commits":390,"total_committers":18,"mean_commits":"21.666666666666668","dds":"0.23076923076923073","last_synced_commit":"084b56b093337ed538587b0fb0afeef6f456b525"},"previous_names":[],"tags_count":30,"template":false,"template_full_name":null,"purl":"pkg:github/messense/dav-server-rs","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/messense%2Fdav-server-rs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/messense%2Fdav-server-rs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/messense%2Fdav-server-rs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/messense%2Fdav-server-rs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/messense","download_url":"https://codeload.github.com/messense/dav-server-rs/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/messense%2Fdav-server-rs/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29672775,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-21T03:11:15.450Z","status":"ssl_error","status_checked_at":"2026-02-21T03:10:34.920Z","response_time":107,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["webdav","webdav-server"],"created_at":"2024-08-03T09:01:25.732Z","updated_at":"2026-02-21T05:15:25.588Z","avatar_url":"https://github.com/messense.png","language":"Rust","funding_links":[],"categories":["Servers","Rust"],"sub_categories":["Standalone"],"readme":"# CalDAV Support in dav-server\n\nThis document describes the CalDAV (Calendaring Extensions to WebDAV) support in the dav-server library.\n\n## Overview\n\nCalDAV is an extension of WebDAV that provides a standard way to access and manage calendar data over HTTP. It's defined in [RFC 4791](https://tools.ietf.org/html/rfc4791) and allows calendar clients to:\n\n- Create and manage calendar collections\n- Store and retrieve calendar events, tasks, and journals\n- Query calendars with complex filters\n- Synchronize calendar data between clients and servers\n\n## Features\n\nThe CalDAV implementation in dav-server includes:\n\n- **Calendar Collections**: A directory that functions as a calendar, containing one `.ics` file for each event.\n- **MKCALENDAR Method**: Create new calendar collection\n- **REPORT Method**: Query calendar data with filters\n- **CalDAV Properties**: Calendar-specific WebDAV properties\n- **iCalendar Support**: Parse and validate iCalendar data\n- **Time Range Queries**: Filter events by date/time ranges\n- **Component Filtering**: Filter by calendar component types (VEVENT, VTODO, etc.)\n\n## Enabling CalDAV\n\nCalDAV support is available as an optional cargo feature:\n\n```toml\n[dependencies]\ndav-server = { version = \"0.8\", features = [\"caldav\"] }\n```\n\n## Quick Start\n\nHere's a basic CalDAV server setup:\n\n```rust\nuse dav_server::{DavHandler, fakels::FakeLs, localfs::LocalFs};\n\nlet server = DavHandler::builder()\n    .filesystem(LocalFs::new(\"/dav_files\", false, false, false))\n    .locksystem(FakeLs::new())\n    .build_handler();\n```\n## Important Setup Notes\n\n**CalDAV Directory Creation**: The `/calendars` directory (defined in `dav_server::caldav::DEFAULT_CALDAV_DIRECTORY`) must exist before CalDAV operations. `MemFs` and `LocalFs` create it automatically, but custom `GuardedFileSystem` implementations must initialize it during startup.\n\n## CalDAV Methods\n\n### MKCALENDAR\n\nCreates a new calendar collection:\n\n```bash\ncurl -X MKCALENDAR http://localhost:8080/calendars/my-calendar/\n```\n\nWith properties:\n\n```bash\ncurl -X MKCALENDAR http://localhost:8080/calendars/my-calendar/ \\\n  -H \"Content-Type: application/xml\" \\\n  --data '\u003c?xml version=\"1.0\" encoding=\"utf-8\" ?\u003e\n\u003cC:mkcalendar xmlns:D=\"DAV:\" xmlns:C=\"urn:ietf:params:xml:ns:caldav\"\u003e\n  \u003cD:set\u003e\n    \u003cD:prop\u003e\n      \u003cD:displayname\u003eMy Calendar\u003c/D:displayname\u003e\n      \u003cC:calendar-description\u003ePersonal calendar\u003c/C:calendar-description\u003e\n    \u003c/D:prop\u003e\n  \u003c/D:set\u003e\n\u003c/C:mkcalendar\u003e'\n```\n\n### REPORT\n\nQuery calendar data:\n\n#### Calendar Query\n\n```bash\ncurl -X REPORT http://localhost:8080/calendars/my-calendar/ \\\n  -H \"Content-Type: application/xml\" \\\n  -H \"Depth: 1\" \\\n  --data '\u003c?xml version=\"1.0\" encoding=\"utf-8\" ?\u003e\n\u003cC:calendar-query xmlns:D=\"DAV:\" xmlns:C=\"urn:ietf:params:xml:ns:caldav\"\u003e\n  \u003cD:prop\u003e\n    \u003cC:calendar-data/\u003e\n  \u003c/D:prop\u003e\n  \u003cC:filter\u003e\n    \u003cC:comp-filter name=\"VCALENDAR\"\u003e\n      \u003cC:comp-filter name=\"VEVENT\"\u003e\n        \u003cC:time-range start=\"20240101T000000Z\" end=\"20241231T235959Z\"/\u003e\n      \u003c/C:comp-filter\u003e\n    \u003c/C:comp-filter\u003e\n  \u003c/C:filter\u003e\n\u003c/C:calendar-query\u003e'\n```\n\n#### Calendar Multiget\n\n```bash\ncurl -X REPORT http://localhost:8080/calendars/my-calendar/ \\\n  -H \"Content-Type: application/xml\" \\\n  --data '\u003c?xml version=\"1.0\" encoding=\"utf-8\" ?\u003e\n\u003cC:calendar-multiget xmlns:D=\"DAV:\" xmlns:C=\"urn:ietf:params:xml:ns:caldav\"\u003e\n  \u003cD:prop\u003e\n    \u003cC:calendar-data/\u003e\n  \u003c/D:prop\u003e\n  \u003cD:href\u003e/my-calendar/event1.ics\u003c/D:href\u003e\n  \u003cD:href\u003e/my-calendar/event2.ics\u003c/D:href\u003e\n\u003c/C:calendar-multiget\u003e'\n```\n\n## CalDAV Properties\n\nThe implementation supports standard CalDAV properties:\n\n### Collection Properties\n\n- `calendar-description`: Human-readable description\n- `calendar-timezone`: Default timezone for the calendar\n- `supported-calendar-component-set`: Supported component types (VEVENT, VTODO, etc.)\n- `supported-calendar-data`: Supported calendar data formats\n- `max-resource-size`: Maximum size for calendar resources\n\n### Principal Properties\n\n- `calendar-home-set`: URL of the user's calendar home collection\n- `calendar-user-address-set`: Calendar user's addresses\n- `schedule-inbox-URL`: URL for scheduling messages\n- `schedule-outbox-URL`: URL for outgoing scheduling\n\n## Working with Calendar Data\n\n### Adding Events\n\nStore iCalendar data using PUT:\n\n```bash\ncurl -X PUT http://localhost:8080/calendars/my-calendar/event.ics \\\n  -H \"Content-Type: text/calendar\" \\\n  --data 'BEGIN:VCALENDAR\nVERSION:2.0\nPRODID:-//Example Corp//CalDAV Client//EN\nBEGIN:VEVENT\nUID:12345@example.com\nDTSTART:20240101T120000Z\nDTEND:20240101T130000Z\nSUMMARY:New Year Meeting\nDESCRIPTION:Planning meeting for the new year\nEND:VEVENT\nEND:VCALENDAR'\n```\n\n### Retrieving Events\n\nUse GET to retrieve individual calendar resources:\n\n```bash\ncurl http://localhost:8080/calendars/my-calendar/event.ics\n```\n\n## Client Compatibility\n\nThe CalDAV implementation has been tested with:\n\n- **Thunderbird**: Full support for calendar sync\n- **Apple Calendar**: Compatible with basic operations\n- **CalDAV-Sync (Android)**: Works with standard CalDAV features\n- **Evolution**: Support for calendar collections and events\n\n## Limitations\n\nCurrent limitations include:\n\n- No scheduling support (iTIP/iMIP)\n- Limited calendar-user-principal support\n- No calendar sharing or ACL support\n- Basic time zone handling\n- No recurring event expansion in queries\n\n## Example Applications\nThese calendar server examples lacks authentication and does not support user-specific access. The default FileSystems can only create collections on the path \"/calendars\".  \nFor a production environment, you should implement the GuardedFileSystem for better security and user management.\n\n### Calendar Server\n\n```rust\nuse dav_server::{DavHandler, fakels::FakeLs, localfs::LocalFs};\nuse std::net::SocketAddr;\n\n#[tokio::main]\nasync fn main() {\n    let server = DavHandler::builder()\n        .filesystem(LocalFs::new(\"/calendars\", false, false, false))\n        .locksystem(FakeLs::new())\n        .build_handler();\n\n    // Serve on port 8080\n    // Calendars accessible at http://localhost:8080/calendars/\n}\n```\n\n### Multi-tenant Calendar Service\n\n```rust\nuse dav_server::{DavHandler, memfs::MemFs, memls::MemLs};\n\n// Use in-memory filesystem for demonstration\nlet server = DavHandler::builder()\n    .filesystem(MemFs::new())\n    .locksystem(MemLs::new())\n    .principal(\"/principals/user1/\")\n    .build_handler();\n```\n\n## Testing\n\nRun CalDAV tests with:\n\n```bash\ncargo test --features caldav caldav_tests\n```\n\nRun the CalDAV example:\n\n```bash\ncargo run --example caldav --features caldav\n```\n\n## Standards Compliance\n\nThis implementation follows:\n\n- [RFC 4791](https://tools.ietf.org/html/rfc4791) - Calendaring Extensions to WebDAV (CalDAV)\n- [RFC 5545](https://tools.ietf.org/html/rfc5545) - Internet Calendaring and Scheduling Core Object Specification (iCalendar)\n- [RFC 4918](https://tools.ietf.org/html/rfc4918) - HTTP Extensions for Web Distributed Authoring and Versioning (WebDAV)\n\n## Contributing\n\nContributions to improve CalDAV support are welcome. Areas for enhancement include:\n\n- Scheduling support (iTIP)\n- Additional client compatibility testing","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmessense%2Fdav-server-rs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmessense%2Fdav-server-rs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmessense%2Fdav-server-rs/lists"}