Back

BriefBox - Temporary Email Service

Overview

Anonymous disposable email service with one-hour self-destructing inboxes. Generates real addresses on a custom domain, receives inbound mail through Cloudflare Email Routing, scans messages for phishing signals, and stores everything in Redis only — no accounts, no permanent database.

Features

01

No signup / no login; Only cookie-based anonymous sessions only

02

One temporary email address per browser session

03

Exact 1-hour lifetime with live countdown timer

04

Automatic cleanup via Redis TTL for sessions and messages

05

Real inbound email on a custom domain via Cloudflare Email Routing catch-all

06

Cloudflare Email Worker forwards raw MIME to the Fastify webhook

07

MIME parsing with mailparser for subject, text, HTML, and links

08

Local rule-based safety scoring: Safe / Warning / Dangerous badges

09

Phishing heuristics for scam phrases, shady TLDs, IP links, shorteners, and brand mismatch

10

Sanitized HTML rendering in the inbox (DOMPurify)

11

Copy-to-clipboard for the temporary address

12

Inbox refresh via React Router revalidation

13

Rate limiting, helmet, CORS, and webhook shared-secret protection

14

PNPM + Turborepo monorepo with separate web and backend apps

15

Dockerfiles for web and backend production builds

Built with

React Router FrameworkTypeScriptFastifyRedisTailwind CSSshadcn/uiCloudflare Email RoutingCloudflare WorkersDockerTurborepopnpm

Challenges & Solutions

Problem

Getting real mail into disposable addresses required more than a webhook endpoint

Solution

Configured Cloudflare nameservers, Email Routing, catch-all rules, and an Email Worker that POSTs raw messages to the backend with a shared webhook secret.

Problem

Early safety rules flagged normal product emails like “verify your email” as risky

Solution

Separated weak auth language from strong scam phrases, limited brand-mismatch penalties to credential-style links, and required shady link context before raising scores.

Problem

Needed ephemeral storage without building a full user/database model

Solution

Designed Redis-only keys for sessions, email-to-session reverse lookup, and per-message records, all with matching TTLs so data disappears with the inbox.

Problem

Session cookies created during loader requests were not reaching the browser

Solution

Captured Set-Cookie headers from API responses in the server-side client and forwarded them through the React Router loader response.

GitHub