Skip to content

fix(blob): switch to private access with auth-gated delivery route#1482

Closed
vvo wants to merge 2 commits intomainfrom
vvo/blob-private-access
Closed

fix(blob): switch to private access with auth-gated delivery route#1482
vvo wants to merge 2 commits intomainfrom
vvo/blob-private-access

Conversation

@vvo
Copy link
Copy Markdown
Member

@vvo vvo commented Apr 13, 2026

Summary

User-uploaded images are auth-gated content that should not be publicly accessible. This switches from public to private blob storage and adds a delivery route that checks the user's session before serving files.

Changes:

  • Upload: access: "public" -> access: "private", returns /api/files/serve?pathname=... instead of raw blob URL
  • New /api/files/serve route: checks auth, streams private blob with ETag caching support
  • Removed *.public.blob.vercel-storage.com from next.config.ts image patterns (no longer needed)

No client changes needed — the upload response interface ({ url, pathname, contentType }) is preserved, and next/image works with same-origin URLs without remotePatterns.

Context

Aligns with the private-by-default direction for Vercel Blob (see vercel/front#65379, vercel/vercel#15375). The CLI now defaults to private-first prompts and requires explicit --access flags.

🤖 Generated with Claude Code

User-uploaded images are auth-gated content that should not be publicly
accessible. This switches from public to private blob storage and adds a
delivery route that checks the user's session before serving files.

Changes:
- Upload route: access: 'public' -> 'private', returns delivery route URL
- New /api/files/serve route: auth-gated, streams private blobs with ETag support
- next.config.ts: remove public blob domain from remotePatterns
@vercel
Copy link
Copy Markdown
Contributor

vercel Bot commented Apr 13, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
ai-chatbot Error Error Apr 13, 2026 3:26pm
chatbot Error Error Apr 13, 2026 3:26pm

Request Review

@vvo
Copy link
Copy Markdown
Member Author

vvo commented Apr 13, 2026

Reopening with branch name without slashes

@vvo vvo closed this Apr 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant