File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed
Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ @implementation AESCrypt
1313
1414+ (NSData *)encryptData : (NSData *)data usingKey : (NSData *)key error : (NSError * _Nullable __autoreleasing *)error
1515{
16- NSMutableData *dataOut = [[ NSMutableData alloc ] initWithCapacity: 16 ];
16+ NSMutableData *dataOut = [NSMutableData dataWithLength: data.length + kCCBlockSizeAES128 ];
1717
1818 CCCryptorStatus status = CCCrypt (kCCEncrypt ,
1919 kCCAlgorithmAES ,
Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ struct AuthRequestTxMessage: TransmitterTxMessage {
1919
2020 NSUUID ( ) . getBytes ( & UUIDBytes)
2121
22- singleUseToken = Data ( bytes: UUIDBytes)
22+ singleUseToken = Data ( bytes: UUIDBytes [ 0 ..< 8 ] )
2323 }
2424
2525 var byteSequence : [ Any ] {
You can’t perform that action at this time.
0 commit comments