No longer use IDFA, now generate UUID and persist in Core Data. Bumped version to 1.0.0

This commit is contained in:
Diego Waxemberg
2015-10-31 23:03:21 -07:00
parent e6a2d5d425
commit 06289ac4d2
15 changed files with 104 additions and 25 deletions

View File

@@ -11,6 +11,7 @@
#import "CryptoManager.h"
#import "AppAssetResponse.h"
#import "HttpRequest.h"
#import "IdManager.h"
@implementation AppAssetRetriever
static const double RETRY_DELAY = 2; // seconds
@@ -21,7 +22,7 @@ static const int MAX_ATTEMPTS = 5;
int attempts = 0;
while (![self isCancelled] && appImage == nil && attempts++ < MAX_ATTEMPTS) {
HttpManager* hMan = [[HttpManager alloc] initWithHost:_host.activeAddress uniqueId:[CryptoManager getUniqueID] deviceName:deviceName cert:[CryptoManager readCertFromFile]];
HttpManager* hMan = [[HttpManager alloc] initWithHost:_host.activeAddress uniqueId:[IdManager getUniqueId] deviceName:deviceName cert:[CryptoManager readCertFromFile]];
AppAssetResponse* appAssetResp = [[AppAssetResponse alloc] init];
[hMan executeRequestSynchronously:[HttpRequest requestForResponse:appAssetResp withUrlRequest:[hMan newAppAssetRequestWithAppId:self.app.id]]];

View File

@@ -13,6 +13,7 @@
#import "DataManager.h"
#import "DiscoveryWorker.h"
#import "ServerInfoResponse.h"
#import "IdManager.h"
@implementation DiscoveryManager {
NSMutableArray* _hostQueue;
@@ -48,7 +49,7 @@
_opQueue = [[NSOperationQueue alloc] init];
_mdnsMan = [[MDNSManager alloc] initWithCallback:self];
[CryptoManager generateKeyPairUsingSSl];
_uniqueId = [CryptoManager getUniqueID];
_uniqueId = [IdManager getUniqueId];
_cert = [CryptoManager readCertFromFile];
return self;
}