|  |  |  | @ -199,6 +199,31 @@ const NSTimeInterval kIdentityKeyStoreNonBlockingSecondsThreshold = 5.0; | 
		
	
		
			
				|  |  |  |  |     } | 
		
	
		
			
				|  |  |  |  | } | 
		
	
		
			
				|  |  |  |  | 
 | 
		
	
		
			
				|  |  |  |  | - (nullable OWSRecipientIdentity *)unseenIdentityChangeForRecipientId:(NSString *)recipientId | 
		
	
		
			
				|  |  |  |  | { | 
		
	
		
			
				|  |  |  |  |     OWSAssert(recipientId != nil); | 
		
	
		
			
				|  |  |  |  | 
 | 
		
	
		
			
				|  |  |  |  |     @synchronized([[self class] sharedIdentityKeyLock]) | 
		
	
		
			
				|  |  |  |  |     { | 
		
	
		
			
				|  |  |  |  |         OWSRecipientIdentity *currentIdentity = [OWSRecipientIdentity fetchObjectWithUniqueID:recipientId]; | 
		
	
		
			
				|  |  |  |  |         if (currentIdentity == nil) { | 
		
	
		
			
				|  |  |  |  |             // No preexisting key, Trust On First Use | 
		
	
		
			
				|  |  |  |  |             return nil; | 
		
	
		
			
				|  |  |  |  |         } | 
		
	
		
			
				|  |  |  |  | 
 | 
		
	
		
			
				|  |  |  |  |         if (currentIdentity.isFirstKnownKey) { | 
		
	
		
			
				|  |  |  |  |             return nil; | 
		
	
		
			
				|  |  |  |  |         } | 
		
	
		
			
				|  |  |  |  | 
 | 
		
	
		
			
				|  |  |  |  |         if (currentIdentity.wasSeen) { | 
		
	
		
			
				|  |  |  |  |             return nil; | 
		
	
		
			
				|  |  |  |  |         } | 
		
	
		
			
				|  |  |  |  | 
 | 
		
	
		
			
				|  |  |  |  |         // identity not yet seen | 
		
	
		
			
				|  |  |  |  |         return currentIdentity; | 
		
	
		
			
				|  |  |  |  |     } | 
		
	
		
			
				|  |  |  |  | } | 
		
	
		
			
				|  |  |  |  | 
 | 
		
	
		
			
				|  |  |  |  | - (BOOL)isTrustedKey:(NSData *)identityKey forSendingToIdentity:(nullable OWSRecipientIdentity *)recipientIdentity | 
		
	
		
			
				|  |  |  |  | { | 
		
	
		
			
				|  |  |  |  |     OWSAssert(identityKey != nil); | 
		
	
	
		
			
				
					|  |  |  | 
 |