Commit graph

313 commits

Author SHA1 Message Date
Matthew Chen
db3df249bf Merge NSData categories. 2018-08-09 13:50:55 -04:00
Jesse Squires
6dc74ddcaf Fix some project warnings + other fixes
- Prefer checking `.isEmpty` rather than `.count == 0` for Swift collections (can be more optimal)
- Avoid comparing `BOOL` explicitly to `NO` (considered bad practice since `BOOL` is a `signed char`)
- Specify unused `SGX_FLAGS` as `__unused` to silence warnings
2018-07-31 09:48:58 -06:00
Matthew Chen
4a4edc68e7 Clean up data. 2018-07-26 17:20:11 -06:00
Michael Kirk
54afa2163e rename token -> password 2018-07-26 14:54:39 -04:00
Matthew Chen
8c4b34aa55 Revert "rename token -> password"
This reverts commit c96d219c942a86fc84cbd1ce22835a83ce9187c9.
2018-07-26 14:48:27 -04:00
Matthew Chen
8e18f40572 Respond to CR. 2018-07-26 14:48:27 -04:00
Matthew Chen
3cac5bbfee Respond to CR. 2018-07-26 14:48:27 -04:00
Matthew Chen
8d1011a1fc Verify certificate subject. 2018-07-26 14:48:27 -04:00
Matthew Chen
aef881cad3 Verify certificate subject. 2018-07-26 14:48:27 -04:00
Michael Kirk
5e2dc18931 rename token -> password 2018-07-26 11:58:26 -06:00
Michael Kirk
6d46ed0e3f No change in behavior: move class down 2018-07-26 11:55:00 -06:00
Michael Kirk
2e38fa145c Unbatch legacy contact requests
// FREEBIE
2018-07-26 11:55:00 -06:00
Matthew Chen
0518b335d8 Refine recipient device updates. 2018-07-26 09:22:40 -04:00
Michael Kirk
bae2e8649d Dry up Parameter parsing logic 2018-07-25 15:35:30 -06:00
Michael Kirk
f002f89f2c Update retryable
Per Jeff, don't handle CDS requests yet.
2018-07-24 10:13:37 -06:00
Michael Kirk
3507367a90 Don't report feedback for HTTP errors.
// FREEBIE
2018-07-24 10:03:47 -06:00
Matthew Chen
5530b8d701 Respond to CR. 2018-07-23 17:13:01 -04:00
Matthew Chen
7a898f5e99 Fix NPE using mock for unknown database objects. 2018-07-23 16:53:02 -04:00
Matthew Chen
2c973782c4 Fix NPE using mock for unknown database objects. 2018-07-23 16:52:00 -04:00
Matthew Chen
723691400f Fix NPE using mock for unknown database objects. 2018-07-23 16:50:12 -04:00
Michael Kirk
558b3bd245 Report contact discovery feedback 2018-07-23 13:06:40 -06:00
Michael Kirk
b42f528713 Integrate with new contact discovery endpoint
Also:
* use system cookie parsing
* add AESGCM additional authenticated data parameter

// FREEBIE
2018-07-23 12:21:54 -06:00
Michael Kirk
a611625691 fixup lookup threading 2018-07-23 12:20:35 -06:00
Michael Kirk
dedfea78da callback handlers for remote attestation 2018-07-23 12:20:35 -06:00
Matthew Chen
28f021ba55 Pull byte parser out into separate source file. 2018-07-23 14:00:17 -04:00
Matthew Chen
906d0b01a4 Fix build break. 2018-07-23 13:47:03 -04:00
Matthew Chen
304240f263 Fix concurrency in contacts updater. 2018-07-23 13:26:19 -04:00
Matthew Chen
9904443fcf Fix concurrency in contacts updater. 2018-07-23 13:26:19 -04:00
Matthew Chen
797bd9be38 Respond to CR. 2018-07-23 12:59:55 -04:00
Matthew Chen
81a940a27f Clean up ahead of CR. 2018-07-23 12:59:55 -04:00
Matthew Chen
7acf9b15e1 Finish signature verification. 2018-07-23 12:59:55 -04:00
Matthew Chen
7476ef123d Remote attestation. 2018-07-23 12:59:55 -04:00
Michael Kirk
ab1190222b Fix overzealous failure when user has no Signal contacts
// FREEBIE
2018-07-20 09:55:40 -06:00
Matthew Chen
75c3b385b2 Respond to CR. 2018-07-20 10:32:15 -04:00
Matthew Chen
f2fdb96931 Clean up ahead of PR. 2018-07-20 09:56:37 -04:00
Matthew Chen
460f7344ad Remote attestation. 2018-07-20 09:55:18 -04:00
Matthew Chen
6686ecb125 Remote attestation. 2018-07-20 09:55:17 -04:00
Matthew Chen
d7bb2b7505 Remote attestation. 2018-07-20 09:55:17 -04:00
Matthew Chen
f3ba6d4c27 Remote attestation. 2018-07-20 09:55:17 -04:00
Michael Kirk
eb4c62593b Cancel quickly if dependent operation fails 2018-07-19 13:40:30 -06:00
Michael Kirk
90214ae578 make contact intersection queue serial 2018-07-19 13:40:30 -06:00
Michael Kirk
0db339b849 fixup double failure 2018-07-19 13:40:30 -06:00
Michael Kirk
9293eb96f7 code re-org 2018-07-19 13:40:30 -06:00
Michael Kirk
75248b5dc7 Stub out feedback operation
// FREEBIE
2018-07-19 13:40:30 -06:00
Michael Kirk
b7288b2565 Move contact intersection into batched operation
// FREEBIE
2018-07-19 13:40:30 -06:00
Matthew Chen
39c7fd9f15 Respond to CR. 2018-07-19 11:31:04 -04:00
Matthew Chen
3aa28aee36 Respond to CR. 2018-07-18 15:09:29 -04:00
Matthew Chen
03e5d2973b Delta contact intersections. 2018-07-18 14:27:40 -04:00
Matthew Chen
899e96f70f Respond to CR. 2018-07-18 14:25:30 -04:00
Matthew Chen
cc91cb3dbf Respond to CR. 2018-07-18 13:57:22 -04:00
Matthew Chen
ace07ac62a Respond to CR. 2018-07-18 13:57:22 -04:00
Matthew Chen
c830f880aa Streamline SignalRecipient. 2018-07-18 13:57:22 -04:00
Matthew Chen
77884913d8 Streamline SignalRecipient. 2018-07-18 13:57:22 -04:00
Matthew Chen
b6489c6948 Streamline SignalRecipient. 2018-07-18 13:57:22 -04:00
Matthew Chen
05a4222b2d Streamline SignalRecipient. 2018-07-18 13:57:22 -04:00
Matthew Chen
ef3933bfaa Streamline SignalRecipient. 2018-07-18 13:57:21 -04:00
Matthew Chen
10b21d10e4 Streamline SignalRecipient. 2018-07-18 13:57:21 -04:00
Matthew Chen
9618fc16c5 Streamline SignalRecipient. 2018-07-18 13:57:21 -04:00
Matthew Chen
d14f764b50 Streamline SignalRecipient. 2018-07-18 13:57:21 -04:00
Michael Kirk
872c89fbff Update recipient devices on successful decrypt to avoid wasting a valid session
created by sender.

Make device set immutable.
2018-07-13 10:04:54 -06:00
Michael Kirk
a66c88e3cf Fix getter for contact threads, remove sneaky read transaction for DM config. 2018-07-10 13:25:38 -06:00
Michael Kirk
92705490a0 No write transaction needed for syncing colors
// FREEBIE
2018-07-10 13:25:38 -06:00
Matthew Chen
03d393553a Tweak home view cells. 2018-07-10 09:28:11 -04:00
Michael Kirk
16df4f589e conversation colors
// FREEBIE
2018-06-29 11:52:41 -06:00
Matthew Chen
ebcc435c9f Clean up ahead of PR. 2018-06-20 17:55:15 -04:00
Matthew Chen
87ea1dcae1 Clean up ahead of PR. 2018-06-20 17:55:15 -04:00
Matthew Chen
08ca4fdb50 Lazy-load contact avatar data and images. Use NSCache for avatar images. 2018-06-20 17:55:14 -04:00
Matthew Chen
83f11ad79b Don't cache CNContact. 2018-06-20 17:55:14 -04:00
Matthew Chen
12295bd8c5 Don't cache CNContact. 2018-06-20 17:55:14 -04:00
Michael Kirk
0cf751d34f Newly added group members should have expire time
Send expire timer with group info updates and in group updates that add a user.
2018-06-14 15:20:45 -04:00
Michael Kirk
74b741e9de Update timer
// FREEBIE
2018-06-14 15:18:42 -04:00
Michael Kirk
f57a5dbc77 Match searches for national number format
// FREEBIE
2018-06-12 15:27:13 -04:00
Matthew Chen
9a08afae28 Fix build warnings. 2018-06-01 12:39:13 -04:00
Matthew Chen
caad6f796e Clean up ahead of PR. 2018-05-30 15:05:02 -04:00
Matthew Chen
e2d9c1187a Fix "group avatar doesn't update after local change." 2018-05-18 15:37:38 -04:00
Michael Kirk
af8ddf7bf0 Use raw text when localization fails
// FREEBIE
2018-05-17 09:59:07 -04:00
Matthew Chen
5c7b98e5c4 Improve handling of unregistered users. 2018-05-14 16:45:06 -04:00
Matthew Chen
8cdb75d52a Respond to CR. 2018-05-10 13:38:39 -04:00
Matthew Chen
8337c3bd68 Refine contact merging. 2018-05-10 13:36:38 -04:00
Michael Kirk
a16040f19f Fix avatar sending in SAE
// FREEBIE
2018-05-10 11:35:42 -04:00
Michael Kirk
c15fea4eca merge avatar with existing
// FREEBIE
2018-05-10 11:31:22 -04:00
Michael Kirk
bf37f41164 Move CNContact logic into our system contact adapter
// FREEBIE
2018-05-10 11:31:22 -04:00
Matthew Chen
44ceee5849 Add contact share actions to conversation view and improve phone number parsing. 2018-05-08 17:22:34 -04:00
Michael Kirk
98aa054496 Avoid spurious "Disabled Disappearing Messages"
`dictionaryDidChange` was always true for new records.

// FREEBIE
2018-05-08 10:19:33 -04:00
Michael Kirk
a10ae1835e respond to code review
// FREEBIE
2018-05-07 12:51:55 -04:00
Michael Kirk
77fc5571fb Implement avatar sending
// FREEBIE
2018-05-07 12:08:41 -04:00
Michael Kirk
3fdf703a60 PhoneNumberUtil is no longer a singleton
// FREEBIE
2018-05-07 12:07:03 -04:00
Matthew Chen
4b6239f491 Fix build breakage. 2018-05-07 10:06:59 -04:00
Matthew Chen
043218fb91 Ensure thread safety in phone parsing logic. 2018-05-07 09:49:19 -04:00
Matthew Chen
0c745dd989 Add contact share approval view. 2018-05-04 18:13:22 -04:00
Matthew Chen
1fc401d200 Respond to CR. 2018-05-04 13:34:11 -04:00
Matthew Chen
1a1a043b27 Format phone numbers of contacts. 2018-05-04 13:21:53 -04:00
Matthew Chen
bb96454070 More outgoing message fixes. 2018-04-30 11:00:57 -04:00
Michael Kirk
7a1d24a9ab Avatar updates when contact/profile/group photo changes
// FREEBIE
2018-04-26 11:18:18 -04:00
Matthew Chen
fa9a4c808a Simplify usage of contacts framework. 2018-04-24 13:21:12 -04:00
Michael Kirk
1f63ce02a0 Increase cache, remove dead code, add debug logging
// FREEBIE
2018-04-21 20:00:57 -04:00
Michael Kirk
5f2b38c50b Introduce Thread view model
// FREEBIE
2018-04-21 19:21:18 -04:00
Michael Kirk
1fb1b5bbe2 WIP unjank home screen
verify `description` isn't used elsewhere (notifications? conversation
view?)

Probably want to remove overzealous asserts for now, but would be good
to work towards leaving them enabled.

// FREEBIE
2018-04-21 19:21:18 -04:00
Michael Kirk
754549adf1 Start timer for expiring message based on when read receipt was sent
// FREEBIE
2018-04-18 15:32:01 -04:00
Michael Kirk
dfb2a034af Use explicit transactions.
- Start expiration within scope of existing transaction when we're
  already in a transaction

// FREEBIE
2018-04-18 15:32:01 -04:00
Michael Kirk
e554884ab3 Use profile name in quoted messages, fix "multi account" label
// FREEBIE
2018-04-13 09:53:31 -04:00
Matthew Chen
4a4e9d1ce2 Bubble collapse. 2018-04-02 10:07:15 -04:00
Michael Kirk
394cc6637c Backport comments from translations
// FREEBIE
2018-03-26 10:12:04 -04:00
Matthew Chen
bb596dba98 Add screen lock feature. 2018-03-22 15:49:57 -04:00
Matthew Chen
8d689ec090 Properly cleanup content. 2018-03-22 09:34:47 -04:00
Matthew Chen
d6f4db1523 Rename TSStorageManager to OWSPrimaryStorage. 2018-03-06 17:12:13 -03:00
Matthew Chen
004479a2ce Elaborate request factory. 2018-03-02 15:05:14 -05:00
Matthew Chen
d648a258d1 Merge branch 'hotfix/2.19.7' 2018-02-16 10:49:52 -05:00
Matthew Chen
abfd333a17 Address Indic script crash. 2018-02-16 10:19:47 -05:00
Matthew Chen
4b62faf2f8 Aggressively nag iOS 8 users to upgrade iOS. 2018-02-14 14:15:23 -05:00
Michael Kirk
a23f1b86ef nullability annotations for TSGroupModel
- add readonly where possible
- group members needn't be a mutable array

// FREEBIE
2018-02-13 09:50:01 -08:00
Matthew Chen
862172072c Respond to CR. 2018-02-09 10:31:29 -05:00
Matthew Chen
bbd689bfd0 Add protocol context to protocol kit. 2018-02-09 10:31:29 -05:00
Matthew Chen
074046b98e Add protocol context to protocol kit. 2018-02-09 10:31:29 -05:00
Matthew Chen
218bb15ea7 Add protocol context to protocol kit. 2018-02-09 10:31:29 -05:00
Matthew Chen
799949e546 Refine sync messages. 2018-02-02 10:56:16 -05:00
Matthew Chen
43ed8d9a5d Send "disappearing messages" state for groups. 2018-02-02 10:42:56 -05:00
Matthew Chen
742d4cabc2 Send "disappearing messages" state for contacts. 2018-02-02 10:42:56 -05:00
Matthew Chen
eb180ba5c4 Register all database views asynchronously. 2018-01-30 10:30:28 -05:00
Michael Kirk
baa312f449 Timer button with duration label
// FREEBIE
2018-01-22 10:28:51 -05:00
Matthew Chen
245304116f Respond to CR. 2017-12-20 11:19:09 -05:00
Matthew Chen
d52eba739d Clean up TSStorageManager usage. 2017-12-19 11:41:31 -05:00
Matthew Chen
85686d3144 Continue TSStorageManager refactor. 2017-12-19 11:41:30 -05:00
Matthew Chen
9a990b58e8 Respond to CR. 2017-12-19 11:38:25 -05:00
Matthew Chen
9815bca825 Clean up ahead of PR. 2017-12-19 11:16:01 -05:00
Matthew Chen
a29c4ce5d6 Pull out OWSStorage base class for TSStorageManager. 2017-12-19 11:16:01 -05:00
Michael Kirk
157bf00410 Merge branch 'hotfix/2.19.3' 2017-12-17 14:02:03 -05:00
Michael Kirk
e78edcde87 Only clear cache when user pulls-to-refresh
// FREEBIE
2017-12-16 12:01:19 -05:00
Michael Kirk
f4e471e0db SignalAccount cache perf improvments
- only persist models that have changed
- remove duplicate contact SignalAccounts
- ensure serial execution of buildAccounts
- only buildSignalAccounts when intersection succeeds

// FREEBIE
2017-12-15 16:18:36 -05:00
Michael Kirk
16448e2a0b Merge tag '2.19.3.0' 2017-12-14 11:42:57 -05:00
Michael Kirk
64e90d29fd CR: extract method, more asserts and annotations
// FREEBIE
2017-12-14 10:52:04 -05:00
Michael Kirk
336c92ddab remove cached display name machinery, cleanup
// FREEBIE
2017-12-13 17:31:36 -05:00
Michael Kirk
7ea4b85a2a Persist signal accounts (and their embedded Contact)
// FREEBIE
2017-12-13 17:31:36 -05:00
Michael Kirk
a58f1f385c Share a photo from photos app
Shows the conversation picker, and sends the attachment to that
conversation.

There's still a lot TODO

-[ ] resolve JSQ dependency
-[ ] properly wait for app to load
-[ ] dismiss share extension after send is complete
-[ ] support non jpeg file types
-[ ] Fix device sleep manager

// FREEBIE
2017-12-07 10:13:06 -05:00
Matthew Chen
9da165b846 Continue conversion of app setup. 2017-12-05 11:19:11 -05:00
Michael Kirk
f96b7bc27c CNContact doesn't exist before iOS9
// FREEBIE
2017-12-04 12:50:28 -05:00
Michael Kirk
a11d83187b WIP: Framework-friendly - compiles but crashes on launch
// FREEBIE
2017-11-29 13:58:27 -08:00
Matthew Chen
9b4ac4073f Improve robustness around unknown country codes. 2017-11-21 17:48:00 -05:00
Matthew Chen
00feb14b10 Respond to CR.
// FREEBIE
2017-11-15 13:15:48 -05:00
Matthew Chen
5eea0347b5 Rework the "update with..." methods to avoid re-saving deleted models. 2017-11-15 07:16:12 -05:00
Matthew Chen
c6160a5a1e Rework the "update with..." methods to avoid re-saving deleted models. 2017-11-15 07:16:12 -05:00
Matthew Chen
8b65246619 Respond to CR.
// FREEBIE
2017-11-10 12:57:16 -05:00
Matthew Chen
6e840ff956 Fix build warnings from XCode 9. 2017-11-09 02:52:44 -05:00
Michael Kirk
68e755ade9 Merge branch 'release/2.18.0' 2017-10-20 16:10:07 -07:00
Michael Kirk
0cd56d4bcc On iOS11 doc picker requires system appearance.
Otherwise nav items are illegible.

// FREEBIE
2017-10-20 12:35:21 -07:00
Matthew Chen
227fd5280d Resize conversation view cells as necessary.
// FREEBIE
2017-10-16 20:41:14 -07:00
Matthew Chen
380ed0f82b Create & access groups more carefully.
// FREEBIE
2017-10-04 09:45:09 -04:00
Matthew Chen
6fce2c26b7 Process messages in a single transaction (wherever possible).
// FREEBIE
2017-09-20 09:40:46 -04:00
Matthew Chen
8a4d67a6e4 Respond to CR.
// FREEBIE
2017-09-20 09:19:15 -04:00
Michael Kirk
2eaaba9082 crashfix: on addObject, presumably it's nil.
I'm not sure how this is happening, but this will prevent the crash and
give us additional diagnostic data in the cases where it is happening.

// FREEBIE
2017-09-01 12:56:50 -04:00
Matthew Chen
a825fad47b Start reworking the contact offers.
// FREEBIE
2017-08-21 17:05:42 -04:00
Michael Kirk
935b51aa19 Fixup tests
// FREEBIE
2017-08-03 13:27:09 -04:00
Michael Kirk
8a4712bf4c Only access localNumber on AccountManager and cache it
// FREEBIE
2017-08-03 13:27:09 -04:00
Matthew Chen
6f03c2d92f Don’t hide threads if they are a group thread, or if they have _ever_ had a message.
// FREEBIE
2017-08-02 15:12:42 -04:00
Matthew Chen
e16d0e326b Avoid crash when deleting threads - and improve perf.
// FREEBIE
2017-07-27 13:02:42 -04:00
Matthew Chen
f1807cd709 Add script to extract and gather analytics event names.
// FREEBIE
2017-07-27 12:29:05 -04:00
Matthew Chen
f973af5a83 Streamline analytics properties.
// FREEBIE
2017-07-27 10:16:16 -04:00
Matthew Chen
b17a7c5751 Review NSError usage.
// FREEBIE
2017-07-24 16:13:59 -04:00
Matthew Chen
9587aab37b Instrument network errors.
// FREEBIE
2017-07-24 16:05:39 -04:00
Matthew Chen
c8b2e22a3b [SSK] Migrating changes from obsolete SSK repo.
// FREEBIE
2017-07-21 15:22:28 -04:00
Matthew Chen
64a99c63b3 [SSK] Migrating changes from obsolete SSK repo.
// FREEBIE
2017-07-21 15:08:37 -04:00
Matthew Chen
4f5b2993b0 [SSK] Migrating changes from obsolete SSK repo.
// FREEBIE
2017-07-21 14:55:31 -04:00
Michael Kirk
ccb4a88742 Import SSK (and history) into Signal-iOS
git remote add ssk ../SignalServiceKit
git remote update
git merge -s ours --allow-unrelated-histories --no-commit ssk/master
git read-tree --prefix=SignalServiceKit -u ssk/master
git commit
2017-07-21 13:55:01 -04:00