Oriel — AI & technology worth noticing, every day.

Expose only share links of a private service with caddy

Web page · https://dataswamp.org/~solene/2026-10-21-caddy-forward-auth-public-share-links.html

First seen by Oriel on .

AI summary

The article shows how to use Caddy reverse-proxy checks and strict route allowlists to expose only valid Immich and Nextcloud share links while keeping the full services VPN-only.

  • For Immich, Caddy checks `/api/users/me?key=<key>`; a 403 indicates a valid key, though this behavior is an implementation side effect that could change.
  • For Nextcloud, Caddy checks `/s/<token>/authenticate/showShare`; a 200 indicates a valid share token, while invalid tokens receive 404 responses.
  • The public sites allow only selected share pages, APIs, static resources, and Nextcloud WebDAV methods, while removing authentication headers and returning 404 for other routes.
  • Recipients can open shared content in a browser without a VPN or account, but each allowed request adds a validation request and application route changes can break sharing.
  • Valid-link holders can still reach the permitted routes, and a few routes without tokens still reach Nextcloud, so the setup reduces exposure rather than eliminating it.

#caddy #immich #nextcloud #self-hosting

Generated by gpt-5.6-sol. Check the original for details.

Metric trends

Last 30 days · Up to 120 recorded samples per source and metric, with reposts kept separate · First and latest retained

Points

Score reported by the source.

  • Lobsters: 38, latest observation ; +37 over observed period since

Comments

Comment count reported by the source.

  • Lobsters: 6, latest observation ; +6 over observed period since

Aliases

SourceExternal IDURL
Lobsterstu5ynphttps://dataswamp.org/~solene/2026-10-21-caddy-forward-auth-public-share-links.html Read discussion