Respond to CR.

This commit is contained in:
Matthew Chen 2018-10-10 09:59:10 -04:00
parent 75e59bbc6f
commit fab79e2673
5 changed files with 10 additions and 8 deletions

View File

@ -19,7 +19,7 @@ def shared_pods
pod 'Curve25519Kit', git: 'https://github.com/signalapp/Curve25519Kit', testspecs: ["Tests"]
# pod 'Curve25519Kit', path: '../Curve25519Kit', testspecs: ["Tests"]
# TODO: Use public repo.
pod 'SignalMetadataKit', git: 'https://github.com/signalapp/SignalMetadataKit', testspecs: ["Tests"], branch: 'charlesmchen/discardSelfSentMessages'
pod 'SignalMetadataKit', git: 'https://github.com/signalapp/SignalMetadataKit', testspecs: ["Tests"]
# pod 'SignalMetadataKit', path: '../SignalMetadataKit', testspecs: ["Tests"]
pod 'SignalServiceKit', path: '.', testspecs: ["Tests"]
pod 'GRKOpenSSLFramework', git: 'https://github.com/signalapp/GRKOpenSSLFramework'

View File

@ -196,8 +196,8 @@ DEPENDENCIES:
- Reachability
- SignalCoreKit (from `https://github.com/signalapp/SignalCoreKit.git`)
- SignalCoreKit/Tests (from `https://github.com/signalapp/SignalCoreKit.git`)
- SignalMetadataKit (from `https://github.com/signalapp/SignalMetadataKit`, branch `charlesmchen/discardSelfSentMessages`)
- SignalMetadataKit/Tests (from `https://github.com/signalapp/SignalMetadataKit`, branch `charlesmchen/discardSelfSentMessages`)
- SignalMetadataKit (from `https://github.com/signalapp/SignalMetadataKit`)
- SignalMetadataKit/Tests (from `https://github.com/signalapp/SignalMetadataKit`)
- SignalServiceKit (from `.`)
- SignalServiceKit/Tests (from `.`)
- SocketRocket (from `https://github.com/signalapp/SocketRocket.git`, branch `mkirk/handle-sec-err`)
@ -233,7 +233,6 @@ EXTERNAL SOURCES:
SignalCoreKit:
:git: https://github.com/signalapp/SignalCoreKit.git
SignalMetadataKit:
:branch: charlesmchen/discardSelfSentMessages
:git: https://github.com/signalapp/SignalMetadataKit
SignalServiceKit:
:path: "."
@ -264,7 +263,7 @@ CHECKOUT OPTIONS:
:commit: ff0b95770520133b83a4bd7b26bc2c90b51abc4d
:git: https://github.com/signalapp/SignalCoreKit.git
SignalMetadataKit:
:commit: 0ff4673181315f5bd7b883a87b783b5772f7b412
:commit: beb10a358db0202228b8d67bcb466d877fefb405
:git: https://github.com/signalapp/SignalMetadataKit
SocketRocket:
:commit: 9f9563a83cd8960503074aa8de72206f83fb7a69
@ -299,6 +298,6 @@ SPEC CHECKSUMS:
YapDatabase: b418a4baa6906e8028748938f9159807fd039af4
YYImage: 1e1b62a9997399593e4b9c4ecfbbabbf1d3f3b54
PODFILE CHECKSUM: b4815f8e6306c08266b24710736a8c956b666aa1
PODFILE CHECKSUM: 820287bc7925d7c20e02a02923976c60b1f5386b
COCOAPODS: 1.5.3

View File

@ -19,6 +19,8 @@ public class OWS111UDAttributesMigration: OWSDatabaseMigration {
// increment a similar constant for each migration.
@objc
class func migrationId() -> String {
// NOTE: Changes were made to the service after this migration was initially
// merged, so we need to re-migrate any developer devices.
return "111.1"
}

View File

@ -117,7 +117,7 @@ NS_ASSUME_NONNULL_BEGIN
NSOutputStream *dataOutputStream = [NSOutputStream outputStreamToMemory];
[dataOutputStream open];
OWSContactsOutputStream *contactsOutputStream =
[[OWSContactsOutputStream alloc] initWithOutputStream:dataOutputStream];
[[OWSContactsOutputStream alloc] initWithOutputStream:dataOutputStream];
for (SignalAccount *signalAccount in signalAccounts) {
OWSRecipientIdentity *_Nullable recipientIdentity =

View File

@ -459,7 +459,8 @@ NSError *EnsureDecryptError(NSError *_Nullable error, NSString *fallbackErrorDes
protocolContext:transaction
error:&error];
if (error || !decryptResult) {
if ([error.domain isEqualToString:@"SignalMetadataKit.SMKSelfSentMessageError"]) {
if ([error.domain isEqualToString:@"SignalMetadataKit.SMKSecretSessionCipherError"]
&& error.code == SMKSecretSessionCipherErrorSelfSentMessage) {
// Self-sent messages can be safely discarded.
return failureBlock(error);
}