Skip to content

Variable: PUSH_PAYLOAD_VERSION ​

ts
const PUSH_PAYLOAD_VERSION: 1 = 1;

Defined in: pushCrypto.ts:20

End-to-end encryption for push notifications.

Each phone makes a secret when it registers and gives it to its instance. The backend seals every notification for that phone with it (AES-256-GCM), and the phone opens it to build what it shows. The relay, Google and Apple carry only ciphertext.

The wire format is base64url(nonce ‖ ciphertext ‖ tag), which is also CryptoKit's AES.GCM.SealedBox.combined: the iOS notification service extension opens it natively. Pure JavaScript, so the same code runs in the backend and in the app's background task.

Released under the GNU Affero General Public License v3.0.