Skip to content

v0.18.0: This release introduces two new credentials in zkgroup,

Compare
Choose a tag to compare
@github-actions github-actions released this 22 Jun 23:02
· 1103 commits to main since this release
ExpiringProfileKeyCredential and AuthCredentialWithPni. Both
credentials have presentations usable with the existing
ProfileKeyPresentation and AuthCredentialPresentation variant types,
respectively. There have been some corresponding changes to existing
APIs:

- zkgroup's RedemptionTime type has been renamed to
  CoarseRedemptionTime, and ReceiptExpirationTime to plain Timestamp.
  These fields were previously treated opaquely, but are now expected
  to be days and seconds since the Unix epoch, respectively. (This
  matches how they're used in Signal.)

- Node: ReceiptCredential.getReceiptExpirationTime() and
  ReceiptCredentialPresentation.getReceiptExpirationTime() now return
  a number rather than a bigint, since any valid expiration time fits
  within MAX_SAFE_INTEGER.

- AuthCredentialPresentation.getRedemptionTime() now returns
  Instant (Java), Date (Swift), Date (TypeScript), or
  zkgroup::Timestamp (Rust). Previously it returned a 32-bit integer.
  Likewise, verifyAuthCredentialPresentation() now takes an
  Instant/Date/Date/Timestamp to represent the current time.

- AuthCredentialPresentation.getPniCiphertext() has been added,
  returning null for older credential versions.

- verifyProfileKeyCredentialPresentation() now takes an
  Instant (Java), Date (Swift), Date (TypeScript), or
  zkgroup::Timestamp (Rust) representing the current time. This is an
  optional parameter in every language but Rust; if omitted, the
  current time will be used.

- getStructurallyValidV1PresentationBytes() has been added to
  ProfileKeyCredentialPresentation to smooth over a use case where
  presentations are read by other clients and not just the server.

- The server "zkgroup parameters" have grown and will need updating.
  The new parameters are backwards-compatible with the old parameters
  as long as the values for existing keys are not changed.

Other changes:

- The 'needsPniSignature' field in SessionRecords has been removed.

- Node: zkgroup "ByteArray" types are now correctly distinguished by
  the TypeScript compiler instead of being treated as interchangeable.