Commit Graph

180 Commits

Author SHA1 Message Date
Harry
52afaa82ef
Allow encrypting a file without custom padding used for bucketing
Some checks failed
CI / Build and Test (push) Has been cancelled
2024-06-03 12:55:20 -07:00
Harry
0e1ee42f41
Expose random encryption key generation in Cryptography.swift 2024-05-31 10:43:57 -07:00
Harry
9498878a69
Support encrypting in memory bytes to in memory output 2024-05-01 17:40:42 -07:00
Harry
f5b92e518e
Read encrypted attachment files directly off disk using a virtual FileHandle 2024-05-01 16:49:50 -07:00
Ehren Kret
b6640fd2ab move signal core kit tests from ios app repo to signal core kit 2024-04-27 13:54:35 -05:00
Pete Walters
44d9256b4a
Expose some methods as public 2024-03-08 17:25:44 -06:00
Max Radermacher
dae815d149
Remove deprecated attribute from a few methods 2023-11-17 16:24:08 -06:00
Max Radermacher
af692d0a1a
Pass data to the correct CocoaLumberjack fields 2023-11-17 12:30:04 -06:00
Max Radermacher
ea99e9002f
Add async-await support to Promises 2023-09-25 12:49:33 -05:00
Max Radermacher
da1f1fd582
Remove some unused code 2023-09-24 20:21:32 -05:00
Pete Walters
8c92ef2634
Optimize allocations in replaceCharacters 2023-08-15 15:09:59 -05:00
Pete Walters
362a2c6bc2
Add a Scheduler.sync that supports rethrowing 2023-07-20 15:09:44 -05:00
Harry
d999504b61
Update build target to iOS 13.0 2023-06-08 09:51:36 -07:00
Igor Solomennikov
c31350f2ca Fix a compiler warning in OWSLogs.h
"A function declaration without a prototype is deprecated in all versions of C"
2023-04-12 15:22:13 -07:00
Evan Hahn
75f61972e0 Add race, timeout, and nilTimeout to Guarantee
This adds the following methods to `Guarantee`:

- `Guarantee.race`, a static method. It's like `Promise.race` but it
  returns a Guarantee, not a Promise. (To match `Promise.race`, there
  are actually two versions of this method: one that takes an array of
  Guarantees and one that takes varargs.)
- `timeout`, an instance method. It's like Promise's `timeout` but it
  returns a Guarantee.
- `nilTimeout`, an instance method. It's like Promise's `nilTimeout` but
  it returns a Guarantee.
2023-03-14 11:12:10 -05:00
Max Radermacher
941fbecc3d Remove unused SCKError… code 2023-02-22 14:43:47 -08:00
Max Radermacher
43004e9c42 Move formatDurationSeconds to SignalMessaging 2023-02-22 14:06:06 -08:00
Max Radermacher
7d2c73808a Remove isValidE164 2023-02-13 13:50:02 -08:00
Max Radermacher
e7ab68a542 Remove AES-GCM, AES-CTR, & OpenSSL-Universal 2023-02-13 11:30:41 -08:00
Harry
58287a4b0a
Use Schedulers for Promise methods
* Use Schedulers for Promise methods

* Always put the scheduler argument first

* Fix ordering in calls

* its hard to write code in github workspaces...
2023-02-07 11:35:45 -08:00
Max Radermacher
0f7a3c7416 Make filterForDisplay non-optional 2023-01-31 11:29:27 -08:00
Max Radermacher
5ae90e076c
Remove redundant ";" from method implementation 2022-10-24 10:56:20 -07:00
Max Radermacher
236a09c60d
Remove unused truncatedSHA1Base64Encoded… method 2022-10-24 10:55:58 -07:00
Max Radermacher
7994b31f97
Remove iOS 11 or lower code paths 2022-10-24 10:55:32 -07:00
Max Radermacher
56dc9a847e Set minimum deployment target to iOS 12.2 2022-10-20 12:42:29 -07:00
Max Radermacher
1d6e3bd1d6
Fix pod lib lint warnings
* Remove constant (unused since 64410ab6b3).
* Remove description
* Set Swift version to 5.0
* Don’t allow warnings during `pod lib lint`
2022-07-25 09:52:03 -07:00
Max Radermacher
2f875bfa87
Add workflow for pushes & pull requests
Co-authored-by: Evan Hahn <69474926+EvanHahn-Signal@users.noreply.github.com>
2022-07-25 08:38:21 -07:00
Max Radermacher
5a9c6be791 Mark StringSanitizer’s @objc methods public 2022-07-21 09:23:11 -07:00
george-signal
2f866beb00
Change how excessive diacriticals are removed.
Fixes a bug where some emoji were mistaken for
zalgo, causing all diacritics in a message to get
stripped. Instead, replace "risky" characters with
too many diacritics with the unicode replacement
character, leaving others alone.
2022-07-20 11:19:38 -07:00
Michelle Linington
603f75807e Remove notImplemented 2022-04-13 20:27:16 -07:00
Martin Böttcher
543d3bfa0d
Merge pull request #59 from signalapp/martin/IOS-2234
added support for using localized strings from the bundle of the main app (when running in an app extension)
2022-03-10 19:47:10 +01:00
Martin Böttcher
6297b00ebc reverted the version number change and corrected some minor details based on feedback 2022-03-10 19:43:38 +01:00
Martin Böttcher
2a1b768441 added support for using localized strings from the bundle of the main app (when running in an app extension) 2022-03-10 11:04:17 +01:00
Michelle Linington
9af3680129 Merge branch 'mlin/PR/OffMainHelper' 2022-03-03 16:25:23 -08:00
Michelle Linington
788cbc4619 Add assertion to verify not on main thread 2022-03-03 16:25:10 -08:00
Jordan Rose
755746107a Call a Future's observers outside of the Future's state lock
Avoids a reentrancy deadlock when a promise's 'result' is used from
within an observer callback. This is a behavior change only in the
following scenario:

1. A promise is sealed and starts running its observers
2. While fulfilling observers, a new observer is added (on the same
   thread or from on another thread)

Previously, the future would wait until all existing observers have
been run, then run the new observer. Now, the new observer will run
immediately, since the only thing being checked is that the promise
has been sealed. We could do more work to preserve the old behavior,
but it's better to not depend on such intricacies in the first place.
2022-03-03 16:18:30 -08:00
Jordan Rose
680ea122fc Add a lock around Future.result
And redefine Future.isSealed in terms of Future.result, rather than
storing it separately.
2022-03-03 13:19:15 -08:00
Jordan Rose
500947f098 Avoid unnecessary allocation in normalization functions
If the string is already in the right form, don't allocate.
Additionally, for replacing elements of a String via CharacterSet,
build up the resulting String explicitly rather than splitting to an
Array and then joining.
2022-02-01 12:06:05 -08:00
George Nachman
f3c7e20453 Merge branch 'george/PR/remove-static' into master 2022-02-01 12:03:11 -08:00
George Nachman
105ae1cacb Remove unnecessary static declaration. 2022-01-31 10:21:29 -08:00
George Nachman
be6df3a525 Merge branch 'george/PR/trap-debugger' into master 2022-01-26 10:38:07 -08:00
George Nachman
b2701e41a9 Break debugger instead of aborting on error. 2022-01-26 10:34:17 -08:00
Michelle Linington
661042ba8c Merge branch 'mlin/PR/AggressiveFlushing' 2022-01-06 11:28:15 -08:00
Michelle Linington
5c132445f7 PR Feedback: Lighter weight atomicity for aggressive logging 2022-01-05 22:06:54 -08:00
Michelle Linington
0cd0f6d7b0 Add flag to aggressively flush logs
This will be used on internal builds to ensure that logs are readily
flushed as we approach the NSE's memory limit
2022-01-04 01:10:56 -08:00
Michelle Linington
517562ffa8 Merge branch 'mlin/PR/AbsoluteTimedGuarantees' 2021-12-16 15:24:24 -08:00
Michelle Linington
075dd6c414 Consult the bundle path for determining appExtension status 2021-12-16 15:13:50 -08:00
Michelle Linington
063292c2d9 PR Feedback 2021-12-16 14:17:03 -08:00
Michelle Linington
69dd803be0 Avoid capturing timeoutErrorBlock in long-lived block 2021-12-15 00:02:06 -08:00
Michelle Linington
faf63cd131 Adds an option to have a timeout use continuous time 2021-12-14 23:38:49 -08:00