Commit Graph

19 Commits

Author SHA1 Message Date
Matthew Chen ebae75af00 Revert 'new sort id'. 2018-09-27 19:40:51 -04:00
Michael Kirk df61316495 minimize diff senderTimestamp -> timestamp 2018-09-26 09:52:33 -06:00
Michael Kirk eef1368ad3 Timestamp audit step1: change signature
There is no change in functionality in this commit.

Apart from clarifying what the timestamp means (it's the timestamp of the
*sender*), this intentionally breaks all the call sites, so I could have a sane
way to thoroughly audit wherever we're passing in timestamps, to see where
we're depending on them to affect sort order.

For the sake of a cleaner diff of meaningful changes, instead of "fixing"
everything in this commit, I've just added comments and renamed signatures.
2018-09-26 09:52:33 -06:00
Matthew Chen cf6f3841a8 Apply new Swift logging. 2018-08-27 10:02:28 -04:00
Matthew Chen 26001e49d1 Unify log tags. 2018-08-15 10:24:29 -04:00
Matthew Chen 4d8c764789 Migrate to Swift 4. 2018-05-30 15:05:02 -04:00
Matthew Chen b2b62880c0 Migrate to Swift 4. 2018-05-30 15:05:02 -04:00
Matthew Chen d6f4db1523 Rename TSStorageManager to OWSPrimaryStorage. 2018-03-06 17:12:13 -03:00
Matthew Chen 6b357f9445 Respond to CR. 2018-02-09 10:31:29 -05:00
Matthew Chen d3e16583eb Add protocol context to protocol kit. 2018-02-09 10:31:29 -05:00
Michael Kirk a11d83187b WIP: Framework-friendly - compiles but crashes on launch
// FREEBIE
2017-11-29 13:58:27 -08:00
Michael Kirk 43092ee6ac CR: be extra paranoid about archiving the reset session
// FREEBIE
2017-11-22 11:44:35 -08:00
Michael Kirk 47926418b5 Prevent subsequent "No valid session" errors from the recipient of an
EndSession message.

// FREEBIE
2017-11-22 11:15:26 -08:00
Matthew Chen c6160a5a1e Rework the "update with..." methods to avoid re-saving deleted models. 2017-11-15 07:16:12 -05:00
Michael Kirk 6ba5e5cc6b Clean up session-reset logging
// FREEBIE
2017-04-07 10:19:40 -04:00
Michael Kirk d8ae941736 Delete session *before* sending EndSession message
Typically we're sending an EndSession message because our session has
diverged from the remote party's session. So if we send an EndSession
message, but decrypt it with our old out-of-sync session, how can we
expect them to be able to decrypt it?

Instead, by deleting the existing sessions, we'll fetch a new PreKey,
and start fresh with the remote side.

// FREEBIE
2017-04-06 21:09:56 -04:00
Michael Kirk 033591aeca Remove unused code
// FREEBIE
2017-04-06 21:09:56 -04:00
Michael Kirk 28a2a4610c Fix compiler warnings.
// FREEBIE
2016-11-11 08:54:13 -05:00
Michael Kirk c6a2fbff23 Tapping corrupted message opens "session reset" activity
This action was previously hidden under a secret longpress gesture in
the fingerprint view controller.

Ideally we'd never receive corrupted messages, but at the point we do,
our sessions are out of whack, and the only recovery option is to reset.
Let's help our users do that.

* Resetting session sends END_SESSION message

  Otherwise the remote side wouldn't know we reset the session and will
  send us a message on the old ratchet.

* Don't reset their identity key when resetting sender ratchet.

* Updated translations

// FREEBIE
2016-11-04 14:57:37 -04:00