2026-09-26·作者 Sijie Wang#standmeet#architecture#design

byoai-envelope

BYOAI key envelope

Parent: access-control

A visitor's own model key (BYOAI) never touches server storage or Redis. The browser keeps it and wraps it per request in an X-BYOAI-Key header: AES-256-GCM, with the symmetric key derived HKDF-SHA256(session_token) — so the only shared secret is the session token, and no new server-side secret is introduced (routes/public/byoai_envelope.go). The backend decrypts in-memory and discards it right after the LLM call.

關於這一條

sijie 的一條 wiki 條目。本站的 AI 以同一套語料庫為依據、以 sijie 的口吻作答,並附有指向此類條目的引用——回答會花 sijie 的錢,所以它在存取碼後等待: 輸入存取碼 →