Commit graph

258 commits

Author SHA1 Message Date
Matthew Chen 2d6d375e82 Add screen lock feature. 2018-03-22 15:49:31 -04:00
Matthew Chen 1612642c26 Add screen lock feature. 2018-03-22 15:49:31 -04:00
Matthew Chen 08ba7c85ed Clean up ahead of PR. 2018-03-20 11:23:56 -04:00
Michael Kirk 267e85915a Avoid overflow
// FREEBIE
2018-03-20 11:19:07 -04:00
Michael Kirk d9a2effff6 CR: remove "k" from non constant
// FREEBIE
2018-03-20 11:15:09 -04:00
Matthew Chen cf13a780e9 Retry backup failures. 2018-03-17 09:18:01 -03:00
Matthew Chen 4746948dfe Respond to CR. 2018-03-14 10:02:44 -03:00
Matthew Chen 68ba8976c5 Clean up ahead of PR. 2018-03-14 09:27:39 -03:00
Matthew Chen 76b4deffe4 Respond to CR. 2018-03-14 09:27:39 -03:00
Matthew Chen 5035cb040e Implement backup import logic. 2018-03-14 09:27:39 -03:00
Matthew Chen aa546a02df Merge remote-tracking branch 'origin/release/2.22.0' 2018-03-14 09:19:15 -03:00
Matthew Chen c1169ce240 Fix typo in background task. 2018-03-13 15:09:06 -04:00
Matthew Chen 0971bad4b2 Upload database and manifest files to CloudKit. 2018-03-12 16:40:07 -03:00
Matthew Chen c84bf81cf3 Export database for backup. 2018-03-12 16:40:07 -03:00
Michael Kirk a885fb5dee Fix first reminder too early, offset bugs.
Schedule first reminder date relative to now, handle overflow

// FREEBIE
2018-03-07 10:58:33 -05:00
Michael Kirk a1de99f1f1 Merge tag '2.21.0.9' 2018-03-06 16:43:33 -05:00
Michael Kirk 39b87b702b Fix debuglogs.org integration
// FREEBIE
2018-03-06 16:07:08 -05:00
Matthew Chen d6f4db1523 Rename TSStorageManager to OWSPrimaryStorage. 2018-03-06 17:12:13 -03:00
Matthew Chen 3435be5aba Preserve registration lock when updating account attributes. 2018-03-05 18:25:23 -03:00
Matthew Chen 0f7b852953 Persist registration lock PIN. 2018-03-05 18:25:23 -03:00
Matthew Chen 2d6b9a7c81 Respond to CR. 2018-03-05 17:08:58 -03:00
Matthew Chen 9db9409561 Share background tasks. 2018-03-05 17:08:58 -03:00
Michael Kirk 1d3831eccd Registration Lock reminder view
Also fixed: Don't lose PIN across registrations

// FREEBIE
2018-03-05 09:53:09 -05:00
Michael Kirk 1ff2f3f42e Merge tag '2.21.0.1' 2018-03-02 18:35:01 -05:00
Matthew Chen 4bbf0d9e3d Integrate with logs service. 2018-03-02 17:44:14 -05:00
Matthew Chen 59c745756a Clean up codebase. 2018-03-02 15:05:14 -05:00
Matthew Chen baf6fcc535 Add 2FA registration view. 2018-03-02 10:55:00 -05:00
Matthew Chen 055061ff5e Clean up ahead of PR. 2018-03-01 15:38:59 -05:00
Matthew Chen e12a1e984a Work on two-factor auth settings UI. 2018-03-01 15:38:59 -05:00
Matthew Chen 1f6cbd399e Sketch out 2FA feature. 2018-03-01 15:38:59 -05:00
Matthew Chen bf48ccd4ad Merge remote-tracking branch 'origin/hotfix/2.20.1' 2018-02-27 15:45:17 -05:00
Matthew Chen 47a6d844c9 Refine handling of unsafe filename characters. 2018-02-27 09:43:26 -05:00
Michael Kirk e020b0ff99 Persist default sound so we can use it for fallback notifications
// FREEBIE
2018-02-26 15:41:35 -05:00
Matthew Chen 1109158b5b Add comment. 2018-02-21 16:18:10 -05:00
Matthew Chen 70ba1720d9 Filter unicode ordering letters. 2018-02-21 16:18:10 -05:00
Matthew Chen 706006539f Improve the robustness of the migration logic. 2018-02-20 20:16:12 -05:00
Matthew Chen d91507d897 Improve the robustness of the migration logic. 2018-02-20 17:37:14 -05:00
Michael Kirk 033505afd7 Remove slow file protection updates from launch path
To avoid blocking launch, file protection is now updated async for most
moved files. Out of paranoia, the database files are also update
redundantly on a sync code path.

It's still critical that we update permissions recursively for two
reasons:

1. Updating a containing directories FileProtection does not affect
   existing files in that directory.

2. Because we've changed the containers default file protection level
   (from unspecified to NSFileProtectionComplete), some existing files
   will have there file protection updated upon launching Signal 2.20.
   It's not clear to me which files this affects, and I haven't found
   any relevant documentation, but from observation, it seems to affect
   any top-level files in the container. Regardless, we're now doing the
   right thing: after launching 2.20, ensure all file permissions are
   what we expect.

Also removed no-op file protection on legacy db files. They've already
been moved by the time this method runs in AppSetup.

// FREEBIE
2018-02-18 16:24:29 -05:00
Matthew Chen 283fe17649 Apply Indic script fixes to SAE and master. 2018-02-16 16:50: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 47aa29db25 Fix build breakage. 2018-02-15 09:38:00 -05:00
Michael Kirk da15f245cf CR: fix early return, assert on error
inline functions which were only used once

// FREEBIE
2018-02-15 06:23:47 -08:00
Michael Kirk b4359b33dd Fix "lose messages received while in background"
A moved legacy DB has the NSFileProtectionClassComplete, meaning it's
never accessible while the device is locked.

// FREEBIE
2018-02-15 06:23:47 -08:00
Matthew Chen d13511ca7d Exit SAE when complete. 2018-02-14 18:46:22 -05:00
Michael Kirk 5c432a2bc1 Fix crash on launch in debug.
OWSReadReceiptManager is not `init` on the main thread; however, because
it "schedules" it's own processing during init.

I considered dispatching to main, but since AppReadiness already *can*
resolve async if the app isn't yet ready, it should be no less safe to
also dispatch async when it's off the main thread.

// FREEBIE
2018-02-14 13:47:45 -08:00
Matthew Chen b7958262ba Respond to CR. 2018-02-14 16:06:47 -05:00
Matthew Chen 6f28c75257 Fix glitch in batch processing of incoming messages. 2018-02-14 14:56:47 -05:00
Matthew Chen 4b62faf2f8 Aggressively nag iOS 8 users to upgrade iOS. 2018-02-14 14:15:23 -05:00
Michael Kirk 3d5f7e6bf3 Clean up logging
- tag all log lines for easier filtering
- use up-to-date database path

// FREEBIE
2018-02-14 09:16:42 -08:00
Collin B. Stuart cc94573e9b Constant time compare
- fix case when second part of the && conditional is skipped when data is not equal

- isEqual variable marked volatile to prevent case when it doesn't equal 0, the loop can break early since it can never be 0 again

- tested with Fastest O3 and Whole Module optimization (App Store Release)

// FREEBIE
2018-02-13 16:18:06 -08:00
Joshua Lund 2c18a75d12 Update to the new GitHub organization name 2018-02-13 10:52:07 -05:00
Matthew Chen ba42ac73d8 Revisit TODOs in the SAE work. 2018-02-12 22:33:26 -05:00
Matthew Chen 9c8178653d Revisit TODOs in the SAE work. 2018-02-12 22:33:26 -05:00
Matthew Chen bd0f601792 Respond to CR. 2018-02-09 10:31:29 -05:00
Matthew Chen 7d3f79440f Clean up ahead of PR. 2018-02-09 10:31:29 -05:00
Matthew Chen 122ef91e57 Add protocol context to protocol kit. 2018-02-09 10:31:29 -05:00
Michael Kirk a1d3073705 Cannot open settings from share extension
// FREEBIE
2018-02-06 18:50:36 -08:00
Matthew Chen 4bfdef520a Respond to CR. 2018-01-30 12:39:27 -05:00
Matthew Chen a30170b3b2 Prefer "app is ready" flag to "storage is ready" flag. 2018-01-30 11:34:00 -05:00
Matthew Chen 8e427111ef Clean up ahead of PR. 2018-01-30 10:31:13 -05:00
Matthew Chen 6eddfae214 Improve post-migration testing tools. 2018-01-30 10:31:13 -05:00
Matthew Chen 100adae245 Register all database views asynchronously. 2018-01-30 10:30:28 -05:00
Matthew Chen 5cf89a0f3d Register all database views asynchronously. 2018-01-30 10:30:28 -05:00
Matthew Chen 6f7f1b3b08 Improve pre-migration testing tools. 2018-01-30 10:06:46 -05:00
Matthew Chen b3e6278a45 Clean up ahead of PR. 2018-01-25 15:24:21 -05:00
Matthew Chen 9d909025c9 Handle UIImage shares. 2018-01-25 15:17:51 -05:00
Matthew Chen 5770a18b08 Handle text shares like URLs. 2018-01-25 13:26:10 -05:00
Matthew Chen 6a81d8e5c2 Respond to CR. 2018-01-25 13:16:35 -05:00
Matthew Chen 7e769de5d2 Remove spurious warning. 2018-01-25 13:07:56 -05:00
Matthew Chen 0cc7f3e00e Clean up ahead of PR. 2018-01-25 11:00:38 -05:00
Matthew Chen 149199138c Clean up ahead of PR. 2018-01-25 11:00:38 -05:00
Matthew Chen 173da64bc4 Modify YapDatabase to read converted database, part 1. 2018-01-25 11:00:38 -05:00
Michael Kirk 71dc7f55d3 Copy DB setup / keying from Yap into conversion
// FREEBIE
2018-01-25 11:00:38 -05:00
Michael Kirk 5dde17d939 Show approval/caption view in app.
ApprovalView/Captioning is shown for:
- Images/Videos from Library
- Images/Video from Camera
- Document Picker
- GIFs

Voice notes are intentionally not captionable.

Also, in main app, hide status bar when ApprovalView is presented

// FREEBIE
2018-01-17 18:19:48 -05:00
Matthew Chen 2b528ad894 Don't use mainApplicationState in business logic. 2018-01-12 14:24:35 -05:00
Matthew Chen 59933ce1d6 Fix rebase breakage. 2018-01-11 11:15:50 -05:00
Matthew Chen 16f7317579 Complete backup restore/import. 2018-01-11 10:44:03 -05:00
Matthew Chen 272a90d269 Add import back up UI. Begin work on import backup logic. 2018-01-11 10:42:57 -05:00
Matthew Chen 980b3d25a7 Rework "export backup" UI. 2018-01-11 10:42:27 -05:00
Matthew Chen 77572bdaec Retain changes from session database branch. 2018-01-10 12:36:23 -05:00
Matthew Chen 1839b10550 Retain changes from session database branch. 2018-01-10 12:18:34 -05:00
Matthew Chen 9ac2383a2c Retain changes from session database branch. 2018-01-10 12:18:29 -05:00
sdkjfhsdkjhfsdlkjhfsdf 6e2d9c8141 identity change vs. share extension
// FREEBIE
2018-01-02 11:24:36 -06:00
Matthew Chen 085f8a6f64 Clean up ahead of PR. 2017-12-19 12:02:58 -05:00
Matthew Chen d52eba739d Clean up TSStorageManager usage. 2017-12-19 11:41:31 -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 137fe6fb8b Pull out OWSStorage base class for TSStorageManager. 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
Matthew Chen a572285ad2 Respond to CR. 2017-12-19 11:10:12 -05:00
Matthew Chen 2cc3752901 Improve background task logic. 2017-12-19 11:05:17 -05:00
Matthew Chen c3b6de4f83 Improve background task logic. 2017-12-19 11:05:17 -05:00
Matthew Chen f9ce34f553 Improve background task logic. 2017-12-19 11:05:17 -05:00
Matthew Chen 5adf98788d Use background task during message processing. 2017-12-19 11:05:17 -05:00
Matthew Chen 609536fcb1 Include build version in logging. 2017-12-15 11:11:04 -05:00
Michael Kirk 56f1bf0305 cleanup 2017-12-11 19:37:49 -05:00
Matthew Chen 791743a5f0 Fix order of operations in SAE setup. 2017-12-07 16:04:52 -05:00
Matthew Chen f148003fb3 Convert logTag to property. 2017-12-07 14:32:22 -05:00
Matthew Chen 99f0b9d3e8 Fix issues around statics. 2017-12-07 12:34:02 -05:00