saltboandClaude Opus 4.7 6bf8ecc8d5 fix(share): return 403 instead of 401 on wrong share password
Dev (vite + miniflare + undici) returns 500 "fetch failed" when the
Worker responds 401 to a POST with a body. undici follows the Fetch
spec's HTTP-auth retry branch, which needs to re-extract the request
body from its source — but the body comes from Node's IncomingMessage
stream, so `body.source` is null and undici throws
`expected non-null body source`. Production (direct CF edge) is
unaffected, this only breaks local dev.

403 is also semantically more accurate: the client isn't performing
HTTP authentication, just supplying a shared secret.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-20 15:10:21 -04:00
2026-04-14 23:44:12 -04:00
2020-10-13 01:50:40 +08:00

ZPan

The open-source, S3-native file hosting platform.

CI codecov Release GitHub Release Docker Image License

Image bed, file sharing, and backup — powered by S3, deployed anywhere.

What is ZPan?

ZPan is a lightweight file hosting platform built on top of S3-compatible storage. Files upload directly from the client to S3, bypassing server bandwidth entirely.

Three scenarios, one platform:

  • Image Bed — Upload via PicGo / ShareX / API, get a URL instantly
  • File Sharing — Upload files, generate share links, distribute to anyone
  • File Backup — CLI agent syncs local directories to S3/R2

Deploy

One-click deploy with zero server management. Free tier covers personal use.

Deploy to Cloudflare

Docker

docker compose up -d

Documentation

Why ZPan?

  • Zero bandwidth bottleneck — files transfer directly between client and S3
  • Zero ops option — deploy to Cloudflare Workers for free, no server needed
  • Self-host friendly — Docker deployment with any S3-compatible storage
  • Tool ecosystem — works with PicGo, ShareX, Flameshot out of the box
  • Open source — free forever for self-hosted users

v1

Looking for ZPan v1 (Go version)? See the v1 branch.

Contributing

See CONTRIBUTING.md for details.

Thank you to all the people who contributed to ZPan!

License

ZPan is under the GPL 3.0 license. See the LICENSE file for details.

S
Description
A self-hosted cloud disk base on the cloud storage./ 一个基于云存储的网盘系统,用于自建私人网盘或企业网盘。
Readme AGPL-3.0
69 MiB
Languages
TypeScript 92.7%
Go 6.5%
JavaScript 0.5%
CSS 0.1%