Support the "temporary item sharing" flow of the Bitwarden clients
(bitwarden/clients #23060, #23079, #23152), which shares a whole vault
item through a Send link and requires the recipient to verify an email
address with a one-time code.
Since SDK 0.2.0-main.1075 (browser and desktop 2026.10.0) the clients seal
the item in the Send and send its id in clear in metadata.itemId, which is
required (bitwarden/sdk-internal#1539, bitwarden/server#8485).
- SendType::Item (2): store only {encryptionVersion, data} and
metadata.itemId, capped at 500 kB; the item stays encrypted
client-side with the Send key. Item Sends without metadata.itemId are
rejected ("Metadata is required for item sends.").
- When the item is new or changes, the owner of the Send must be able to
share it: own item, or an organization item they can edit with
passwords visible; not deleted, not archived, not an SSH key. Missing
and forbidden items get the same "Item not found.".
- Item Sends in the earlier format, which no current client decrypts, are
left out of sync, list and get and refused at the access token. They
are not deleted; the regular purge removes them.
- Email verification without a schema change: the allowed addresses
live in the existing `sends.data` JSON (`vwAuthEmails`, stripped from
every response) and the one-time code lives in memory
(EMAIL_TOKEN_SIZE digits, valid for EMAIL_EXPIRATION_TIME, single use,
30 s resend cooldown, burned after EMAIL_ATTEMPTS_LIMIT wrong tries;
a burned code keeps the cooldown).
- Unknown addresses get the same response as allowed ones and no mail
is sent. The code is mailed in the background, so neither the timing
nor a mail server failure tells the two apart; failures are logged.
- `authType` and `emails` in the Send JSON; put_send and create_send
accept `emails` and `authType` instead of rejecting them. Keeping the
current recipients doesn't need mail, so a key rotation can't fail
halfway because email was switched off after the Send was created.
- The legacy /sends/access endpoints refuse email-protected Sends, so
older clients cannot skip the code.
- The two client feature flags (pm-34203-temporary-item-sharing,
pm-30110-sdk-sends-api) are only advertised to clients at or above
ITEM_SHARING_MIN_CLIENT_VERSION (default 2026.10.0), and Item Sends
are hidden from sync/list/get for Android and iOS (the Android app
has no fallback for unknown Send types and would fail the whole sync)
and for clients below that version.
- Each successful access logs "Send <id> opened by <email> from <ip>".
- MaybeClientVersion guard for /api/config, so requests without the
Bitwarden-Client-Version header no longer log an error.