1. paste something
2. retrieve a paste
what just happened on the server
- POST: per-request
96-bit IV→ AES-256-GCM encrypt →zlib.gzipSynccompress →fs.writeFileSync - POST: ECDSA P-256 sign over
{ id, exp }→ ES256 JWT bearer - GET:
crypto.verify("sha256", ..., pubKey, sig)→zlib.gunzipSync→ AES-256-GCM decrypt with auth-tag check - If the auth tag doesn't match (bit-flip / tampering), GCM
final()throws and the server returns 500