feat(#175): opaque base64url share fragment (no raw key in URL) + Referrer-Policy no-referrer #189
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "fix-frag"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Implements the researched, security-first recommendation for the share-link key exposure.
Research (Bitwarden Send, Mega, PrivateBin all converge): the key belongs in the URL fragment — never sent to the server, the correct zero-knowledge design — but encoded as an opaque token, never a labelled secret. PrivateBin moved off base64 padding because mail/chat clients mangle trailing
=.Change:
base64url(no padding, URL-safe) of the age identity, not the rawAGE-SECRET-KEY-1…. Same crypto, same fragment mechanism — the URL just stops exposing a scary secret string. Since the UI displaysshare.url, this fixes the display everywhere for free.Referrer-Policy: no-referreron the public/s/surface (+ meta tag) — the one genuine leak vector the research surfaced: a fragment isn't sent to servers, but the whole URL can leak to third parties via theRefererheader.Chose base64url-of-identity over re-deriving raw key bytes deliberately: identical security, no hand-rolled bech32 in the crypto path. Three tests (round trip, legacy passthrough, garbage inert); go test share+api + build green. CHANGELOG v0.6.6. Password mode remains the two-channel option in the dialog.