Make framework friendly

- Adapt to Curve25159Kit renaming
- Explicit import
- move non-framework compatible includes out of header

// FREEBIE
This commit is contained in:
Michael Kirk 2017-08-18 16:15:43 -04:00
parent 6e9d5e8c3d
commit c1925e77fc
16 changed files with 25 additions and 58 deletions

View File

@ -14,7 +14,7 @@ Pod::Spec.new do |s|
s.ios.deployment_target = "6.0"
s.osx.deployment_target = "10.8"
s.requires_arc = true
s.dependency '25519', '~> 2.0.1'
s.dependency 'Curve25519Kit', '~> 2.1.0'
s.dependency 'HKDFKit', '~> 0.0.3'
s.dependency 'ProtocolBuffers', '~> 1.9.8'
s.dependency 'CocoaLumberjack'

View File

@ -1,12 +1,8 @@
//
// PreKeyRecord.h
// AxolotlKit
//
// Created by Frederic Jacobs on 26/07/14.
// Copyright (c) 2014 Frederic Jacobs. All rights reserved.
// Copyright (c) 2017 Open Whisper Systems. All rights reserved.
//
#import <25519/Curve25519.h>
#import <Curve25519Kit/Curve25519.h>
#import <Foundation/Foundation.h>

View File

@ -4,7 +4,7 @@
#import <Foundation/Foundation.h>
#import "PreKeyRecord.h"
#import <25519/Curve25519.h>
#import <Curve25519Kit/Curve25519.h>
@interface SignedPreKeyRecord : PreKeyRecord <NSSecureCoding>

View File

@ -1,13 +1,9 @@
//
// AxolotlParameters.h
// AxolotlKit
//
// Created by Frederic Jacobs on 22/07/14.
// Copyright (c) 2014 Frederic Jacobs. All rights reserved.
// Copyright (c) 2017 Open Whisper Systems. All rights reserved.
//
#import <Foundation/Foundation.h>
#import <25519/Curve25519.h>
#import <Curve25519Kit/Curve25519.h>
@protocol AxolotlParameters <NSObject>

View File

@ -4,7 +4,7 @@
#import "ChainKey.h"
#import "TSDerivedSecrets.h"
#import <25519/Curve25519.h>
#import <Curve25519Kit/Curve25519.h>
#import <CommonCrypto/CommonCrypto.h>
@implementation ChainKey

View File

@ -1,13 +1,9 @@
//
// RKCK.m
// AxolotlKit
//
// Created by Frederic Jacobs on 1/15/14.
// Copyright (c) 2014 Open Whisper Systems. All rights reserved.
// Copyright (c) 2017 Open Whisper Systems. All rights reserved.
//
#import "RKCK.h"
#import <25519/Curve25519.h>
#import <Curve25519Kit/Curve25519.h>
#import "TSDerivedSecrets.h"
@implementation RKCK

View File

@ -1,9 +1,5 @@
//
// RatchetingSession.m
// AxolotlKit
//
// Created by Frederic Jacobs on 26/07/14.
// Copyright (c) 2014 Frederic Jacobs. All rights reserved.
// Copyright (c) 2017 Open Whisper Systems. All rights reserved.
//
#import "RatchetingSession.h"
@ -13,7 +9,7 @@
#import "RootKey.h"
#import "SessionState.h"
#import <HKDFKit/HKDFKit.h>
#import <25519/Curve25519.h>
#import <Curve25519Kit/Curve25519.h>
#import "ChainKey.h"
@interface DHEResult : NSObject

View File

@ -1,14 +1,10 @@
//
// ReceivingChain.h
// AxolotlKit
//
// Created by Frederic Jacobs on 02/09/14.
// Copyright (c) 2014 Frederic Jacobs. All rights reserved.
// Copyright (c) 2017 Open Whisper Systems. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "Chain.h"
#import <25519/Curve25519.h>
#import <Curve25519Kit/Curve25519.h>
@interface ReceivingChain : NSObject <Chain, NSSecureCoding>

View File

@ -5,7 +5,7 @@
#import "RootKey.h"
#import "TSDerivedSecrets.h"
#import "RKCK.h"
#import <25519/Curve25519.h>
#import <Curve25519Kit/Curve25519.h>
#import "ChainKey.h"
static NSString* const kCoderData = @"kCoderData";

View File

@ -1,15 +1,11 @@
//
// SendingChain.h
// AxolotlKit
//
// Created by Frederic Jacobs on 02/09/14.
// Copyright (c) 2014 Frederic Jacobs. All rights reserved.
// Copyright (c) 2017 Open Whisper Systems. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "Chain.h"
#import <25519/Curve25519.h>
#import <Curve25519Kit/Curve25519.h>
@interface SendingChain : NSObject <Chain, NSSecureCoding>

View File

@ -4,7 +4,7 @@
#import "TSDerivedSecrets.h"
#import "HKDFKit.h"
#import <25519/Curve25519.h>
#import <Curve25519Kit/Curve25519.h>
@implementation TSDerivedSecrets

View File

@ -3,8 +3,8 @@
//
#import "SessionCipher.h"
#import <25519/Curve25519.h>
#import <25519/Ed25519.h>
#import <Curve25519Kit/Curve25519.h>
#import <Curve25519Kit/Ed25519.h>
#import "NSData+keyVersionByte.h"

View File

@ -15,8 +15,8 @@
#import "PreKeyWhisperMessage.h"
#import "RatchetingSession.h"
#import <25519/Curve25519.h>
#import <25519/Ed25519.h>
#import <Curve25519Kit/Curve25519.h>
#import <Curve25519Kit/Ed25519.h>
#import "PrekeyBundle.h"

View File

@ -2,7 +2,7 @@
// Copyright (c) 2017 Open Whisper Systems. All rights reserved.
//
#import <25519/Curve25519.h>
#import <Curve25519Kit/Curve25519.h>
#import "SessionState.h"
#import "ReceivingChain.h"
#import "SendingChain.h"

View File

@ -1,13 +1,8 @@
//
// SerializationUtilities.h
// AxolotlKit
//
// Created by Frederic Jacobs on 26/10/14.
// Copyright (c) 2014 Frederic Jacobs. All rights reserved.
// Copyright (c) 2017 Open Whisper Systems. All rights reserved.
//
#import <Foundation/Foundation.h>
#import <CommonCrypto/CommonCrypto.h>
#define MAC_LENGTH 8

View File

@ -1,13 +1,9 @@
//
// SerializationUtilities.m
// AxolotlKit
//
// Created by Frederic Jacobs on 26/10/14.
// Copyright (c) 2014 Frederic Jacobs. All rights reserved.
// Copyright (c) 2017 Open Whisper Systems. All rights reserved.
//
#import "SerializationUtilities.h"
#import <CommonCrypto/CommonCrypto.h>
@implementation SerializationUtilities