feat: Implement WebFinger discovery and ActivityPub user actor endpoint

- Added a new router for handling well-known endpoints, specifically WebFinger.
- Implemented the `webfinger` function to respond to WebFinger queries.
- Created a new route for WebFinger in the router.
- Refactored user retrieval logic to support both user ID and username in a single endpoint.
- Updated user router to use the new `get_user_by_param` function.
- Added tests for WebFinger discovery and ActivityPub user actor endpoint.
- Updated dependencies in Cargo.toml files to include necessary libraries.
This commit is contained in:
2025-09-06 01:18:04 +02:00
parent 3d73c7f198
commit c7c573f3f4
11 changed files with 935 additions and 70 deletions

View File

@@ -22,6 +22,8 @@ tower-http = { version = "0.6.6", features = ["fs", "cors"] }
tower-cookies = "0.11.0"
anyhow = "1.0.98"
dotenvy = "0.15.7"
activitypub_federation = "0.6.5"
url = "2.5.7"
# db
sea-orm = { workspace = true }
@@ -29,8 +31,11 @@ sea-orm = { workspace = true }
# doc
utoipa = { workspace = true }
serde_json = { workspace = true }
# local dependencies
app = { path = "../app" }
models = { path = "../models" }
[dev-dependencies]