diff --git a/bindings/ios/3rdparty/build-cryptopp.sh b/bindings/ios/3rdparty/build-cryptopp.sh index 9d1b849135..97ba39fd3c 100644 --- a/bindings/ios/3rdparty/build-cryptopp.sh +++ b/bindings/ios/3rdparty/build-cryptopp.sh @@ -1,40 +1,43 @@ #!/bin/sh -PROJECT_NAME="cryptopp" -CRYPTOPP_VERSION="565" +CURRENTPATH=`pwd` -UNIVERSAL_OUTPUTFOLDER="lib" -BUILD_DIR="cryptopp" -CONFIGURATION="Release" -BUILD_ROOT="cryptopp" - -############################################## +CRYPTOPP_VERSION="982655845a784a9a4cfbc92221359a25a74184a3" set -e -if [ ! -e "cryptopp${CRYPTOPP_VERSION}.zip" ] +NPROCESSORS=$(getconf NPROCESSORS_ONLN 2>/dev/null || getconf _NPROCESSORS_ONLN 2>/dev/null) + +if [ ! -e "${CRYPTOPP_VERSION}.tar.gz" ] then -curl -LO "http://www.cryptopp.com/cryptopp${CRYPTOPP_VERSION}.zip" +curl -LO "https://github.com/weidai11/cryptopp/archive/${CRYPTOPP_VERSION}.tar.gz" fi -unzip cryptopp${CRYPTOPP_VERSION}.zip -d cryptopp - -# Step 1. Build versions for devices and simulator -xcodebuild -jobs 8 -target cryptopp ONLY_ACTIVE_ARCH=NO -configuration ${CONFIGURATION} -sdk iphoneos BUILD_DIR="${BUILD_DIR}" BUILD_ROOT="${BUILD_ROOT}" -xcodebuild -jobs 8 -target cryptopp ONLY_ACTIVE_ARCH=NO -configuration ${CONFIGURATION} -sdk iphonesimulator BUILD_DIR="${BUILD_DIR}" BUILD_ROOT="${BUILD_ROOT}" - -# Make sure the output directory exists -mkdir -p "${UNIVERSAL_OUTPUTFOLDER}" - -# Step 2. Create universal binary file, using lipo -lipo -create -output "${UNIVERSAL_OUTPUTFOLDER}/lib${PROJECT_NAME}.a" "${BUILD_DIR}/${CONFIGURATION}-iphoneos/lib${PROJECT_NAME}.a" "${BUILD_DIR}/${CONFIGURATION}-iphonesimulator/lib${PROJECT_NAME}.a" +ARCHS="x86_64 armv7 armv7s arm64" + +for ARCH in ${ARCHS} +do +tar zxf ${CRYPTOPP_VERSION}.tar.gz +pushd cryptopp-${CRYPTOPP_VERSION} +source setenv-ios.sh ${ARCH} +mkdir -p "${CURRENTPATH}/bin/${ARCH}.sdk" +make -f GNUmakefile-cross lean -j ${NPROCESSORS} +mv libcryptopp.a "${CURRENTPATH}/bin/${ARCH}.sdk" +popd +rm -rf cryptopp-${CRYPTOPP_VERSION} +done + +mkdir -p lib + +lipo -create "${CURRENTPATH}/bin/x86_64.sdk/libcryptopp.a" "${CURRENTPATH}/bin/armv7.sdk/libcryptopp.a" "${CURRENTPATH}/bin/armv7s.sdk/libcryptopp.a" "${CURRENTPATH}/bin/arm64.sdk/libcryptopp.a" -output "${CURRENTPATH}/libcryptopp.a" +tar zxf ${CRYPTOPP_VERSION}.tar.gz mkdir -p include/cryptopp || true -cp -f cryptopp/*.h include/cryptopp -sed -i '' $'s/\#ifdef CRYPTOPP_DISABLE_X86ASM/\#define CRYPTOPP_DISABLE_X86ASM\\\n\#ifdef CRYPTOPP_DISABLE_X86ASM/' include/cryptopp/config.h +cp -f cryptopp-${CRYPTOPP_VERSION}/*.h include/cryptopp +rm -rf cryptopp-${CRYPTOPP_VERSION} +mv -f libcryptopp.a lib/ -rm -rf cryptopp -rm -rf build rm -rf bin +rm -rf ${CRYPTOPP_VERSION}.tar.gz echo "Done." diff --git a/bindings/ios/3rdparty/cryptopp.xcodeproj/project.pbxproj b/bindings/ios/3rdparty/cryptopp.xcodeproj/project.pbxproj deleted file mode 100644 index b31c5bdf6f..0000000000 --- a/bindings/ios/3rdparty/cryptopp.xcodeproj/project.pbxproj +++ /dev/null @@ -1,1013 +0,0 @@ -// !$*UTF8*$! -{ - archiveVersion = 1; - classes = { - }; - objectVersion = 46; - objects = { - -/* Begin PBXBuildFile section */ - 41ACFBC51A11524C00905ACF /* wake.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 41ACFBC41A11524C00905ACF /* wake.cpp */; }; - 9426682E19DAC5A300B63EB5 /* algebra.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667A919DAC5A300B63EB5 /* algebra.cpp */; }; - 9426683219DAC5A300B63EB5 /* dsa.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667AD19DAC5A300B63EB5 /* dsa.cpp */; }; - 9426683319DAC5A300B63EB5 /* eccrypto.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667AE19DAC5A300B63EB5 /* eccrypto.cpp */; }; - 9426683419DAC5A300B63EB5 /* gfpcrypt.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667AF19DAC5A300B63EB5 /* gfpcrypt.cpp */; }; - 9426683519DAC5A300B63EB5 /* osrng.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667B019DAC5A300B63EB5 /* osrng.cpp */; }; - 9426683619DAC5A300B63EB5 /* panama.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667B119DAC5A300B63EB5 /* panama.cpp */; }; - 9426683819DAC5A300B63EB5 /* rijndael.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667B319DAC5A300B63EB5 /* rijndael.cpp */; }; - 9426683919DAC5A300B63EB5 /* salsa.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667B419DAC5A300B63EB5 /* salsa.cpp */; }; - 9426683A19DAC5A300B63EB5 /* sha3.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667B519DAC5A300B63EB5 /* sha3.cpp */; }; - 9426683D19DAC5A300B63EB5 /* 3way.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667B819DAC5A300B63EB5 /* 3way.cpp */; }; - 9426683E19DAC5A300B63EB5 /* adler32.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667B919DAC5A300B63EB5 /* adler32.cpp */; }; - 9426683F19DAC5A300B63EB5 /* algparam.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667BA19DAC5A300B63EB5 /* algparam.cpp */; }; - 9426684019DAC5A300B63EB5 /* arc4.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667BB19DAC5A300B63EB5 /* arc4.cpp */; }; - 9426684119DAC5A300B63EB5 /* asn.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667BC19DAC5A300B63EB5 /* asn.cpp */; }; - 9426684219DAC5A300B63EB5 /* authenc.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667BD19DAC5A300B63EB5 /* authenc.cpp */; }; - 9426684319DAC5A300B63EB5 /* base32.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667BE19DAC5A300B63EB5 /* base32.cpp */; }; - 9426684419DAC5A300B63EB5 /* base64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667BF19DAC5A300B63EB5 /* base64.cpp */; }; - 9426684519DAC5A300B63EB5 /* basecode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667C019DAC5A300B63EB5 /* basecode.cpp */; }; - 9426684619DAC5A300B63EB5 /* bfinit.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667C119DAC5A300B63EB5 /* bfinit.cpp */; }; - 9426684719DAC5A300B63EB5 /* blowfish.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667C219DAC5A300B63EB5 /* blowfish.cpp */; }; - 9426684819DAC5A300B63EB5 /* blumshub.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667C319DAC5A300B63EB5 /* blumshub.cpp */; }; - 9426684919DAC5A300B63EB5 /* camellia.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667C419DAC5A300B63EB5 /* camellia.cpp */; }; - 9426684A19DAC5A300B63EB5 /* cast.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667C519DAC5A300B63EB5 /* cast.cpp */; }; - 9426684B19DAC5A300B63EB5 /* casts.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667C619DAC5A300B63EB5 /* casts.cpp */; }; - 9426684C19DAC5A300B63EB5 /* cbcmac.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667C719DAC5A300B63EB5 /* cbcmac.cpp */; }; - 9426684D19DAC5A300B63EB5 /* ccm.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667C819DAC5A300B63EB5 /* ccm.cpp */; }; - 9426684E19DAC5A300B63EB5 /* channels.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667C919DAC5A300B63EB5 /* channels.cpp */; }; - 9426684F19DAC5A300B63EB5 /* cmac.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667CA19DAC5A300B63EB5 /* cmac.cpp */; }; - 9426685019DAC5A300B63EB5 /* cpu.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667CB19DAC5A300B63EB5 /* cpu.cpp */; }; - 9426685119DAC5A300B63EB5 /* crc.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667CC19DAC5A300B63EB5 /* crc.cpp */; }; - 9426685319DAC5A300B63EB5 /* cryptlib.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667CE19DAC5A300B63EB5 /* cryptlib.cpp */; }; - 9426685419DAC5A300B63EB5 /* default.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667CF19DAC5A300B63EB5 /* default.cpp */; }; - 9426685519DAC5A300B63EB5 /* des.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667D019DAC5A300B63EB5 /* des.cpp */; }; - 9426685619DAC5A300B63EB5 /* dessp.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667D119DAC5A300B63EB5 /* dessp.cpp */; }; - 9426685719DAC5A300B63EB5 /* dh.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667D219DAC5A300B63EB5 /* dh.cpp */; }; - 9426685819DAC5A300B63EB5 /* dh2.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667D319DAC5A300B63EB5 /* dh2.cpp */; }; - 9426685919DAC5A300B63EB5 /* dll.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667D419DAC5A300B63EB5 /* dll.cpp */; }; - 9426685B19DAC5A300B63EB5 /* eax.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667D619DAC5A300B63EB5 /* eax.cpp */; }; - 9426685C19DAC5A300B63EB5 /* ec2n.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667D719DAC5A300B63EB5 /* ec2n.cpp */; }; - 9426685D19DAC5A300B63EB5 /* ecp.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667D819DAC5A300B63EB5 /* ecp.cpp */; }; - 9426685E19DAC5A300B63EB5 /* elgamal.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667D919DAC5A300B63EB5 /* elgamal.cpp */; }; - 9426685F19DAC5A300B63EB5 /* emsa2.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667DA19DAC5A300B63EB5 /* emsa2.cpp */; }; - 9426686019DAC5A300B63EB5 /* eprecomp.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667DB19DAC5A300B63EB5 /* eprecomp.cpp */; }; - 9426686119DAC5A300B63EB5 /* esign.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667DC19DAC5A300B63EB5 /* esign.cpp */; }; - 9426686219DAC5A300B63EB5 /* files.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667DD19DAC5A300B63EB5 /* files.cpp */; }; - 9426686319DAC5A300B63EB5 /* filters.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667DE19DAC5A300B63EB5 /* filters.cpp */; }; - 9426686419DAC5A300B63EB5 /* fips140.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667DF19DAC5A300B63EB5 /* fips140.cpp */; }; - 9426686519DAC5A300B63EB5 /* fipsalgt.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667E019DAC5A300B63EB5 /* fipsalgt.cpp */; }; - 9426686719DAC5A300B63EB5 /* gcm.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667E219DAC5A300B63EB5 /* gcm.cpp */; }; - 9426686819DAC5A300B63EB5 /* gf2_32.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667E319DAC5A300B63EB5 /* gf2_32.cpp */; }; - 9426686919DAC5A300B63EB5 /* gf2n.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667E419DAC5A300B63EB5 /* gf2n.cpp */; }; - 9426686A19DAC5A300B63EB5 /* gf256.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667E519DAC5A300B63EB5 /* gf256.cpp */; }; - 9426686B19DAC5A300B63EB5 /* gost.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667E619DAC5A300B63EB5 /* gost.cpp */; }; - 9426686C19DAC5A300B63EB5 /* gzip.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667E719DAC5A300B63EB5 /* gzip.cpp */; }; - 9426686D19DAC5A300B63EB5 /* hex.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667E819DAC5A300B63EB5 /* hex.cpp */; }; - 9426686E19DAC5A300B63EB5 /* hmac.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667E919DAC5A300B63EB5 /* hmac.cpp */; }; - 9426686F19DAC5A300B63EB5 /* hrtimer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667EA19DAC5A300B63EB5 /* hrtimer.cpp */; }; - 9426687019DAC5A300B63EB5 /* ida.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667EB19DAC5A300B63EB5 /* ida.cpp */; }; - 9426687119DAC5A300B63EB5 /* idea.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667EC19DAC5A300B63EB5 /* idea.cpp */; }; - 9426687219DAC5A300B63EB5 /* integer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667ED19DAC5A300B63EB5 /* integer.cpp */; }; - 9426687319DAC5A300B63EB5 /* iterhash.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667EE19DAC5A300B63EB5 /* iterhash.cpp */; }; - 9426687419DAC5A300B63EB5 /* luc.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667EF19DAC5A300B63EB5 /* luc.cpp */; }; - 9426687519DAC5A300B63EB5 /* mars.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667F019DAC5A300B63EB5 /* mars.cpp */; }; - 9426687619DAC5A300B63EB5 /* marss.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667F119DAC5A300B63EB5 /* marss.cpp */; }; - 9426687719DAC5A300B63EB5 /* md2.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667F219DAC5A300B63EB5 /* md2.cpp */; }; - 9426687819DAC5A300B63EB5 /* md4.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667F319DAC5A300B63EB5 /* md4.cpp */; }; - 9426687919DAC5A300B63EB5 /* md5.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667F419DAC5A300B63EB5 /* md5.cpp */; }; - 9426687A19DAC5A300B63EB5 /* misc.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667F519DAC5A300B63EB5 /* misc.cpp */; }; - 9426687B19DAC5A300B63EB5 /* modes.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667F619DAC5A300B63EB5 /* modes.cpp */; }; - 9426687C19DAC5A300B63EB5 /* mqueue.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667F719DAC5A300B63EB5 /* mqueue.cpp */; }; - 9426687D19DAC5A300B63EB5 /* mqv.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667F819DAC5A300B63EB5 /* mqv.cpp */; }; - 9426687E19DAC5A300B63EB5 /* nbtheory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667F919DAC5A300B63EB5 /* nbtheory.cpp */; }; - 9426687F19DAC5A300B63EB5 /* network.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667FA19DAC5A300B63EB5 /* network.cpp */; }; - 9426688019DAC5A300B63EB5 /* oaep.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667FB19DAC5A300B63EB5 /* oaep.cpp */; }; - 9426688119DAC5A300B63EB5 /* pch.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667FC19DAC5A300B63EB5 /* pch.cpp */; }; - 9426688219DAC5A300B63EB5 /* pkcspad.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667FD19DAC5A300B63EB5 /* pkcspad.cpp */; }; - 9426688319DAC5A300B63EB5 /* polynomi.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667FE19DAC5A300B63EB5 /* polynomi.cpp */; }; - 9426688419DAC5A300B63EB5 /* pssr.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 942667FF19DAC5A300B63EB5 /* pssr.cpp */; }; - 9426688519DAC5A300B63EB5 /* pubkey.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426680019DAC5A300B63EB5 /* pubkey.cpp */; }; - 9426688619DAC5A300B63EB5 /* queue.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426680119DAC5A300B63EB5 /* queue.cpp */; }; - 9426688719DAC5A300B63EB5 /* rabin.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426680219DAC5A300B63EB5 /* rabin.cpp */; }; - 9426688819DAC5A300B63EB5 /* randpool.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426680319DAC5A300B63EB5 /* randpool.cpp */; }; - 9426688919DAC5A300B63EB5 /* rc2.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426680419DAC5A300B63EB5 /* rc2.cpp */; }; - 9426688A19DAC5A300B63EB5 /* rc5.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426680519DAC5A300B63EB5 /* rc5.cpp */; }; - 9426688B19DAC5A300B63EB5 /* rc6.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426680619DAC5A300B63EB5 /* rc6.cpp */; }; - 9426688C19DAC5A300B63EB5 /* rdtables.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426680719DAC5A300B63EB5 /* rdtables.cpp */; }; - 9426688D19DAC5A300B63EB5 /* ripemd.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426680819DAC5A300B63EB5 /* ripemd.cpp */; }; - 9426688E19DAC5A300B63EB5 /* rng.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426680919DAC5A300B63EB5 /* rng.cpp */; }; - 9426688F19DAC5A300B63EB5 /* rsa.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426680A19DAC5A300B63EB5 /* rsa.cpp */; }; - 9426689019DAC5A300B63EB5 /* rw.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426680B19DAC5A300B63EB5 /* rw.cpp */; }; - 9426689119DAC5A300B63EB5 /* safer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426680C19DAC5A300B63EB5 /* safer.cpp */; }; - 9426689219DAC5A300B63EB5 /* seal.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426680D19DAC5A300B63EB5 /* seal.cpp */; }; - 9426689319DAC5A300B63EB5 /* seed.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426680E19DAC5A300B63EB5 /* seed.cpp */; }; - 9426689419DAC5A300B63EB5 /* serpent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426680F19DAC5A300B63EB5 /* serpent.cpp */; }; - 9426689519DAC5A300B63EB5 /* sha.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426681019DAC5A300B63EB5 /* sha.cpp */; }; - 9426689619DAC5A300B63EB5 /* shacal2.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426681119DAC5A300B63EB5 /* shacal2.cpp */; }; - 9426689719DAC5A300B63EB5 /* shark.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426681219DAC5A300B63EB5 /* shark.cpp */; }; - 9426689819DAC5A300B63EB5 /* sharkbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426681319DAC5A300B63EB5 /* sharkbox.cpp */; }; - 9426689919DAC5A300B63EB5 /* simple.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426681419DAC5A300B63EB5 /* simple.cpp */; }; - 9426689A19DAC5A300B63EB5 /* skipjack.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426681519DAC5A300B63EB5 /* skipjack.cpp */; }; - 9426689B19DAC5A300B63EB5 /* socketft.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426681619DAC5A300B63EB5 /* socketft.cpp */; }; - 9426689C19DAC5A300B63EB5 /* sosemanuk.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426681719DAC5A300B63EB5 /* sosemanuk.cpp */; }; - 9426689D19DAC5A300B63EB5 /* square.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426681819DAC5A300B63EB5 /* square.cpp */; }; - 9426689E19DAC5A300B63EB5 /* squaretb.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426681919DAC5A300B63EB5 /* squaretb.cpp */; }; - 9426689F19DAC5A300B63EB5 /* strciphr.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426681A19DAC5A300B63EB5 /* strciphr.cpp */; }; - 942668A019DAC5A300B63EB5 /* tea.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426681B19DAC5A300B63EB5 /* tea.cpp */; }; - 942668A219DAC5A300B63EB5 /* tftables.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426681D19DAC5A300B63EB5 /* tftables.cpp */; }; - 942668A319DAC5A300B63EB5 /* tiger.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426681E19DAC5A300B63EB5 /* tiger.cpp */; }; - 942668A419DAC5A300B63EB5 /* tigertab.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426681F19DAC5A300B63EB5 /* tigertab.cpp */; }; - 942668A519DAC5A300B63EB5 /* trdlocal.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426682019DAC5A300B63EB5 /* trdlocal.cpp */; }; - 942668A619DAC5A300B63EB5 /* ttmac.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426682119DAC5A300B63EB5 /* ttmac.cpp */; }; - 942668A719DAC5A300B63EB5 /* twofish.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426682219DAC5A300B63EB5 /* twofish.cpp */; }; - 942668A919DAC5A300B63EB5 /* vmac.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426682419DAC5A300B63EB5 /* vmac.cpp */; }; - 942668AA19DAC5A300B63EB5 /* wait.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426682519DAC5A300B63EB5 /* wait.cpp */; }; - 942668AC19DAC5A300B63EB5 /* whrlpool.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426682719DAC5A300B63EB5 /* whrlpool.cpp */; }; - 942668AD19DAC5A300B63EB5 /* winpipes.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426682819DAC5A300B63EB5 /* winpipes.cpp */; }; - 942668AE19DAC5A300B63EB5 /* xtr.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426682919DAC5A300B63EB5 /* xtr.cpp */; }; - 942668AF19DAC5A300B63EB5 /* xtrcrypt.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426682A19DAC5A300B63EB5 /* xtrcrypt.cpp */; }; - 942668B019DAC5A300B63EB5 /* zdeflate.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426682B19DAC5A300B63EB5 /* zdeflate.cpp */; }; - 942668B119DAC5A300B63EB5 /* zinflate.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426682C19DAC5A300B63EB5 /* zinflate.cpp */; }; - 942668B219DAC5A300B63EB5 /* zlib.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9426682D19DAC5A300B63EB5 /* zlib.cpp */; }; -/* End PBXBuildFile section */ - -/* Begin PBXCopyFilesBuildPhase section */ - 9426679219DAC3F500B63EB5 /* CopyFiles */ = { - isa = PBXCopyFilesBuildPhase; - buildActionMask = 2147483647; - dstPath = "include/$(PRODUCT_NAME)"; - dstSubfolderSpec = 16; - files = ( - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXCopyFilesBuildPhase section */ - -/* Begin PBXFileReference section */ - 41ACFBC41A11524C00905ACF /* wake.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = wake.cpp; sourceTree = ""; }; - 9426679419DAC3F500B63EB5 /* libcryptopp.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libcryptopp.a; sourceTree = BUILT_PRODUCTS_DIR; }; - 942667A919DAC5A300B63EB5 /* algebra.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = algebra.cpp; sourceTree = ""; }; - 942667AD19DAC5A300B63EB5 /* dsa.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = dsa.cpp; sourceTree = ""; }; - 942667AE19DAC5A300B63EB5 /* eccrypto.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = eccrypto.cpp; sourceTree = ""; }; - 942667AF19DAC5A300B63EB5 /* gfpcrypt.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = gfpcrypt.cpp; sourceTree = ""; }; - 942667B019DAC5A300B63EB5 /* osrng.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = osrng.cpp; sourceTree = ""; }; - 942667B119DAC5A300B63EB5 /* panama.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = panama.cpp; sourceTree = ""; }; - 942667B319DAC5A300B63EB5 /* rijndael.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = rijndael.cpp; sourceTree = ""; }; - 942667B419DAC5A300B63EB5 /* salsa.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = salsa.cpp; sourceTree = ""; }; - 942667B519DAC5A300B63EB5 /* sha3.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = sha3.cpp; sourceTree = ""; }; - 942667B819DAC5A300B63EB5 /* 3way.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = 3way.cpp; sourceTree = ""; }; - 942667B919DAC5A300B63EB5 /* adler32.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = adler32.cpp; sourceTree = ""; }; - 942667BA19DAC5A300B63EB5 /* algparam.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = algparam.cpp; sourceTree = ""; }; - 942667BB19DAC5A300B63EB5 /* arc4.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = arc4.cpp; sourceTree = ""; }; - 942667BC19DAC5A300B63EB5 /* asn.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = asn.cpp; sourceTree = ""; }; - 942667BD19DAC5A300B63EB5 /* authenc.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = authenc.cpp; sourceTree = ""; }; - 942667BE19DAC5A300B63EB5 /* base32.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = base32.cpp; sourceTree = ""; }; - 942667BF19DAC5A300B63EB5 /* base64.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = base64.cpp; sourceTree = ""; }; - 942667C019DAC5A300B63EB5 /* basecode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = basecode.cpp; sourceTree = ""; }; - 942667C119DAC5A300B63EB5 /* bfinit.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = bfinit.cpp; sourceTree = ""; }; - 942667C219DAC5A300B63EB5 /* blowfish.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = blowfish.cpp; sourceTree = ""; }; - 942667C319DAC5A300B63EB5 /* blumshub.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = blumshub.cpp; sourceTree = ""; }; - 942667C419DAC5A300B63EB5 /* camellia.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = camellia.cpp; sourceTree = ""; }; - 942667C519DAC5A300B63EB5 /* cast.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = cast.cpp; sourceTree = ""; }; - 942667C619DAC5A300B63EB5 /* casts.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = casts.cpp; sourceTree = ""; }; - 942667C719DAC5A300B63EB5 /* cbcmac.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = cbcmac.cpp; sourceTree = ""; }; - 942667C819DAC5A300B63EB5 /* ccm.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ccm.cpp; sourceTree = ""; }; - 942667C919DAC5A300B63EB5 /* channels.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = channels.cpp; sourceTree = ""; }; - 942667CA19DAC5A300B63EB5 /* cmac.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = cmac.cpp; sourceTree = ""; }; - 942667CB19DAC5A300B63EB5 /* cpu.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = cpu.cpp; sourceTree = ""; }; - 942667CC19DAC5A300B63EB5 /* crc.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = crc.cpp; sourceTree = ""; }; - 942667CD19DAC5A300B63EB5 /* cryptlib_bds.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = cryptlib_bds.cpp; sourceTree = ""; }; - 942667CE19DAC5A300B63EB5 /* cryptlib.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = cryptlib.cpp; sourceTree = ""; }; - 942667CF19DAC5A300B63EB5 /* default.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = default.cpp; sourceTree = ""; }; - 942667D019DAC5A300B63EB5 /* des.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = des.cpp; sourceTree = ""; }; - 942667D119DAC5A300B63EB5 /* dessp.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = dessp.cpp; sourceTree = ""; }; - 942667D219DAC5A300B63EB5 /* dh.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = dh.cpp; sourceTree = ""; }; - 942667D319DAC5A300B63EB5 /* dh2.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = dh2.cpp; sourceTree = ""; }; - 942667D419DAC5A300B63EB5 /* dll.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = dll.cpp; sourceTree = ""; }; - 942667D619DAC5A300B63EB5 /* eax.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = eax.cpp; sourceTree = ""; }; - 942667D719DAC5A300B63EB5 /* ec2n.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ec2n.cpp; sourceTree = ""; }; - 942667D819DAC5A300B63EB5 /* ecp.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ecp.cpp; sourceTree = ""; }; - 942667D919DAC5A300B63EB5 /* elgamal.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = elgamal.cpp; sourceTree = ""; }; - 942667DA19DAC5A300B63EB5 /* emsa2.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = emsa2.cpp; sourceTree = ""; }; - 942667DB19DAC5A300B63EB5 /* eprecomp.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = eprecomp.cpp; sourceTree = ""; }; - 942667DC19DAC5A300B63EB5 /* esign.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = esign.cpp; sourceTree = ""; }; - 942667DD19DAC5A300B63EB5 /* files.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = files.cpp; sourceTree = ""; }; - 942667DE19DAC5A300B63EB5 /* filters.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = filters.cpp; sourceTree = ""; }; - 942667DF19DAC5A300B63EB5 /* fips140.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = fips140.cpp; sourceTree = ""; }; - 942667E019DAC5A300B63EB5 /* fipsalgt.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = fipsalgt.cpp; sourceTree = ""; }; - 942667E219DAC5A300B63EB5 /* gcm.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = gcm.cpp; sourceTree = ""; }; - 942667E319DAC5A300B63EB5 /* gf2_32.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = gf2_32.cpp; sourceTree = ""; }; - 942667E419DAC5A300B63EB5 /* gf2n.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = gf2n.cpp; sourceTree = ""; }; - 942667E519DAC5A300B63EB5 /* gf256.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = gf256.cpp; sourceTree = ""; }; - 942667E619DAC5A300B63EB5 /* gost.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = gost.cpp; sourceTree = ""; }; - 942667E719DAC5A300B63EB5 /* gzip.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = gzip.cpp; sourceTree = ""; }; - 942667E819DAC5A300B63EB5 /* hex.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = hex.cpp; sourceTree = ""; }; - 942667E919DAC5A300B63EB5 /* hmac.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = hmac.cpp; sourceTree = ""; }; - 942667EA19DAC5A300B63EB5 /* hrtimer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = hrtimer.cpp; sourceTree = ""; }; - 942667EB19DAC5A300B63EB5 /* ida.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ida.cpp; sourceTree = ""; }; - 942667EC19DAC5A300B63EB5 /* idea.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = idea.cpp; sourceTree = ""; }; - 942667ED19DAC5A300B63EB5 /* integer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = integer.cpp; sourceTree = ""; }; - 942667EE19DAC5A300B63EB5 /* iterhash.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = iterhash.cpp; sourceTree = ""; }; - 942667EF19DAC5A300B63EB5 /* luc.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = luc.cpp; sourceTree = ""; }; - 942667F019DAC5A300B63EB5 /* mars.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = mars.cpp; sourceTree = ""; }; - 942667F119DAC5A300B63EB5 /* marss.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = marss.cpp; sourceTree = ""; }; - 942667F219DAC5A300B63EB5 /* md2.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = md2.cpp; sourceTree = ""; }; - 942667F319DAC5A300B63EB5 /* md4.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = md4.cpp; sourceTree = ""; }; - 942667F419DAC5A300B63EB5 /* md5.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = md5.cpp; sourceTree = ""; }; - 942667F519DAC5A300B63EB5 /* misc.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = misc.cpp; sourceTree = ""; }; - 942667F619DAC5A300B63EB5 /* modes.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = modes.cpp; sourceTree = ""; }; - 942667F719DAC5A300B63EB5 /* mqueue.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = mqueue.cpp; sourceTree = ""; }; - 942667F819DAC5A300B63EB5 /* mqv.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = mqv.cpp; sourceTree = ""; }; - 942667F919DAC5A300B63EB5 /* nbtheory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = nbtheory.cpp; sourceTree = ""; }; - 942667FA19DAC5A300B63EB5 /* network.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = network.cpp; sourceTree = ""; }; - 942667FB19DAC5A300B63EB5 /* oaep.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = oaep.cpp; sourceTree = ""; }; - 942667FC19DAC5A300B63EB5 /* pch.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = pch.cpp; sourceTree = ""; }; - 942667FD19DAC5A300B63EB5 /* pkcspad.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = pkcspad.cpp; sourceTree = ""; }; - 942667FE19DAC5A300B63EB5 /* polynomi.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = polynomi.cpp; sourceTree = ""; }; - 942667FF19DAC5A300B63EB5 /* pssr.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = pssr.cpp; sourceTree = ""; }; - 9426680019DAC5A300B63EB5 /* pubkey.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = pubkey.cpp; sourceTree = ""; }; - 9426680119DAC5A300B63EB5 /* queue.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = queue.cpp; sourceTree = ""; }; - 9426680219DAC5A300B63EB5 /* rabin.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = rabin.cpp; sourceTree = ""; }; - 9426680319DAC5A300B63EB5 /* randpool.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = randpool.cpp; sourceTree = ""; }; - 9426680419DAC5A300B63EB5 /* rc2.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = rc2.cpp; sourceTree = ""; }; - 9426680519DAC5A300B63EB5 /* rc5.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = rc5.cpp; sourceTree = ""; }; - 9426680619DAC5A300B63EB5 /* rc6.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = rc6.cpp; sourceTree = ""; }; - 9426680719DAC5A300B63EB5 /* rdtables.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = rdtables.cpp; sourceTree = ""; }; - 9426680819DAC5A300B63EB5 /* ripemd.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ripemd.cpp; sourceTree = ""; }; - 9426680919DAC5A300B63EB5 /* rng.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = rng.cpp; sourceTree = ""; }; - 9426680A19DAC5A300B63EB5 /* rsa.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = rsa.cpp; sourceTree = ""; }; - 9426680B19DAC5A300B63EB5 /* rw.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = rw.cpp; sourceTree = ""; }; - 9426680C19DAC5A300B63EB5 /* safer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = safer.cpp; sourceTree = ""; }; - 9426680D19DAC5A300B63EB5 /* seal.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = seal.cpp; sourceTree = ""; }; - 9426680E19DAC5A300B63EB5 /* seed.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = seed.cpp; sourceTree = ""; }; - 9426680F19DAC5A300B63EB5 /* serpent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = serpent.cpp; sourceTree = ""; }; - 9426681019DAC5A300B63EB5 /* sha.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = sha.cpp; sourceTree = ""; }; - 9426681119DAC5A300B63EB5 /* shacal2.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = shacal2.cpp; sourceTree = ""; }; - 9426681219DAC5A300B63EB5 /* shark.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = shark.cpp; sourceTree = ""; }; - 9426681319DAC5A300B63EB5 /* sharkbox.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = sharkbox.cpp; sourceTree = ""; }; - 9426681419DAC5A300B63EB5 /* simple.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = simple.cpp; sourceTree = ""; }; - 9426681519DAC5A300B63EB5 /* skipjack.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = skipjack.cpp; sourceTree = ""; }; - 9426681619DAC5A300B63EB5 /* socketft.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = socketft.cpp; sourceTree = ""; }; - 9426681719DAC5A300B63EB5 /* sosemanuk.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = sosemanuk.cpp; sourceTree = ""; }; - 9426681819DAC5A300B63EB5 /* square.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = square.cpp; sourceTree = ""; }; - 9426681919DAC5A300B63EB5 /* squaretb.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = squaretb.cpp; sourceTree = ""; }; - 9426681A19DAC5A300B63EB5 /* strciphr.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = strciphr.cpp; sourceTree = ""; }; - 9426681B19DAC5A300B63EB5 /* tea.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = tea.cpp; sourceTree = ""; }; - 9426681D19DAC5A300B63EB5 /* tftables.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = tftables.cpp; sourceTree = ""; }; - 9426681E19DAC5A300B63EB5 /* tiger.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = tiger.cpp; sourceTree = ""; }; - 9426681F19DAC5A300B63EB5 /* tigertab.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = tigertab.cpp; sourceTree = ""; }; - 9426682019DAC5A300B63EB5 /* trdlocal.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = trdlocal.cpp; sourceTree = ""; }; - 9426682119DAC5A300B63EB5 /* ttmac.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ttmac.cpp; sourceTree = ""; }; - 9426682219DAC5A300B63EB5 /* twofish.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = twofish.cpp; sourceTree = ""; }; - 9426682419DAC5A300B63EB5 /* vmac.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = vmac.cpp; sourceTree = ""; }; - 9426682519DAC5A300B63EB5 /* wait.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = wait.cpp; sourceTree = ""; }; - 9426682719DAC5A300B63EB5 /* whrlpool.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = whrlpool.cpp; sourceTree = ""; }; - 9426682819DAC5A300B63EB5 /* winpipes.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = winpipes.cpp; sourceTree = ""; }; - 9426682919DAC5A300B63EB5 /* xtr.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = xtr.cpp; sourceTree = ""; }; - 9426682A19DAC5A300B63EB5 /* xtrcrypt.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = xtrcrypt.cpp; sourceTree = ""; }; - 9426682B19DAC5A300B63EB5 /* zdeflate.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = zdeflate.cpp; sourceTree = ""; }; - 9426682C19DAC5A300B63EB5 /* zinflate.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = zinflate.cpp; sourceTree = ""; }; - 9426682D19DAC5A300B63EB5 /* zlib.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = zlib.cpp; sourceTree = ""; }; - 942668B319DAC5E600B63EB5 /* blowfish.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = blowfish.h; sourceTree = ""; }; - 942668B419DAC5E600B63EB5 /* config.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = config.h; sourceTree = ""; }; - 942668B519DAC5E600B63EB5 /* cryptlib.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cryptlib.h; sourceTree = ""; }; - 942668B619DAC5E600B63EB5 /* eccrypto.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = eccrypto.h; sourceTree = ""; }; - 942668B719DAC5E600B63EB5 /* factory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = factory.h; sourceTree = ""; }; - 942668B819DAC5E600B63EB5 /* gfpcrypt.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = gfpcrypt.h; sourceTree = ""; }; - 942668B919DAC5E600B63EB5 /* misc.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = misc.h; sourceTree = ""; }; - 942668BA19DAC5E600B63EB5 /* panama.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = panama.h; sourceTree = ""; }; - 942668BB19DAC5E600B63EB5 /* queue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = queue.h; sourceTree = ""; }; - 942668BC19DAC5E600B63EB5 /* rw.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = rw.h; sourceTree = ""; }; - 942668BD19DAC5E600B63EB5 /* secblock.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = secblock.h; sourceTree = ""; }; - 942668BE19DAC5E600B63EB5 /* sha3.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = sha3.h; sourceTree = ""; }; - 942668BF19DAC5E600B63EB5 /* validate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = validate.h; sourceTree = ""; }; - 942668C019DAC5E600B63EB5 /* 3way.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = 3way.h; sourceTree = ""; }; - 942668C119DAC5E600B63EB5 /* adler32.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = adler32.h; sourceTree = ""; }; - 942668C219DAC5E600B63EB5 /* aes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = aes.h; sourceTree = ""; }; - 942668C319DAC5E600B63EB5 /* algebra.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = algebra.h; sourceTree = ""; }; - 942668C419DAC5E600B63EB5 /* algparam.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = algparam.h; sourceTree = ""; }; - 942668C519DAC5E600B63EB5 /* arc4.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = arc4.h; sourceTree = ""; }; - 942668C619DAC5E600B63EB5 /* argnames.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = argnames.h; sourceTree = ""; }; - 942668C719DAC5E600B63EB5 /* asn.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = asn.h; sourceTree = ""; }; - 942668C819DAC5E600B63EB5 /* authenc.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = authenc.h; sourceTree = ""; }; - 942668C919DAC5E600B63EB5 /* base32.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = base32.h; sourceTree = ""; }; - 942668CA19DAC5E600B63EB5 /* base64.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = base64.h; sourceTree = ""; }; - 942668CB19DAC5E600B63EB5 /* basecode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = basecode.h; sourceTree = ""; }; - 942668CC19DAC5E600B63EB5 /* bench.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = bench.h; sourceTree = ""; }; - 942668CD19DAC5E600B63EB5 /* blumshub.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = blumshub.h; sourceTree = ""; }; - 942668CE19DAC5E600B63EB5 /* camellia.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = camellia.h; sourceTree = ""; }; - 942668CF19DAC5E600B63EB5 /* cast.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cast.h; sourceTree = ""; }; - 942668D019DAC5E600B63EB5 /* cbcmac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cbcmac.h; sourceTree = ""; }; - 942668D119DAC5E600B63EB5 /* ccm.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ccm.h; sourceTree = ""; }; - 942668D219DAC5E600B63EB5 /* channels.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = channels.h; sourceTree = ""; }; - 942668D319DAC5E600B63EB5 /* cmac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cmac.h; sourceTree = ""; }; - 942668D419DAC5E600B63EB5 /* cpu.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cpu.h; sourceTree = ""; }; - 942668D519DAC5E600B63EB5 /* crc.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = crc.h; sourceTree = ""; }; - 942668D619DAC5E600B63EB5 /* default.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = default.h; sourceTree = ""; }; - 942668D719DAC5E600B63EB5 /* des.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = des.h; sourceTree = ""; }; - 942668D819DAC5E600B63EB5 /* dh.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = dh.h; sourceTree = ""; }; - 942668D919DAC5E600B63EB5 /* dh2.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = dh2.h; sourceTree = ""; }; - 942668DA19DAC5E600B63EB5 /* dll.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = dll.h; sourceTree = ""; }; - 942668DB19DAC5E600B63EB5 /* dmac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = dmac.h; sourceTree = ""; }; - 942668DC19DAC5E600B63EB5 /* dsa.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = dsa.h; sourceTree = ""; }; - 942668DD19DAC5E600B63EB5 /* eax.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = eax.h; sourceTree = ""; }; - 942668DE19DAC5E600B63EB5 /* ec2n.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ec2n.h; sourceTree = ""; }; - 942668DF19DAC5E600B63EB5 /* ecp.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ecp.h; sourceTree = ""; }; - 942668E019DAC5E600B63EB5 /* elgamal.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = elgamal.h; sourceTree = ""; }; - 942668E119DAC5E600B63EB5 /* emsa2.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = emsa2.h; sourceTree = ""; }; - 942668E219DAC5E600B63EB5 /* eprecomp.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = eprecomp.h; sourceTree = ""; }; - 942668E319DAC5E600B63EB5 /* esign.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = esign.h; sourceTree = ""; }; - 942668E419DAC5E600B63EB5 /* files.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = files.h; sourceTree = ""; }; - 942668E519DAC5E600B63EB5 /* filters.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = filters.h; sourceTree = ""; }; - 942668E619DAC5E600B63EB5 /* fips140.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = fips140.h; sourceTree = ""; }; - 942668E719DAC5E600B63EB5 /* fltrimpl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = fltrimpl.h; sourceTree = ""; }; - 942668E819DAC5E600B63EB5 /* gcm.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = gcm.h; sourceTree = ""; }; - 942668E919DAC5E600B63EB5 /* gf2_32.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = gf2_32.h; sourceTree = ""; }; - 942668EA19DAC5E600B63EB5 /* gf2n.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = gf2n.h; sourceTree = ""; }; - 942668EB19DAC5E600B63EB5 /* gf256.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = gf256.h; sourceTree = ""; }; - 942668EC19DAC5E600B63EB5 /* gost.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = gost.h; sourceTree = ""; }; - 942668ED19DAC5E600B63EB5 /* gzip.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = gzip.h; sourceTree = ""; }; - 942668EE19DAC5E600B63EB5 /* hex.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = hex.h; sourceTree = ""; }; - 942668EF19DAC5E600B63EB5 /* hmac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = hmac.h; sourceTree = ""; }; - 942668F019DAC5E600B63EB5 /* hrtimer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = hrtimer.h; sourceTree = ""; }; - 942668F119DAC5E600B63EB5 /* ida.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ida.h; sourceTree = ""; }; - 942668F219DAC5E600B63EB5 /* idea.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = idea.h; sourceTree = ""; }; - 942668F319DAC5E600B63EB5 /* integer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = integer.h; sourceTree = ""; }; - 942668F419DAC5E600B63EB5 /* iterhash.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = iterhash.h; sourceTree = ""; }; - 942668F519DAC5E600B63EB5 /* lubyrack.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = lubyrack.h; sourceTree = ""; }; - 942668F619DAC5E600B63EB5 /* luc.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = luc.h; sourceTree = ""; }; - 942668F719DAC5E600B63EB5 /* mars.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = mars.h; sourceTree = ""; }; - 942668F819DAC5E600B63EB5 /* md2.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = md2.h; sourceTree = ""; }; - 942668F919DAC5E600B63EB5 /* md4.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = md4.h; sourceTree = ""; }; - 942668FA19DAC5E600B63EB5 /* md5.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = md5.h; sourceTree = ""; }; - 942668FB19DAC5E600B63EB5 /* mdc.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = mdc.h; sourceTree = ""; }; - 942668FC19DAC5E600B63EB5 /* modarith.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = modarith.h; sourceTree = ""; }; - 942668FD19DAC5E600B63EB5 /* modes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = modes.h; sourceTree = ""; }; - 942668FE19DAC5E600B63EB5 /* modexppc.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = modexppc.h; sourceTree = ""; }; - 942668FF19DAC5E600B63EB5 /* mqueue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = mqueue.h; sourceTree = ""; }; - 9426690019DAC5E600B63EB5 /* mqv.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = mqv.h; sourceTree = ""; }; - 9426690119DAC5E600B63EB5 /* nbtheory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = nbtheory.h; sourceTree = ""; }; - 9426690219DAC5E600B63EB5 /* network.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = network.h; sourceTree = ""; }; - 9426690319DAC5E600B63EB5 /* nr.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = nr.h; sourceTree = ""; }; - 9426690419DAC5E600B63EB5 /* oaep.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = oaep.h; sourceTree = ""; }; - 9426690519DAC5E600B63EB5 /* oids.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = oids.h; sourceTree = ""; }; - 9426690619DAC5E600B63EB5 /* osrng.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = osrng.h; sourceTree = ""; }; - 9426690719DAC5E600B63EB5 /* pch.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = pch.h; sourceTree = ""; }; - 9426690819DAC5E600B63EB5 /* pkcspad.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = pkcspad.h; sourceTree = ""; }; - 9426690919DAC5E600B63EB5 /* polynomi.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = polynomi.h; sourceTree = ""; }; - 9426690A19DAC5E600B63EB5 /* pssr.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = pssr.h; sourceTree = ""; }; - 9426690B19DAC5E600B63EB5 /* pubkey.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = pubkey.h; sourceTree = ""; }; - 9426690C19DAC5E600B63EB5 /* pwdbased.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = pwdbased.h; sourceTree = ""; }; - 9426690D19DAC5E600B63EB5 /* rabin.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = rabin.h; sourceTree = ""; }; - 9426690E19DAC5E600B63EB5 /* randpool.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = randpool.h; sourceTree = ""; }; - 9426690F19DAC5E600B63EB5 /* rc2.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = rc2.h; sourceTree = ""; }; - 9426691019DAC5E600B63EB5 /* rc5.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = rc5.h; sourceTree = ""; }; - 9426691119DAC5E600B63EB5 /* rc6.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = rc6.h; sourceTree = ""; }; - 9426691219DAC5E600B63EB5 /* resource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = resource.h; sourceTree = ""; }; - 9426691319DAC5E600B63EB5 /* rijndael.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = rijndael.h; sourceTree = ""; }; - 9426691419DAC5E600B63EB5 /* ripemd.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ripemd.h; sourceTree = ""; }; - 9426691519DAC5E600B63EB5 /* rng.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = rng.h; sourceTree = ""; }; - 9426691619DAC5E600B63EB5 /* rsa.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = rsa.h; sourceTree = ""; }; - 9426691719DAC5E600B63EB5 /* safer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = safer.h; sourceTree = ""; }; - 9426691819DAC5E600B63EB5 /* salsa.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = salsa.h; sourceTree = ""; }; - 9426691919DAC5E600B63EB5 /* seal.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = seal.h; sourceTree = ""; }; - 9426691A19DAC5E600B63EB5 /* seckey.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = seckey.h; sourceTree = ""; }; - 9426691B19DAC5E600B63EB5 /* seed.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = seed.h; sourceTree = ""; }; - 9426691C19DAC5E600B63EB5 /* serpent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = serpent.h; sourceTree = ""; }; - 9426691D19DAC5E600B63EB5 /* serpentp.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = serpentp.h; sourceTree = ""; }; - 9426691E19DAC5E600B63EB5 /* sha.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = sha.h; sourceTree = ""; }; - 9426691F19DAC5E600B63EB5 /* shacal2.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = shacal2.h; sourceTree = ""; }; - 9426692019DAC5E600B63EB5 /* shark.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = shark.h; sourceTree = ""; }; - 9426692119DAC5E600B63EB5 /* simple.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = simple.h; sourceTree = ""; }; - 9426692219DAC5E600B63EB5 /* skipjack.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = skipjack.h; sourceTree = ""; }; - 9426692319DAC5E600B63EB5 /* smartptr.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = smartptr.h; sourceTree = ""; }; - 9426692419DAC5E600B63EB5 /* socketft.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = socketft.h; sourceTree = ""; }; - 9426692519DAC5E600B63EB5 /* sosemanuk.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = sosemanuk.h; sourceTree = ""; }; - 9426692619DAC5E600B63EB5 /* square.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = square.h; sourceTree = ""; }; - 9426692719DAC5E600B63EB5 /* stdcpp.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = stdcpp.h; sourceTree = ""; }; - 9426692819DAC5E600B63EB5 /* strciphr.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = strciphr.h; sourceTree = ""; }; - 9426692919DAC5E600B63EB5 /* tea.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = tea.h; sourceTree = ""; }; - 9426692A19DAC5E600B63EB5 /* tiger.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = tiger.h; sourceTree = ""; }; - 9426692B19DAC5E600B63EB5 /* trdlocal.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = trdlocal.h; sourceTree = ""; }; - 9426692C19DAC5E600B63EB5 /* trunhash.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = trunhash.h; sourceTree = ""; }; - 9426692D19DAC5E600B63EB5 /* ttmac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ttmac.h; sourceTree = ""; }; - 9426692E19DAC5E600B63EB5 /* twofish.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = twofish.h; sourceTree = ""; }; - 9426692F19DAC5E600B63EB5 /* vmac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = vmac.h; sourceTree = ""; }; - 9426693019DAC5E600B63EB5 /* wait.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = wait.h; sourceTree = ""; }; - 9426693119DAC5E600B63EB5 /* wake.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = wake.h; sourceTree = ""; }; - 9426693219DAC5E600B63EB5 /* whrlpool.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = whrlpool.h; sourceTree = ""; }; - 9426693319DAC5E600B63EB5 /* winpipes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = winpipes.h; sourceTree = ""; }; - 9426693419DAC5E600B63EB5 /* words.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = words.h; sourceTree = ""; }; - 9426693519DAC5E600B63EB5 /* xtr.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = xtr.h; sourceTree = ""; }; - 9426693619DAC5E600B63EB5 /* xtrcrypt.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = xtrcrypt.h; sourceTree = ""; }; - 9426693719DAC5E600B63EB5 /* zdeflate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = zdeflate.h; sourceTree = ""; }; - 9426693819DAC5E600B63EB5 /* zinflate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = zinflate.h; sourceTree = ""; }; - 9426693919DAC5E600B63EB5 /* zlib.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = zlib.h; sourceTree = ""; }; -/* End PBXFileReference section */ - -/* Begin PBXFrameworksBuildPhase section */ - 9426679119DAC3F500B63EB5 /* Frameworks */ = { - isa = PBXFrameworksBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXFrameworksBuildPhase section */ - -/* Begin PBXGroup section */ - 9426678619DAC20200B63EB5 = { - isa = PBXGroup; - children = ( - 9426679619DAC3F500B63EB5 /* cryptopp */, - 9426679519DAC3F500B63EB5 /* Products */, - ); - sourceTree = ""; - }; - 9426679519DAC3F500B63EB5 /* Products */ = { - isa = PBXGroup; - children = ( - 9426679419DAC3F500B63EB5 /* libcryptopp.a */, - ); - name = Products; - sourceTree = ""; - }; - 9426679619DAC3F500B63EB5 /* cryptopp */ = { - isa = PBXGroup; - children = ( - 41ACFBC41A11524C00905ACF /* wake.cpp */, - 942668B319DAC5E600B63EB5 /* blowfish.h */, - 942668B419DAC5E600B63EB5 /* config.h */, - 942668B519DAC5E600B63EB5 /* cryptlib.h */, - 942668B619DAC5E600B63EB5 /* eccrypto.h */, - 942668B719DAC5E600B63EB5 /* factory.h */, - 942668B819DAC5E600B63EB5 /* gfpcrypt.h */, - 942668B919DAC5E600B63EB5 /* misc.h */, - 942668BA19DAC5E600B63EB5 /* panama.h */, - 942668BB19DAC5E600B63EB5 /* queue.h */, - 942668BC19DAC5E600B63EB5 /* rw.h */, - 942668BD19DAC5E600B63EB5 /* secblock.h */, - 942668BE19DAC5E600B63EB5 /* sha3.h */, - 942668BF19DAC5E600B63EB5 /* validate.h */, - 942668C019DAC5E600B63EB5 /* 3way.h */, - 942668C119DAC5E600B63EB5 /* adler32.h */, - 942668C219DAC5E600B63EB5 /* aes.h */, - 942668C319DAC5E600B63EB5 /* algebra.h */, - 942668C419DAC5E600B63EB5 /* algparam.h */, - 942668C519DAC5E600B63EB5 /* arc4.h */, - 942668C619DAC5E600B63EB5 /* argnames.h */, - 942668C719DAC5E600B63EB5 /* asn.h */, - 942668C819DAC5E600B63EB5 /* authenc.h */, - 942668C919DAC5E600B63EB5 /* base32.h */, - 942668CA19DAC5E600B63EB5 /* base64.h */, - 942668CB19DAC5E600B63EB5 /* basecode.h */, - 942668CC19DAC5E600B63EB5 /* bench.h */, - 942668CD19DAC5E600B63EB5 /* blumshub.h */, - 942668CE19DAC5E600B63EB5 /* camellia.h */, - 942668CF19DAC5E600B63EB5 /* cast.h */, - 942668D019DAC5E600B63EB5 /* cbcmac.h */, - 942668D119DAC5E600B63EB5 /* ccm.h */, - 942668D219DAC5E600B63EB5 /* channels.h */, - 942668D319DAC5E600B63EB5 /* cmac.h */, - 942668D419DAC5E600B63EB5 /* cpu.h */, - 942668D519DAC5E600B63EB5 /* crc.h */, - 942668D619DAC5E600B63EB5 /* default.h */, - 942668D719DAC5E600B63EB5 /* des.h */, - 942668D819DAC5E600B63EB5 /* dh.h */, - 942668D919DAC5E600B63EB5 /* dh2.h */, - 942668DA19DAC5E600B63EB5 /* dll.h */, - 942668DB19DAC5E600B63EB5 /* dmac.h */, - 942668DC19DAC5E600B63EB5 /* dsa.h */, - 942668DD19DAC5E600B63EB5 /* eax.h */, - 942668DE19DAC5E600B63EB5 /* ec2n.h */, - 942668DF19DAC5E600B63EB5 /* ecp.h */, - 942668E019DAC5E600B63EB5 /* elgamal.h */, - 942668E119DAC5E600B63EB5 /* emsa2.h */, - 942668E219DAC5E600B63EB5 /* eprecomp.h */, - 942668E319DAC5E600B63EB5 /* esign.h */, - 942668E419DAC5E600B63EB5 /* files.h */, - 942668E519DAC5E600B63EB5 /* filters.h */, - 942668E619DAC5E600B63EB5 /* fips140.h */, - 942668E719DAC5E600B63EB5 /* fltrimpl.h */, - 942668E819DAC5E600B63EB5 /* gcm.h */, - 942668E919DAC5E600B63EB5 /* gf2_32.h */, - 942668EA19DAC5E600B63EB5 /* gf2n.h */, - 942668EB19DAC5E600B63EB5 /* gf256.h */, - 942668EC19DAC5E600B63EB5 /* gost.h */, - 942668ED19DAC5E600B63EB5 /* gzip.h */, - 942668EE19DAC5E600B63EB5 /* hex.h */, - 942668EF19DAC5E600B63EB5 /* hmac.h */, - 942668F019DAC5E600B63EB5 /* hrtimer.h */, - 942668F119DAC5E600B63EB5 /* ida.h */, - 942668F219DAC5E600B63EB5 /* idea.h */, - 942668F319DAC5E600B63EB5 /* integer.h */, - 942668F419DAC5E600B63EB5 /* iterhash.h */, - 942668F519DAC5E600B63EB5 /* lubyrack.h */, - 942668F619DAC5E600B63EB5 /* luc.h */, - 942668F719DAC5E600B63EB5 /* mars.h */, - 942668F819DAC5E600B63EB5 /* md2.h */, - 942668F919DAC5E600B63EB5 /* md4.h */, - 942668FA19DAC5E600B63EB5 /* md5.h */, - 942668FB19DAC5E600B63EB5 /* mdc.h */, - 942668FC19DAC5E600B63EB5 /* modarith.h */, - 942668FD19DAC5E600B63EB5 /* modes.h */, - 942668FE19DAC5E600B63EB5 /* modexppc.h */, - 942668FF19DAC5E600B63EB5 /* mqueue.h */, - 9426690019DAC5E600B63EB5 /* mqv.h */, - 9426690119DAC5E600B63EB5 /* nbtheory.h */, - 9426690219DAC5E600B63EB5 /* network.h */, - 9426690319DAC5E600B63EB5 /* nr.h */, - 9426690419DAC5E600B63EB5 /* oaep.h */, - 9426690519DAC5E600B63EB5 /* oids.h */, - 9426690619DAC5E600B63EB5 /* osrng.h */, - 9426690719DAC5E600B63EB5 /* pch.h */, - 9426690819DAC5E600B63EB5 /* pkcspad.h */, - 9426690919DAC5E600B63EB5 /* polynomi.h */, - 9426690A19DAC5E600B63EB5 /* pssr.h */, - 9426690B19DAC5E600B63EB5 /* pubkey.h */, - 9426690C19DAC5E600B63EB5 /* pwdbased.h */, - 9426690D19DAC5E600B63EB5 /* rabin.h */, - 9426690E19DAC5E600B63EB5 /* randpool.h */, - 9426690F19DAC5E600B63EB5 /* rc2.h */, - 9426691019DAC5E600B63EB5 /* rc5.h */, - 9426691119DAC5E600B63EB5 /* rc6.h */, - 9426691219DAC5E600B63EB5 /* resource.h */, - 9426691319DAC5E600B63EB5 /* rijndael.h */, - 9426691419DAC5E600B63EB5 /* ripemd.h */, - 9426691519DAC5E600B63EB5 /* rng.h */, - 9426691619DAC5E600B63EB5 /* rsa.h */, - 9426691719DAC5E600B63EB5 /* safer.h */, - 9426691819DAC5E600B63EB5 /* salsa.h */, - 9426691919DAC5E600B63EB5 /* seal.h */, - 9426691A19DAC5E600B63EB5 /* seckey.h */, - 9426691B19DAC5E600B63EB5 /* seed.h */, - 9426691C19DAC5E600B63EB5 /* serpent.h */, - 9426691D19DAC5E600B63EB5 /* serpentp.h */, - 9426691E19DAC5E600B63EB5 /* sha.h */, - 9426691F19DAC5E600B63EB5 /* shacal2.h */, - 9426692019DAC5E600B63EB5 /* shark.h */, - 9426692119DAC5E600B63EB5 /* simple.h */, - 9426692219DAC5E600B63EB5 /* skipjack.h */, - 9426692319DAC5E600B63EB5 /* smartptr.h */, - 9426692419DAC5E600B63EB5 /* socketft.h */, - 9426692519DAC5E600B63EB5 /* sosemanuk.h */, - 9426692619DAC5E600B63EB5 /* square.h */, - 9426692719DAC5E600B63EB5 /* stdcpp.h */, - 9426692819DAC5E600B63EB5 /* strciphr.h */, - 9426692919DAC5E600B63EB5 /* tea.h */, - 9426692A19DAC5E600B63EB5 /* tiger.h */, - 9426692B19DAC5E600B63EB5 /* trdlocal.h */, - 9426692C19DAC5E600B63EB5 /* trunhash.h */, - 9426692D19DAC5E600B63EB5 /* ttmac.h */, - 9426692E19DAC5E600B63EB5 /* twofish.h */, - 9426692F19DAC5E600B63EB5 /* vmac.h */, - 9426693019DAC5E600B63EB5 /* wait.h */, - 9426693119DAC5E600B63EB5 /* wake.h */, - 9426693219DAC5E600B63EB5 /* whrlpool.h */, - 9426693319DAC5E600B63EB5 /* winpipes.h */, - 9426693419DAC5E600B63EB5 /* words.h */, - 9426693519DAC5E600B63EB5 /* xtr.h */, - 9426693619DAC5E600B63EB5 /* xtrcrypt.h */, - 9426693719DAC5E600B63EB5 /* zdeflate.h */, - 9426693819DAC5E600B63EB5 /* zinflate.h */, - 9426693919DAC5E600B63EB5 /* zlib.h */, - 942667A919DAC5A300B63EB5 /* algebra.cpp */, - 942667AD19DAC5A300B63EB5 /* dsa.cpp */, - 942667AE19DAC5A300B63EB5 /* eccrypto.cpp */, - 942667AF19DAC5A300B63EB5 /* gfpcrypt.cpp */, - 942667B019DAC5A300B63EB5 /* osrng.cpp */, - 942667B119DAC5A300B63EB5 /* panama.cpp */, - 942667B319DAC5A300B63EB5 /* rijndael.cpp */, - 942667B419DAC5A300B63EB5 /* salsa.cpp */, - 942667B519DAC5A300B63EB5 /* sha3.cpp */, - 942667B819DAC5A300B63EB5 /* 3way.cpp */, - 942667B919DAC5A300B63EB5 /* adler32.cpp */, - 942667BA19DAC5A300B63EB5 /* algparam.cpp */, - 942667BB19DAC5A300B63EB5 /* arc4.cpp */, - 942667BC19DAC5A300B63EB5 /* asn.cpp */, - 942667BD19DAC5A300B63EB5 /* authenc.cpp */, - 942667BE19DAC5A300B63EB5 /* base32.cpp */, - 942667BF19DAC5A300B63EB5 /* base64.cpp */, - 942667C019DAC5A300B63EB5 /* basecode.cpp */, - 942667C119DAC5A300B63EB5 /* bfinit.cpp */, - 942667C219DAC5A300B63EB5 /* blowfish.cpp */, - 942667C319DAC5A300B63EB5 /* blumshub.cpp */, - 942667C419DAC5A300B63EB5 /* camellia.cpp */, - 942667C519DAC5A300B63EB5 /* cast.cpp */, - 942667C619DAC5A300B63EB5 /* casts.cpp */, - 942667C719DAC5A300B63EB5 /* cbcmac.cpp */, - 942667C819DAC5A300B63EB5 /* ccm.cpp */, - 942667C919DAC5A300B63EB5 /* channels.cpp */, - 942667CA19DAC5A300B63EB5 /* cmac.cpp */, - 942667CB19DAC5A300B63EB5 /* cpu.cpp */, - 942667CC19DAC5A300B63EB5 /* crc.cpp */, - 942667CD19DAC5A300B63EB5 /* cryptlib_bds.cpp */, - 942667CE19DAC5A300B63EB5 /* cryptlib.cpp */, - 942667CF19DAC5A300B63EB5 /* default.cpp */, - 942667D019DAC5A300B63EB5 /* des.cpp */, - 942667D119DAC5A300B63EB5 /* dessp.cpp */, - 942667D219DAC5A300B63EB5 /* dh.cpp */, - 942667D319DAC5A300B63EB5 /* dh2.cpp */, - 942667D419DAC5A300B63EB5 /* dll.cpp */, - 942667D619DAC5A300B63EB5 /* eax.cpp */, - 942667D719DAC5A300B63EB5 /* ec2n.cpp */, - 942667D819DAC5A300B63EB5 /* ecp.cpp */, - 942667D919DAC5A300B63EB5 /* elgamal.cpp */, - 942667DA19DAC5A300B63EB5 /* emsa2.cpp */, - 942667DB19DAC5A300B63EB5 /* eprecomp.cpp */, - 942667DC19DAC5A300B63EB5 /* esign.cpp */, - 942667DD19DAC5A300B63EB5 /* files.cpp */, - 942667DE19DAC5A300B63EB5 /* filters.cpp */, - 942667DF19DAC5A300B63EB5 /* fips140.cpp */, - 942667E019DAC5A300B63EB5 /* fipsalgt.cpp */, - 942667E219DAC5A300B63EB5 /* gcm.cpp */, - 942667E319DAC5A300B63EB5 /* gf2_32.cpp */, - 942667E419DAC5A300B63EB5 /* gf2n.cpp */, - 942667E519DAC5A300B63EB5 /* gf256.cpp */, - 942667E619DAC5A300B63EB5 /* gost.cpp */, - 942667E719DAC5A300B63EB5 /* gzip.cpp */, - 942667E819DAC5A300B63EB5 /* hex.cpp */, - 942667E919DAC5A300B63EB5 /* hmac.cpp */, - 942667EA19DAC5A300B63EB5 /* hrtimer.cpp */, - 942667EB19DAC5A300B63EB5 /* ida.cpp */, - 942667EC19DAC5A300B63EB5 /* idea.cpp */, - 942667ED19DAC5A300B63EB5 /* integer.cpp */, - 942667EE19DAC5A300B63EB5 /* iterhash.cpp */, - 942667EF19DAC5A300B63EB5 /* luc.cpp */, - 942667F019DAC5A300B63EB5 /* mars.cpp */, - 942667F119DAC5A300B63EB5 /* marss.cpp */, - 942667F219DAC5A300B63EB5 /* md2.cpp */, - 942667F319DAC5A300B63EB5 /* md4.cpp */, - 942667F419DAC5A300B63EB5 /* md5.cpp */, - 942667F519DAC5A300B63EB5 /* misc.cpp */, - 942667F619DAC5A300B63EB5 /* modes.cpp */, - 942667F719DAC5A300B63EB5 /* mqueue.cpp */, - 942667F819DAC5A300B63EB5 /* mqv.cpp */, - 942667F919DAC5A300B63EB5 /* nbtheory.cpp */, - 942667FA19DAC5A300B63EB5 /* network.cpp */, - 942667FB19DAC5A300B63EB5 /* oaep.cpp */, - 942667FC19DAC5A300B63EB5 /* pch.cpp */, - 942667FD19DAC5A300B63EB5 /* pkcspad.cpp */, - 942667FE19DAC5A300B63EB5 /* polynomi.cpp */, - 942667FF19DAC5A300B63EB5 /* pssr.cpp */, - 9426680019DAC5A300B63EB5 /* pubkey.cpp */, - 9426680119DAC5A300B63EB5 /* queue.cpp */, - 9426680219DAC5A300B63EB5 /* rabin.cpp */, - 9426680319DAC5A300B63EB5 /* randpool.cpp */, - 9426680419DAC5A300B63EB5 /* rc2.cpp */, - 9426680519DAC5A300B63EB5 /* rc5.cpp */, - 9426680619DAC5A300B63EB5 /* rc6.cpp */, - 9426680719DAC5A300B63EB5 /* rdtables.cpp */, - 9426680819DAC5A300B63EB5 /* ripemd.cpp */, - 9426680919DAC5A300B63EB5 /* rng.cpp */, - 9426680A19DAC5A300B63EB5 /* rsa.cpp */, - 9426680B19DAC5A300B63EB5 /* rw.cpp */, - 9426680C19DAC5A300B63EB5 /* safer.cpp */, - 9426680D19DAC5A300B63EB5 /* seal.cpp */, - 9426680E19DAC5A300B63EB5 /* seed.cpp */, - 9426680F19DAC5A300B63EB5 /* serpent.cpp */, - 9426681019DAC5A300B63EB5 /* sha.cpp */, - 9426681119DAC5A300B63EB5 /* shacal2.cpp */, - 9426681219DAC5A300B63EB5 /* shark.cpp */, - 9426681319DAC5A300B63EB5 /* sharkbox.cpp */, - 9426681419DAC5A300B63EB5 /* simple.cpp */, - 9426681519DAC5A300B63EB5 /* skipjack.cpp */, - 9426681619DAC5A300B63EB5 /* socketft.cpp */, - 9426681719DAC5A300B63EB5 /* sosemanuk.cpp */, - 9426681819DAC5A300B63EB5 /* square.cpp */, - 9426681919DAC5A300B63EB5 /* squaretb.cpp */, - 9426681A19DAC5A300B63EB5 /* strciphr.cpp */, - 9426681B19DAC5A300B63EB5 /* tea.cpp */, - 9426681D19DAC5A300B63EB5 /* tftables.cpp */, - 9426681E19DAC5A300B63EB5 /* tiger.cpp */, - 9426681F19DAC5A300B63EB5 /* tigertab.cpp */, - 9426682019DAC5A300B63EB5 /* trdlocal.cpp */, - 9426682119DAC5A300B63EB5 /* ttmac.cpp */, - 9426682219DAC5A300B63EB5 /* twofish.cpp */, - 9426682419DAC5A300B63EB5 /* vmac.cpp */, - 9426682519DAC5A300B63EB5 /* wait.cpp */, - 9426682719DAC5A300B63EB5 /* whrlpool.cpp */, - 9426682819DAC5A300B63EB5 /* winpipes.cpp */, - 9426682919DAC5A300B63EB5 /* xtr.cpp */, - 9426682A19DAC5A300B63EB5 /* xtrcrypt.cpp */, - 9426682B19DAC5A300B63EB5 /* zdeflate.cpp */, - 9426682C19DAC5A300B63EB5 /* zinflate.cpp */, - 9426682D19DAC5A300B63EB5 /* zlib.cpp */, - ); - path = cryptopp; - sourceTree = ""; - }; -/* End PBXGroup section */ - -/* Begin PBXNativeTarget section */ - 9426679319DAC3F500B63EB5 /* cryptopp */ = { - isa = PBXNativeTarget; - buildConfigurationList = 942667A719DAC3F500B63EB5 /* Build configuration list for PBXNativeTarget "cryptopp" */; - buildPhases = ( - 9426679019DAC3F500B63EB5 /* Sources */, - 9426679119DAC3F500B63EB5 /* Frameworks */, - 9426679219DAC3F500B63EB5 /* CopyFiles */, - ); - buildRules = ( - ); - dependencies = ( - ); - name = cryptopp; - productName = cryptopp; - productReference = 9426679419DAC3F500B63EB5 /* libcryptopp.a */; - productType = "com.apple.product-type.library.static"; - }; -/* End PBXNativeTarget section */ - -/* Begin PBXProject section */ - 9426678719DAC20200B63EB5 /* Project object */ = { - isa = PBXProject; - attributes = { - LastUpgradeCheck = 0600; - TargetAttributes = { - 9426679319DAC3F500B63EB5 = { - CreatedOnToolsVersion = 6.0.1; - }; - }; - }; - buildConfigurationList = 9426678A19DAC20200B63EB5 /* Build configuration list for PBXProject "cryptopp" */; - compatibilityVersion = "Xcode 3.2"; - developmentRegion = English; - hasScannedForEncodings = 0; - knownRegions = ( - en, - ); - mainGroup = 9426678619DAC20200B63EB5; - productRefGroup = 9426679519DAC3F500B63EB5 /* Products */; - projectDirPath = ""; - projectRoot = ""; - targets = ( - 9426679319DAC3F500B63EB5 /* cryptopp */, - ); - }; -/* End PBXProject section */ - -/* Begin PBXSourcesBuildPhase section */ - 9426679019DAC3F500B63EB5 /* Sources */ = { - isa = PBXSourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - 942668AE19DAC5A300B63EB5 /* xtr.cpp in Sources */, - 9426685D19DAC5A300B63EB5 /* ecp.cpp in Sources */, - 942668B119DAC5A300B63EB5 /* zinflate.cpp in Sources */, - 9426685819DAC5A300B63EB5 /* dh2.cpp in Sources */, - 9426686C19DAC5A300B63EB5 /* gzip.cpp in Sources */, - 9426688119DAC5A300B63EB5 /* pch.cpp in Sources */, - 9426686E19DAC5A300B63EB5 /* hmac.cpp in Sources */, - 9426684219DAC5A300B63EB5 /* authenc.cpp in Sources */, - 942668AF19DAC5A300B63EB5 /* xtrcrypt.cpp in Sources */, - 9426683319DAC5A300B63EB5 /* eccrypto.cpp in Sources */, - 9426686119DAC5A300B63EB5 /* esign.cpp in Sources */, - 9426689319DAC5A300B63EB5 /* seed.cpp in Sources */, - 942668A619DAC5A300B63EB5 /* ttmac.cpp in Sources */, - 9426687219DAC5A300B63EB5 /* integer.cpp in Sources */, - 9426686419DAC5A300B63EB5 /* fips140.cpp in Sources */, - 942668A719DAC5A300B63EB5 /* twofish.cpp in Sources */, - 9426685719DAC5A300B63EB5 /* dh.cpp in Sources */, - 942668B019DAC5A300B63EB5 /* zdeflate.cpp in Sources */, - 9426684F19DAC5A300B63EB5 /* cmac.cpp in Sources */, - 9426684519DAC5A300B63EB5 /* basecode.cpp in Sources */, - 942668A219DAC5A300B63EB5 /* tftables.cpp in Sources */, - 9426684B19DAC5A300B63EB5 /* casts.cpp in Sources */, - 9426684A19DAC5A300B63EB5 /* cast.cpp in Sources */, - 9426684119DAC5A300B63EB5 /* asn.cpp in Sources */, - 9426687119DAC5A300B63EB5 /* idea.cpp in Sources */, - 9426685F19DAC5A300B63EB5 /* emsa2.cpp in Sources */, - 942668A919DAC5A300B63EB5 /* vmac.cpp in Sources */, - 9426689919DAC5A300B63EB5 /* simple.cpp in Sources */, - 9426684C19DAC5A300B63EB5 /* cbcmac.cpp in Sources */, - 9426687519DAC5A300B63EB5 /* mars.cpp in Sources */, - 942668AA19DAC5A300B63EB5 /* wait.cpp in Sources */, - 9426684919DAC5A300B63EB5 /* camellia.cpp in Sources */, - 9426688919DAC5A300B63EB5 /* rc2.cpp in Sources */, - 942668A419DAC5A300B63EB5 /* tigertab.cpp in Sources */, - 9426688C19DAC5A300B63EB5 /* rdtables.cpp in Sources */, - 9426686719DAC5A300B63EB5 /* gcm.cpp in Sources */, - 9426686A19DAC5A300B63EB5 /* gf256.cpp in Sources */, - 9426683919DAC5A300B63EB5 /* salsa.cpp in Sources */, - 9426689F19DAC5A300B63EB5 /* strciphr.cpp in Sources */, - 9426688D19DAC5A300B63EB5 /* ripemd.cpp in Sources */, - 9426688319DAC5A300B63EB5 /* polynomi.cpp in Sources */, - 9426684319DAC5A300B63EB5 /* base32.cpp in Sources */, - 9426688619DAC5A300B63EB5 /* queue.cpp in Sources */, - 9426688019DAC5A300B63EB5 /* oaep.cpp in Sources */, - 9426689219DAC5A300B63EB5 /* seal.cpp in Sources */, - 9426684D19DAC5A300B63EB5 /* ccm.cpp in Sources */, - 9426689519DAC5A300B63EB5 /* sha.cpp in Sources */, - 942668AC19DAC5A300B63EB5 /* whrlpool.cpp in Sources */, - 9426684619DAC5A300B63EB5 /* bfinit.cpp in Sources */, - 9426683A19DAC5A300B63EB5 /* sha3.cpp in Sources */, - 9426689419DAC5A300B63EB5 /* serpent.cpp in Sources */, - 9426687419DAC5A300B63EB5 /* luc.cpp in Sources */, - 9426686219DAC5A300B63EB5 /* files.cpp in Sources */, - 9426687019DAC5A300B63EB5 /* ida.cpp in Sources */, - 9426689D19DAC5A300B63EB5 /* square.cpp in Sources */, - 9426687B19DAC5A300B63EB5 /* modes.cpp in Sources */, - 9426684419DAC5A300B63EB5 /* base64.cpp in Sources */, - 9426683619DAC5A300B63EB5 /* panama.cpp in Sources */, - 9426683519DAC5A300B63EB5 /* osrng.cpp in Sources */, - 9426687A19DAC5A300B63EB5 /* misc.cpp in Sources */, - 9426687F19DAC5A300B63EB5 /* network.cpp in Sources */, - 9426686019DAC5A300B63EB5 /* eprecomp.cpp in Sources */, - 9426685619DAC5A300B63EB5 /* dessp.cpp in Sources */, - 9426688F19DAC5A300B63EB5 /* rsa.cpp in Sources */, - 942668A519DAC5A300B63EB5 /* trdlocal.cpp in Sources */, - 9426684719DAC5A300B63EB5 /* blowfish.cpp in Sources */, - 9426688719DAC5A300B63EB5 /* rabin.cpp in Sources */, - 9426689819DAC5A300B63EB5 /* sharkbox.cpp in Sources */, - 9426686519DAC5A300B63EB5 /* fipsalgt.cpp in Sources */, - 9426688419DAC5A300B63EB5 /* pssr.cpp in Sources */, - 9426688B19DAC5A300B63EB5 /* rc6.cpp in Sources */, - 9426689119DAC5A300B63EB5 /* safer.cpp in Sources */, - 9426687719DAC5A300B63EB5 /* md2.cpp in Sources */, - 9426687819DAC5A300B63EB5 /* md4.cpp in Sources */, - 9426682E19DAC5A300B63EB5 /* algebra.cpp in Sources */, - 9426687E19DAC5A300B63EB5 /* nbtheory.cpp in Sources */, - 9426689019DAC5A300B63EB5 /* rw.cpp in Sources */, - 9426686F19DAC5A300B63EB5 /* hrtimer.cpp in Sources */, - 9426683419DAC5A300B63EB5 /* gfpcrypt.cpp in Sources */, - 9426688219DAC5A300B63EB5 /* pkcspad.cpp in Sources */, - 9426683819DAC5A300B63EB5 /* rijndael.cpp in Sources */, - 9426687619DAC5A300B63EB5 /* marss.cpp in Sources */, - 9426685C19DAC5A300B63EB5 /* ec2n.cpp in Sources */, - 9426686919DAC5A300B63EB5 /* gf2n.cpp in Sources */, - 9426688A19DAC5A300B63EB5 /* rc5.cpp in Sources */, - 9426685119DAC5A300B63EB5 /* crc.cpp in Sources */, - 9426683219DAC5A300B63EB5 /* dsa.cpp in Sources */, - 9426689A19DAC5A300B63EB5 /* skipjack.cpp in Sources */, - 9426683F19DAC5A300B63EB5 /* algparam.cpp in Sources */, - 9426686319DAC5A300B63EB5 /* filters.cpp in Sources */, - 9426684019DAC5A300B63EB5 /* arc4.cpp in Sources */, - 9426685B19DAC5A300B63EB5 /* eax.cpp in Sources */, - 9426685519DAC5A300B63EB5 /* des.cpp in Sources */, - 9426687D19DAC5A300B63EB5 /* mqv.cpp in Sources */, - 9426683E19DAC5A300B63EB5 /* adler32.cpp in Sources */, - 9426684819DAC5A300B63EB5 /* blumshub.cpp in Sources */, - 9426689C19DAC5A300B63EB5 /* sosemanuk.cpp in Sources */, - 9426685319DAC5A300B63EB5 /* cryptlib.cpp in Sources */, - 9426688819DAC5A300B63EB5 /* randpool.cpp in Sources */, - 9426688E19DAC5A300B63EB5 /* rng.cpp in Sources */, - 942668B219DAC5A300B63EB5 /* zlib.cpp in Sources */, - 41ACFBC51A11524C00905ACF /* wake.cpp in Sources */, - 9426686819DAC5A300B63EB5 /* gf2_32.cpp in Sources */, - 9426685419DAC5A300B63EB5 /* default.cpp in Sources */, - 9426689619DAC5A300B63EB5 /* shacal2.cpp in Sources */, - 942668AD19DAC5A300B63EB5 /* winpipes.cpp in Sources */, - 9426684E19DAC5A300B63EB5 /* channels.cpp in Sources */, - 9426683D19DAC5A300B63EB5 /* 3way.cpp in Sources */, - 9426687319DAC5A300B63EB5 /* iterhash.cpp in Sources */, - 9426685919DAC5A300B63EB5 /* dll.cpp in Sources */, - 9426685E19DAC5A300B63EB5 /* elgamal.cpp in Sources */, - 9426687919DAC5A300B63EB5 /* md5.cpp in Sources */, - 9426685019DAC5A300B63EB5 /* cpu.cpp in Sources */, - 9426689E19DAC5A300B63EB5 /* squaretb.cpp in Sources */, - 9426688519DAC5A300B63EB5 /* pubkey.cpp in Sources */, - 9426689719DAC5A300B63EB5 /* shark.cpp in Sources */, - 9426686D19DAC5A300B63EB5 /* hex.cpp in Sources */, - 9426687C19DAC5A300B63EB5 /* mqueue.cpp in Sources */, - 9426686B19DAC5A300B63EB5 /* gost.cpp in Sources */, - 942668A019DAC5A300B63EB5 /* tea.cpp in Sources */, - 942668A319DAC5A300B63EB5 /* tiger.cpp in Sources */, - 9426689B19DAC5A300B63EB5 /* socketft.cpp in Sources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXSourcesBuildPhase section */ - -/* Begin XCBuildConfiguration section */ - 9426678B19DAC20200B63EB5 /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - }; - name = Debug; - }; - 9426678C19DAC20200B63EB5 /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - }; - name = Release; - }; - 942667A319DAC3F500B63EB5 /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; - CLANG_CXX_LIBRARY = "libc++"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - COPY_PHASE_STRIP = NO; - ENABLE_STRICT_OBJC_MSGSEND = YES; - GCC_C_LANGUAGE_STANDARD = gnu99; - GCC_DYNAMIC_NO_PIC = NO; - GCC_OPTIMIZATION_LEVEL = 0; - GCC_PREPROCESSOR_DEFINITIONS = ( - "DEBUG=1", - "$(inherited)", - ); - "GCC_PREPROCESSOR_DEFINITIONS[arch=*]" = ( - "DEBUG=1", - "$(inherited)", - CRYPTOPP_DISABLE_X86ASM, - ); - GCC_SYMBOLS_PRIVATE_EXTERN = NO; - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 8.0; - MTL_ENABLE_DEBUG_INFO = YES; - ONLY_ACTIVE_ARCH = YES; - OTHER_CPLUSPLUSFLAGS = ( - "$(OTHER_CFLAGS)", - "-Wno-c++11-narrowing", - ); - OTHER_LDFLAGS = "-ObjC"; - PRODUCT_NAME = "$(TARGET_NAME)"; - SDKROOT = iphoneos; - SKIP_INSTALL = YES; - }; - name = Debug; - }; - 942667A419DAC3F500B63EB5 /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; - CLANG_CXX_LIBRARY = "libc++"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - COPY_PHASE_STRIP = YES; - ENABLE_NS_ASSERTIONS = NO; - ENABLE_STRICT_OBJC_MSGSEND = YES; - GCC_C_LANGUAGE_STANDARD = gnu99; - GCC_PREPROCESSOR_DEFINITIONS = CRYPTOPP_DISABLE_X86ASM; - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 8.0; - MTL_ENABLE_DEBUG_INFO = NO; - OTHER_CPLUSPLUSFLAGS = ( - "$(OTHER_CFLAGS)", - "-Wno-c++11-narrowing", - ); - OTHER_LDFLAGS = "-ObjC"; - PRODUCT_NAME = "$(TARGET_NAME)"; - SDKROOT = iphoneos; - SKIP_INSTALL = YES; - VALIDATE_PRODUCT = YES; - }; - name = Release; - }; -/* End XCBuildConfiguration section */ - -/* Begin XCConfigurationList section */ - 9426678A19DAC20200B63EB5 /* Build configuration list for PBXProject "cryptopp" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 9426678B19DAC20200B63EB5 /* Debug */, - 9426678C19DAC20200B63EB5 /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; - 942667A719DAC3F500B63EB5 /* Build configuration list for PBXNativeTarget "cryptopp" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 942667A319DAC3F500B63EB5 /* Debug */, - 942667A419DAC3F500B63EB5 /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; -/* End XCConfigurationList section */ - }; - rootObject = 9426678719DAC20200B63EB5 /* Project object */; -} diff --git a/bindings/ios/3rdparty/cryptopp.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/bindings/ios/3rdparty/cryptopp.xcodeproj/project.xcworkspace/contents.xcworkspacedata deleted file mode 100644 index 437ecf1bc3..0000000000 --- a/bindings/ios/3rdparty/cryptopp.xcodeproj/project.xcworkspace/contents.xcworkspacedata +++ /dev/null @@ -1,7 +0,0 @@ - - - - - diff --git a/bindings/ios/3rdparty/cryptopp.xcodeproj/project.xcworkspace/xcuserdata/MEGA.xcuserdatad/UserInterfaceState.xcuserstate b/bindings/ios/3rdparty/cryptopp.xcodeproj/project.xcworkspace/xcuserdata/MEGA.xcuserdatad/UserInterfaceState.xcuserstate deleted file mode 100644 index f339bbb2a8..0000000000 Binary files a/bindings/ios/3rdparty/cryptopp.xcodeproj/project.xcworkspace/xcuserdata/MEGA.xcuserdatad/UserInterfaceState.xcuserstate and /dev/null differ diff --git a/bindings/ios/3rdparty/cryptopp.xcodeproj/project.xcworkspace/xcuserdata/MEGA.xcuserdatad/WorkspaceSettings.xcsettings b/bindings/ios/3rdparty/cryptopp.xcodeproj/project.xcworkspace/xcuserdata/MEGA.xcuserdatad/WorkspaceSettings.xcsettings deleted file mode 100644 index bfffcfe01a..0000000000 --- a/bindings/ios/3rdparty/cryptopp.xcodeproj/project.xcworkspace/xcuserdata/MEGA.xcuserdatad/WorkspaceSettings.xcsettings +++ /dev/null @@ -1,10 +0,0 @@ - - - - - HasAskedToTakeAutomaticSnapshotBeforeSignificantChanges - - SnapshotAutomaticallyBeforeSignificantChanges - - - diff --git a/bindings/ios/3rdparty/cryptopp.xcodeproj/xcuserdata/MEGA.xcuserdatad/xcschemes/cares.xcscheme b/bindings/ios/3rdparty/cryptopp.xcodeproj/xcuserdata/MEGA.xcuserdatad/xcschemes/cares.xcscheme deleted file mode 100644 index 25b50be062..0000000000 --- a/bindings/ios/3rdparty/cryptopp.xcodeproj/xcuserdata/MEGA.xcuserdatad/xcschemes/cares.xcscheme +++ /dev/null @@ -1,77 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/bindings/ios/3rdparty/cryptopp.xcodeproj/xcuserdata/MEGA.xcuserdatad/xcschemes/caresTests.xcscheme b/bindings/ios/3rdparty/cryptopp.xcodeproj/xcuserdata/MEGA.xcuserdatad/xcschemes/caresTests.xcscheme deleted file mode 100644 index 669226087a..0000000000 --- a/bindings/ios/3rdparty/cryptopp.xcodeproj/xcuserdata/MEGA.xcuserdatad/xcschemes/caresTests.xcscheme +++ /dev/null @@ -1,96 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/bindings/ios/3rdparty/cryptopp.xcodeproj/xcuserdata/MEGA.xcuserdatad/xcschemes/cryptopp.xcscheme b/bindings/ios/3rdparty/cryptopp.xcodeproj/xcuserdata/MEGA.xcuserdatad/xcschemes/cryptopp.xcscheme deleted file mode 100644 index d4db4aa850..0000000000 --- a/bindings/ios/3rdparty/cryptopp.xcodeproj/xcuserdata/MEGA.xcuserdatad/xcschemes/cryptopp.xcscheme +++ /dev/null @@ -1,77 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/bindings/ios/3rdparty/cryptopp.xcodeproj/xcuserdata/MEGA.xcuserdatad/xcschemes/cryptoppTests.xcscheme b/bindings/ios/3rdparty/cryptopp.xcodeproj/xcuserdata/MEGA.xcuserdatad/xcschemes/cryptoppTests.xcscheme deleted file mode 100644 index 4809bb34e9..0000000000 --- a/bindings/ios/3rdparty/cryptopp.xcodeproj/xcuserdata/MEGA.xcuserdatad/xcschemes/cryptoppTests.xcscheme +++ /dev/null @@ -1,96 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/bindings/ios/3rdparty/cryptopp.xcodeproj/xcuserdata/MEGA.xcuserdatad/xcschemes/xcschememanagement.plist b/bindings/ios/3rdparty/cryptopp.xcodeproj/xcuserdata/MEGA.xcuserdatad/xcschemes/xcschememanagement.plist deleted file mode 100644 index 281a51d802..0000000000 --- a/bindings/ios/3rdparty/cryptopp.xcodeproj/xcuserdata/MEGA.xcuserdatad/xcschemes/xcschememanagement.plist +++ /dev/null @@ -1,52 +0,0 @@ - - - - - SchemeUserState - - cares.xcscheme - - orderHint - 3 - - caresTests.xcscheme - - orderHint - 4 - - cryptopp.xcscheme - - orderHint - 1 - - cryptoppTests.xcscheme - - orderHint - 2 - - - SuppressBuildableAutocreation - - 9426679319DAC3F500B63EB5 - - primary - - - 9426679E19DAC3F500B63EB5 - - primary - - - 9426694619DAD21700B63EB5 - - primary - - - 9426695019DAD21700B63EB5 - - primary - - - - - diff --git a/bindings/ios/MEGASdk.h b/bindings/ios/MEGASdk.h index 0971246e2b..e7513a584b 100644 --- a/bindings/ios/MEGASdk.h +++ b/bindings/ios/MEGASdk.h @@ -97,7 +97,8 @@ typedef NS_ENUM(NSInteger, MEGAUserAttribute) { MEGAUserAttributeRichPreviews = 18, // private - byte array MEGAUserAttributeRubbishTime = 19, // private - byte array MEGAUserAttributeLastPSA = 20, // private - char array - MEGAUserAttributeStorageState = 21 // private - char array + MEGAUserAttributeStorageState = 21, // private - char array + MEGAUserAttributeGeolocation = 22 // private - char array }; typedef NS_ENUM(NSInteger, MEGANodeAttribute) { @@ -3051,6 +3052,8 @@ typedef NS_ENUM(NSUInteger, StorageState) { * Get number of days for rubbish-bin cleaning scheduler (private, non-encrypted) * MEGAUserAttributeStorageState = 21 * Get the state of the storage (private non-encrypted) + * MEGAUserAttributeGeolocation = 22 + * Get whether the user has enabled send geolocation messages (private) * */ - (void)getUserAttributeForUser:(MEGAUser *)user type:(MEGAUserAttribute)type; @@ -3102,6 +3105,8 @@ typedef NS_ENUM(NSUInteger, StorageState) { * Get number of days for rubbish-bin cleaning scheduler (private, non-encrypted) * MEGAUserAttributeStorageState = 21 * Get the state of the storage (private non-encrypted) + * MEGAUserAttributeGeolocation = 22 + * Get whether the user has enabled send geolocation messages (private) * * @param delegate MEGARequestDelegate to track this request */ @@ -3157,6 +3162,8 @@ typedef NS_ENUM(NSUInteger, StorageState) { * Get number of days for rubbish-bin cleaning scheduler (private, non-encrypted) * MEGAUserAttributeStorageState = 21 * Get the state of the storage (private non-encrypted) + * MEGAUserAttributeGeolocation = 22 + * Get whether the user has enabled send geolocation messages (private) * */ - (void)getUserAttributeForEmailOrHandle:(NSString *)emailOrHandle type:(MEGAUserAttribute)type; @@ -3211,6 +3218,8 @@ typedef NS_ENUM(NSUInteger, StorageState) { * Get number of days for rubbish-bin cleaning scheduler (private, non-encrypted) * MEGAUserAttributeStorageState = 21 * Get the state of the storage (private non-encrypted) + * MEGAUserAttributeGeolocation = 22 + * Get whether the user has enabled send geolocation messages (private) * * @param delegate MEGARequestDelegate to track this request */ @@ -3264,6 +3273,8 @@ typedef NS_ENUM(NSUInteger, StorageState) { * Get number of days for rubbish-bin cleaning scheduler (private, non-encrypted) * MEGAUserAttributeStorageState = 21 * Get the state of the storage (private non-encrypted) + * MEGAUserAttributeGeolocation = 22 + * Get whether the user has enabled send geolocation messages (private) * */ - (void)getUserAttributeType:(MEGAUserAttribute)type; @@ -3316,6 +3327,8 @@ typedef NS_ENUM(NSUInteger, StorageState) { * Get number of days for rubbish-bin cleaning scheduler (private, non-encrypted) * MEGAUserAttributeStorageState = 21 * Get the state of the storage (private non-encrypted) + * MEGAUserAttributeGeolocation = 22 + * Get whether the user has enabled send geolocation messages (private) * * @param delegate MEGARequestDelegate to track this request */ @@ -3925,6 +3938,54 @@ typedef NS_ENUM(NSUInteger, StorageState) { */ - (void)setRichLinkWarningCounterValue:(NSUInteger)value; +/** + * @brief Enable the sending of geolocation messages + * + * The associated request type with this request is MEGARequestTypeSetAttrUser + * Valid data in the MEGARequest object received on callbacks: + * - [MEGARequest paramType] - Returns the attribute type MEGAUserAttributeGeolocation + * + * @param delegate MEGARequestDelegate to track this request + */ +- (void)enableGeolocationWithDelegate:(id)delegate; + +/** + * @brief Enable the sending of geolocation messages + * + * The associated request type with this request is MEGARequestTypeSetAttrUser + * Valid data in the MEGARequest object received on callbacks: + * - [MEGARequest paramType] - Returns the attribute type MEGAUserAttributeGeolocation + */ +- (void)enableGeolocation; + +/** + * @brief Check if the sending of geolocation messages is enabled + * + * The associated request type with this request is MEGARequestTypeSetAttrUser + * Valid data in the MEGARequest object received on callbacks: + * - [MEGARequest paramType] - Returns the attribute type MEGAUserAttributeGeolocation + * + * Sending a Geolocation message is enabled if the MEGARequest object, received in onRequestFinish, + * has error code MEGAErrorTypeApiOk. In other cases, send geolocation messages is not enabled and + * the application has to answer before send a message of this type. + * + * @param delegate MEGARequestDelegate to track this request + */ +- (void)isGeolocationEnabledWithDelegate:(id)delegate; + +/** + * @brief Check if the sending of geolocation messages is enabled + * + * The associated request type with this request is MEGARequestTypeSetAttrUser + * Valid data in the MEGARequest object received on callbacks: + * - [MEGARequest paramType] - Returns the attribute type MEGAUserAttributeGeolocation + * + * Sending a Geolocation message is enabled if the MEGARequest object, received in onRequestFinish, + * has error code MEGAErrorTypeApiOk. In other cases, send geolocation messages is not enabled and + * the application has to answer before send a message of this type. + */ +- (void)isGeolocationEnabled; + /** * @brief Get the number of days for rubbish-bin cleaning scheduler * diff --git a/bindings/ios/MEGASdk.mm b/bindings/ios/MEGASdk.mm index 9f0d7e503f..081684d701 100644 --- a/bindings/ios/MEGASdk.mm +++ b/bindings/ios/MEGASdk.mm @@ -1194,6 +1194,22 @@ - (void)setRichLinkWarningCounterValue:(NSUInteger)value { self.megaApi->setRichLinkWarningCounterValue((int)value); } +- (void)enableGeolocationWithDelegate:(id)delegate { + self.megaApi->enableGeolocation([self createDelegateMEGARequestListener:delegate singleListener:YES]); +} + +- (void)enableGeolocation { + self.megaApi->enableGeolocation(); +} + +- (void)isGeolocationEnabledWithDelegate:(id)delegate { + self.megaApi->isGeolocationEnabled([self createDelegateMEGARequestListener:delegate singleListener:YES]); +} + +- (void)isGeolocationEnabled { + self.megaApi->isGeolocationEnabled(); +} + - (void)getRubbishBinAutopurgePeriodWithDelegate:(id)delegate { self.megaApi->getRubbishBinAutopurgePeriod([self createDelegateMEGARequestListener:delegate singleListener:YES]); } diff --git a/bindings/ios/MEGAUser.h b/bindings/ios/MEGAUser.h index deea295961..69248055ed 100644 --- a/bindings/ios/MEGAUser.h +++ b/bindings/ios/MEGAUser.h @@ -48,7 +48,8 @@ typedef NS_ENUM(NSInteger, MEGAUserChangeType) { MEGAUserChangeTypeContactLinkVerification = 0x10000, MEGAUserChangeTypeRichPreviews = 0x20000, MEGAUserChangeTypeRubbishTime = 0x40000, - MEGAUserChangeTypeStorageState = 0x80000 + MEGAUserChangeTypeStorageState = 0x80000, + MEGAUserChangeTypeGeolocation = 0x100000, }; @@ -174,6 +175,9 @@ typedef NS_ENUM(NSInteger, MEGAUserChangeType) { * - MEGAUserChangeTypeStorageState = 0x80000 * Check if the state of the storage has changed * + * - MEGAUserChangeTypeGeolocation = 0x100000 + * Check if option for geolocation messages has changed + * */ @property (readonly, nonatomic) MEGAUserChangeType changes; @@ -264,6 +268,9 @@ typedef NS_ENUM(NSInteger, MEGAUserChangeType) { * - MEGAUserChangeTypeStorageState = 0x80000 * Check if the state of the storage has changed * + * - MEGAUserChangeTypeGeolocation = 0x100000 + * Check if option for geolocation messages has changed + * * @return YES if this user has an specific change */ - (BOOL)hasChangedType:(MEGAUserChangeType)changeType; diff --git a/bindings/java/nz/mega/sdk/MegaApiJava.java b/bindings/java/nz/mega/sdk/MegaApiJava.java index 7610482a98..8ae3b13612 100644 --- a/bindings/java/nz/mega/sdk/MegaApiJava.java +++ b/bindings/java/nz/mega/sdk/MegaApiJava.java @@ -95,6 +95,7 @@ void runCallback(Runnable runnable) { public final static int USER_ATTR_RUBBISH_TIME = MegaApi.USER_ATTR_RUBBISH_TIME; public final static int USER_ATTR_LAST_PSA = MegaApi.USER_ATTR_LAST_PSA; public final static int USER_ATTR_STORAGE_STATE = MegaApi.USER_ATTR_STORAGE_STATE; + public final static int USER_ATTR_GEOLOCATION = MegaApi.USER_ATTR_GEOLOCATION; public final static int NODE_ATTR_DURATION = MegaApi.NODE_ATTR_DURATION; public final static int NODE_ATTR_COORDINATES = MegaApi.NODE_ATTR_COORDINATES; @@ -2904,7 +2905,8 @@ public String getUserAvatarColor(String userhandle){ * Get number of days for rubbish-bin cleaning scheduler (private non-encrypted) * MegaApi::USER_ATTR_STORAGE_STATE = 21 * Get the state of the storage (private non-encrypted) - * + * MegaApi::USER_ATTR_GEOLOCATION = 22 + * Get whether the user has enabled send geolocation messages (private) * @param listener MegaRequestListener to track this request */ public void getUserAttribute(MegaUser user, int type, MegaRequestListenerInterface listener) { @@ -2962,6 +2964,8 @@ public void getUserAttribute(MegaUser user, int type, MegaRequestListenerInterfa * Get number of days for rubbish-bin cleaning scheduler (private non-encrypted) * MegaApi::USER_ATTR_STORAGE_STATE = 21 * Get the state of the storage (private non-encrypted) + * MegaApi::USER_ATTR_GEOLOCATION = 22 + * Get whether the user has enabled send geolocation messages (private) */ public void getUserAttribute(MegaUser user, int type) { megaApi.getUserAttribute(user, type); @@ -3017,7 +3021,8 @@ public void getUserAttribute(MegaUser user, int type) { * Get number of days for rubbish-bin cleaning scheduler (private non-encrypted) * MegaApi::USER_ATTR_STORAGE_STATE = 21 * Get the state of the storage (private non-encrypted) - * + * MegaApi::USER_ATTR_GEOLOCATION = 22 + * Get whether the user has enabled send geolocation messages (private) * @param listener MegaRequestListener to track this request */ public void getUserAttribute(String email_or_handle, int type, MegaRequestListenerInterface listener) { @@ -3074,6 +3079,8 @@ public void getUserAttribute(String email_or_handle, int type, MegaRequestListen * Get number of days for rubbish-bin cleaning scheduler (private non-encrypted) * MegaApi::USER_ATTR_STORAGE_STATE = 21 * Get the state of the storage (private non-encrypted) + * MegaApi::USER_ATTR_GEOLOCATION = 22 + * Get whether the user has enabled send geolocation messages (private) */ public void getUserAttribute(String email_or_handle, int type) { megaApi.getUserAttribute(email_or_handle, type); @@ -3128,7 +3135,8 @@ public void getUserAttribute(String email_or_handle, int type) { * Get number of days for rubbish-bin cleaning scheduler (private non-encrypted) * MegaApi::USER_ATTR_STORAGE_STATE = 21 * Get the state of the storage (private non-encrypted) - * + * MegaApi::USER_ATTR_GEOLOCATION = 22 + * Get whether the user has enabled send geolocation messages (private) * @param listener MegaRequestListener to track this request */ public void getUserAttribute(int type, MegaRequestListenerInterface listener) { @@ -3184,6 +3192,8 @@ public void getUserAttribute(int type, MegaRequestListenerInterface listener) { * Get number of days for rubbish-bin cleaning scheduler (private non-encrypted) * MegaApi::USER_ATTR_STORAGE_STATE = 21 * Get the state of the storage (private non-encrypted) + * MegaApi::USER_ATTR_GEOLOCATION = 22 + * Get whether the user has enabled send geolocation messages (private) */ public void getUserAttribute(int type) { megaApi.getUserAttribute(type); @@ -4316,6 +4326,36 @@ public void setRichLinkWarningCounterValue(int value){ megaApi.setRichLinkWarningCounterValue(value); } + /** + * Enable the sending of geolocation messages + * + * The associated request type with this request is MegaRequest::TYPE_SET_ATTR_USER + * Valid data in the MegaRequest object received on callbacks: + * - MegaRequest::getParamType - Returns the attribute type MegaApi::USER_ATTR_GEOLOCATION + * + * @param listener MegaRequestListener to track this request + */ + public void enableGeolocation(MegaRequestListenerInterface listener){ + megaApi.enableGeolocation(createDelegateRequestListener(listener)); + } + + /** + * Check if the sending of geolocation messages is enabled + * + * The associated request type with this request is MegaRequest::TYPE_GET_ATTR_USER + * Valid data in the MegaRequest object received on callbacks: + * - MegaRequest::getParamType - Returns the attribute type MegaApi::USER_ATTR_GEOLOCATION + * + * Sending a Geolocation message is enabled if the MegaRequest object, received in onRequestFinish, + * has error code MegaError::API_OK. In other cases, send geolocation messages is not enabled and + * the application has to answer before send a message of this type. + * + * @param listener MegaRequestListener to track this request + */ + public void isGeolocationEnabled(MegaRequestListenerInterface listener){ + megaApi.isGeolocationEnabled(createDelegateRequestListener(listener)); + } + /** * Get the number of days for rubbish-bin cleaning scheduler * diff --git a/bindings/qt/sdk.pri b/bindings/qt/sdk.pri index 0a78bfd3d9..f5f0d71161 100644 --- a/bindings/qt/sdk.pri +++ b/bindings/qt/sdk.pri @@ -66,9 +66,36 @@ CONFIG(USE_AUTOCOMPLETE) { } } -CONFIG(USE_LIBWEBSOCKETS) { +CONFIG(USE_CONSOLE) { + win32 { + + HEADERS += include/mega/win32/megaconsole.h + HEADERS += include/mega/win32/megaconsolewaiter.h + + CONFIG(noreadline) { + DEFINES += NO_READLINE + SOURCES += src/win32/console.cpp + SOURCES += src/win32/consolewaiter.cpp + } + else { + DEFINES += USE_READLINE_STATIC + SOURCES += src/wincurl/console.cpp + SOURCES += src/wincurl/consolewaiter.cpp + LIBS += -lreadline + } + QMAKE_CXXFLAGS+=/Zc:__cplusplus /std:c++ #this will set _cplusplus correctly in MSVC >= 2017 15.7 Preview 3 + } + else { + HEADERS += include/mega/posix/megaconsole.h + HEADERS += include/mega/posix/megaconsolewaiter.h + SOURCES += src/posix/console.cpp + SOURCES += src/posix/consolewaiter.cpp + LIBS += -lreadline + } +} + +CONFIG(ENABLE_CHAT) { CONFIG += USE_LIBUV - DEFINES += USE_LIBWEBSOCKETS=1 !macx { exists($$MEGASDK_BASE_PATH/bindings/qt/3rdparty/libs/libwebsockets.a) { @@ -341,9 +368,7 @@ CONFIG(USE_MEGAAPI) { win32 { HEADERS += include/mega/win32/megasys.h \ include/mega/win32/megafs.h \ - include/mega/win32/megawaiter.h \ - include/mega/win32/megaconsole.h \ - include/mega/win32/megaconsolewaiter.h + include/mega/win32/megawaiter.h SOURCES += bindings/qt/3rdparty/libs/sqlite3.c } diff --git a/bindings/wp8/MegaSDK.cpp b/bindings/wp8/MegaSDK.cpp index fdd7e8362c..2545f53b6c 100644 --- a/bindings/wp8/MegaSDK.cpp +++ b/bindings/wp8/MegaSDK.cpp @@ -378,6 +378,22 @@ void MegaSDK::setStatsID(String^ id) MegaApi::setStatsID((id != nullptr) ? utf8id.c_str() : NULL); } +void MegaSDK::setDnsServers(String^ dnsServers, MRequestListenerInterface^ listener) +{ + std::string utf8dnsServers; + if (dnsServers != nullptr) + MegaApi::utf16ToUtf8(dnsServers->Data(), dnsServers->Length(), &utf8dnsServers); + + megaApi->setDnsServers( + (dnsServers != nullptr) ? utf8dnsServers.c_str() : NULL, + createDelegateMRequestListener(listener)); +} + +void MegaSDK::setDnsServers(String^ dnsServers) +{ + this->setDnsServers(dnsServers, nullptr); +} + bool MegaSDK::serverSideRubbishBinAutopurgeEnabled() { return megaApi->serverSideRubbishBinAutopurgeEnabled(); diff --git a/bindings/wp8/MegaSDK.h b/bindings/wp8/MegaSDK.h index 73cec7eef2..05f9269cbc 100644 --- a/bindings/wp8/MegaSDK.h +++ b/bindings/wp8/MegaSDK.h @@ -199,6 +199,54 @@ namespace mega void reconnect(); static void setStatsID(String^ id); + /** + * @brief Use custom DNS servers + * + * The SDK tries to automatically get and use DNS servers configured in the system at startup. This function can be used + * to override that automatic detection and use a custom list of DNS servers. It is also useful to provide working + * DNS servers to the SDK in platforms in which it can't get them from the system (Windows Phone and Universal Windows Platform). + * + * Since the usage of this function implies a change in DNS servers used by the SDK, all connections are + * closed and restarted using the new list of new DNS servers, so calling this function too often can cause + * many retries and problems to complete requests. Please use it only at startup or when DNS servers need to be changed. + * + * The associated request type with this request is MRequest::TYPE_RETRY_PENDING_CONNECTIONS. + * Valid data in the MRequest object received on callbacks: + * - MRequest::getText - Returns the new list of DNS servers + * + * @param dnsServers New list of DNS servers. It must be a list of IPs separated by a comma character ",". + * IPv6 servers are allowed (without brackets). + * + * The usage of this function will trigger the callback MGlobalListener::onEvent and the callback + * MListener::onEvent with the event type MEvent::EVENT_DISCONNECT. + * + * @param listener MRequestListener to track this request + */ + void setDnsServers(String^ dnsServers, MRequestListenerInterface^ listener); + + /** + * @brief Use custom DNS servers + * + * The SDK tries to automatically get and use DNS servers configured in the system at startup. This function can be used + * to override that automatic detection and use a custom list of DNS servers. It is also useful to provide working + * DNS servers to the SDK in platforms in which it can't get them from the system (Windows Phone and Universal Windows Platform). + * + * Since the usage of this function implies a change in DNS servers used by the SDK, all connections are + * closed and restarted using the new list of new DNS servers, so calling this function too often can cause + * many retries and problems to complete requests. Please use it only at startup or when DNS servers need to be changed. + * + * The associated request type with this request is MRequest::TYPE_RETRY_PENDING_CONNECTIONS. + * Valid data in the MRequest object received on callbacks: + * - MRequest::getText - Returns the new list of DNS servers + * + * @param dnsServers New list of DNS servers. It must be a list of IPs separated by a comma character ",". + * IPv6 servers are allowed (without brackets). + * + * The usage of this function will trigger the callback MGlobalListener::onEvent and the callback + * MListener::onEvent with the event type MEvent::EVENT_DISCONNECT. + */ + void setDnsServers(String^ dnsServers); + /** * @brief Check if server-side Rubbish Bin autopurging is enabled for the current account * @return True if this feature is enabled. Otherwise false. diff --git a/contrib/QtCreator/MEGACli/MEGACli.pro b/contrib/QtCreator/MEGACli/MEGACli.pro index f653db132f..0310004272 100644 --- a/contrib/QtCreator/MEGACli/MEGACli.pro +++ b/contrib/QtCreator/MEGACli/MEGACli.pro @@ -13,31 +13,11 @@ CONFIG += console CONFIG += noreadline win32 { - DEFINES += USE_READLINE_STATIC DEFINES += __STDC_LIMIT_MACROS #this is required to include or - CONFIG(noreadline) { - DEFINES += NO_READLINE - } } -LIBS += -lreadline - CONFIG += USE_AUTOCOMPLETE -win32 { - CONFIG(noreadline) { - SOURCES += ../../../src/win32/console.cpp - SOURCES += ../../../src/win32/consolewaiter.cpp - } - else { - SOURCES += ../../../src/wincurl/console.cpp - SOURCES += ../../../src/wincurl/consolewaiter.cpp - } - QMAKE_CXXFLAGS+=/Zc:__cplusplus /std:c++ #this will set _cplusplus correctly in MSVC >= 2017 15.7 Preview 3 -} -else { - SOURCES += ../../../src/posix/console.cpp - SOURCES += ../../../src/posix/consolewaiter.cpp -} +CONFIG += USE_CONSOLE SOURCES += ../../../examples/megacli.cpp HEADERS += ../../../examples/megacli.h diff --git a/contrib/QtCreator/MEGATests/MEGATests.pro b/contrib/QtCreator/MEGATests/MEGATests.pro new file mode 100644 index 0000000000..9ecaecc75b --- /dev/null +++ b/contrib/QtCreator/MEGATests/MEGATests.pro @@ -0,0 +1,28 @@ + + +CONFIG(debug, debug|release) { + CONFIG -= debug release + CONFIG += debug +} +CONFIG(release, debug|release) { + CONFIG -= debug release + CONFIG += release +} + +TARGET = MEGASyncTests +TEMPLATE = app + +CONFIG += USE_AUTOCOMPLETE +CONFIG += USE_MEDIAINFO +CONFIG += USE_LIBRAW +CONFIG += USE_FFMPEG + +CONFIG += c++17 +LIBS+=-lstdc++fs +QMAKE_CXXFLAGS+=-std=c++17 + +LIBS+=-lgtest + +include(../../../bindings/qt/sdk.pri) +SOURCES += ../../../tests/synctests.cpp + diff --git a/examples/Swift/MEGA/MEGA.xcodeproj/project.pbxproj b/examples/Swift/MEGA/MEGA.xcodeproj/project.pbxproj index 18a27eccab..329dde571b 100644 --- a/examples/Swift/MEGA/MEGA.xcodeproj/project.pbxproj +++ b/examples/Swift/MEGA/MEGA.xcodeproj/project.pbxproj @@ -24,7 +24,6 @@ 41ABFDF11CBB942D00CC9D71 /* CoreMedia.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 41ABFDF01CBB942D00CC9D71 /* CoreMedia.framework */; }; 41B4A5B51A5E94B8008B6E73 /* Helper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 41B4A5B41A5E94B8008B6E73 /* Helper.swift */; }; 41B4A5BA1A5EF067008B6E73 /* DetailsNodeInfoViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 41B4A5B91A5EF067008B6E73 /* DetailsNodeInfoViewController.swift */; }; - 41C346BC1B4C47C9002091F8 /* libMEGASDK.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 41C346BB1B4C47C9002091F8 /* libMEGASDK.a */; }; 41C6A0441A5FD13300865971 /* Offline.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 41C6A0431A5FD13300865971 /* Offline.storyboard */; }; 41C6A0461A5FD15B00865971 /* OfflineTableViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 41C6A0451A5FD15B00865971 /* OfflineTableViewController.swift */; }; 41C6A0491A5FF8CC00865971 /* Settings.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 41C6A0481A5FF8CC00865971 /* Settings.storyboard */; }; @@ -34,24 +33,20 @@ 41F175791A51E22500570E30 /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = 41F175771A51E22500570E30 /* LaunchScreen.xib */; }; 41F175A01A51F17E00570E30 /* ImageIO.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 41F1759F1A51F17E00570E30 /* ImageIO.framework */; }; 41F175A21A51F18B00570E30 /* MobileCoreServices.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 41F175A11A51F18B00570E30 /* MobileCoreServices.framework */; }; - 41F175A41A51F19F00570E30 /* libresolv.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 41F175A31A51F19F00570E30 /* libresolv.dylib */; }; - 41F175A61A51F1AF00570E30 /* libc++.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 41F175A51A51F1AF00570E30 /* libc++.dylib */; }; - 41F175A81A51F1B700570E30 /* libz.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 41F175A71A51F1B700570E30 /* libz.dylib */; }; - 41F175AA1A51F1C200570E30 /* libsqlite3.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 41F175A91A51F1C200570E30 /* libsqlite3.dylib */; }; - A88EE20C1F0A62AF00AECF76 /* libcares.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2051F0A62AF00AECF76 /* libcares.a */; }; - A88EE20D1F0A62AF00AECF76 /* libcrypto.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2061F0A62AF00AECF76 /* libcrypto.a */; }; - A88EE20E1F0A62AF00AECF76 /* libcryptopp.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2071F0A62AF00AECF76 /* libcryptopp.a */; }; - A88EE20F1F0A62AF00AECF76 /* libcurl.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2081F0A62AF00AECF76 /* libcurl.a */; }; - A88EE2101F0A62AF00AECF76 /* libssl.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2091F0A62AF00AECF76 /* libssl.a */; }; - A88EE2111F0A62AF00AECF76 /* libuv.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE20A1F0A62AF00AECF76 /* libuv.a */; }; - A88EE2121F0A62AF00AECF76 /* libsodium.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE20B1F0A62AF00AECF76 /* libsodium.a */; }; - A88EE22D1F0A648600AECF76 /* libcares.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2261F0A648600AECF76 /* libcares.a */; }; - A88EE22E1F0A648600AECF76 /* libcrypto.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2271F0A648600AECF76 /* libcrypto.a */; }; - A88EE22F1F0A648600AECF76 /* libcryptopp.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2281F0A648600AECF76 /* libcryptopp.a */; }; - A88EE2301F0A648600AECF76 /* libcurl.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2291F0A648600AECF76 /* libcurl.a */; }; - A88EE2311F0A648600AECF76 /* libsodium.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE22A1F0A648600AECF76 /* libsodium.a */; }; - A88EE2321F0A648600AECF76 /* libssl.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE22B1F0A648600AECF76 /* libssl.a */; }; - A88EE2331F0A648600AECF76 /* libuv.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE22C1F0A648600AECF76 /* libuv.a */; }; + A8BF109621ED0BD8006B283A /* libsodium.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF108D21ED0BD7006B283A /* libsodium.a */; }; + A8BF109721ED0BD8006B283A /* libuv.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF108E21ED0BD7006B283A /* libuv.a */; }; + A8BF109821ED0BD8006B283A /* libcrypto.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF108F21ED0BD7006B283A /* libcrypto.a */; }; + A8BF109921ED0BD8006B283A /* libcryptopp.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF109021ED0BD7006B283A /* libcryptopp.a */; }; + A8BF109A21ED0BD8006B283A /* libcurl.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF109121ED0BD8006B283A /* libcurl.a */; }; + A8BF109B21ED0BD8006B283A /* libssl.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF109221ED0BD8006B283A /* libssl.a */; }; + A8BF109C21ED0BD8006B283A /* libzen.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF109321ED0BD8006B283A /* libzen.a */; }; + A8BF109D21ED0BD8006B283A /* libmediainfo.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF109421ED0BD8006B283A /* libmediainfo.a */; }; + A8BF109E21ED0BD8006B283A /* libcares.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF109521ED0BD8006B283A /* libcares.a */; }; + A8BF10A021ED0BF7006B283A /* libMEGASDK.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF109F21ED0BF7006B283A /* libMEGASDK.a */; }; + A8BF10A221ED0CF9006B283A /* libc++.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF10A121ED0CF9006B283A /* libc++.tbd */; }; + A8BF10A421ED0D04006B283A /* libsqlite3.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF10A321ED0D04006B283A /* libsqlite3.tbd */; }; + A8BF10A621ED0D0D006B283A /* libz.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF10A521ED0D0D006B283A /* libz.tbd */; }; + A8BF10A821ED0D15006B283A /* libresolv.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF10A721ED0D15006B283A /* libresolv.tbd */; }; /* End PBXBuildFile section */ /* Begin PBXFileReference section */ @@ -76,7 +71,6 @@ 41ABFDF01CBB942D00CC9D71 /* CoreMedia.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreMedia.framework; path = System/Library/Frameworks/CoreMedia.framework; sourceTree = SDKROOT; }; 41B4A5B41A5E94B8008B6E73 /* Helper.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Helper.swift; sourceTree = ""; }; 41B4A5B91A5EF067008B6E73 /* DetailsNodeInfoViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = DetailsNodeInfoViewController.swift; path = ../CloudDrive/DetailsNodeInfoViewController.swift; sourceTree = ""; }; - 41C346BB1B4C47C9002091F8 /* libMEGASDK.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libMEGASDK.a; path = "../../../bindings/ios/build/Debug-iphoneos/libMEGASDK.a"; sourceTree = ""; }; 41C6A0431A5FD13300865971 /* Offline.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = Offline.storyboard; sourceTree = ""; }; 41C6A0451A5FD15B00865971 /* OfflineTableViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = OfflineTableViewController.swift; sourceTree = ""; }; 41C6A0481A5FF8CC00865971 /* Settings.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = Settings.storyboard; sourceTree = ""; }; @@ -86,28 +80,23 @@ 41F1756E1A51E22500570E30 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; 41F175751A51E22500570E30 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = ""; }; 41F175781A51E22500570E30 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/LaunchScreen.xib; sourceTree = ""; }; - 41F175901A51E3A500570E30 /* libmega.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libmega.a; path = "../../../bindings/ios/build/Debug-iphoneos/libmega.a"; sourceTree = ""; }; 41F175941A51E5E500570E30 /* MEGA-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "MEGA-Bridging-Header.h"; sourceTree = ""; }; 41F1759F1A51F17E00570E30 /* ImageIO.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = ImageIO.framework; path = System/Library/Frameworks/ImageIO.framework; sourceTree = SDKROOT; }; 41F175A11A51F18B00570E30 /* MobileCoreServices.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = MobileCoreServices.framework; path = System/Library/Frameworks/MobileCoreServices.framework; sourceTree = SDKROOT; }; - 41F175A31A51F19F00570E30 /* libresolv.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libresolv.dylib; path = usr/lib/libresolv.dylib; sourceTree = SDKROOT; }; - 41F175A51A51F1AF00570E30 /* libc++.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = "libc++.dylib"; path = "usr/lib/libc++.dylib"; sourceTree = SDKROOT; }; - 41F175A71A51F1B700570E30 /* libz.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libz.dylib; path = usr/lib/libz.dylib; sourceTree = SDKROOT; }; - 41F175A91A51F1C200570E30 /* libsqlite3.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libsqlite3.dylib; path = usr/lib/libsqlite3.dylib; sourceTree = SDKROOT; }; - A88EE2051F0A62AF00AECF76 /* libcares.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libcares.a; sourceTree = ""; }; - A88EE2061F0A62AF00AECF76 /* libcrypto.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libcrypto.a; sourceTree = ""; }; - A88EE2071F0A62AF00AECF76 /* libcryptopp.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libcryptopp.a; sourceTree = ""; }; - A88EE2081F0A62AF00AECF76 /* libcurl.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libcurl.a; sourceTree = ""; }; - A88EE2091F0A62AF00AECF76 /* libssl.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libssl.a; sourceTree = ""; }; - A88EE20A1F0A62AF00AECF76 /* libuv.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libuv.a; sourceTree = ""; }; - A88EE20B1F0A62AF00AECF76 /* libsodium.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libsodium.a; sourceTree = ""; }; - A88EE2261F0A648600AECF76 /* libcares.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libcares.a; path = ../../../bindings/ios/3rdparty/lib/libcares.a; sourceTree = ""; }; - A88EE2271F0A648600AECF76 /* libcrypto.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libcrypto.a; path = ../../../bindings/ios/3rdparty/lib/libcrypto.a; sourceTree = ""; }; - A88EE2281F0A648600AECF76 /* libcryptopp.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libcryptopp.a; path = ../../../bindings/ios/3rdparty/lib/libcryptopp.a; sourceTree = ""; }; - A88EE2291F0A648600AECF76 /* libcurl.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libcurl.a; path = ../../../bindings/ios/3rdparty/lib/libcurl.a; sourceTree = ""; }; - A88EE22A1F0A648600AECF76 /* libsodium.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libsodium.a; path = ../../../bindings/ios/3rdparty/lib/libsodium.a; sourceTree = ""; }; - A88EE22B1F0A648600AECF76 /* libssl.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libssl.a; path = ../../../bindings/ios/3rdparty/lib/libssl.a; sourceTree = ""; }; - A88EE22C1F0A648600AECF76 /* libuv.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libuv.a; path = ../../../bindings/ios/3rdparty/lib/libuv.a; sourceTree = ""; }; + A8BF108D21ED0BD7006B283A /* libsodium.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libsodium.a; path = ../../../bindings/ios/3rdparty/lib/libsodium.a; sourceTree = ""; }; + A8BF108E21ED0BD7006B283A /* libuv.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libuv.a; path = ../../../bindings/ios/3rdparty/lib/libuv.a; sourceTree = ""; }; + A8BF108F21ED0BD7006B283A /* libcrypto.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libcrypto.a; path = ../../../bindings/ios/3rdparty/lib/libcrypto.a; sourceTree = ""; }; + A8BF109021ED0BD7006B283A /* libcryptopp.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libcryptopp.a; path = ../../../bindings/ios/3rdparty/lib/libcryptopp.a; sourceTree = ""; }; + A8BF109121ED0BD8006B283A /* libcurl.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libcurl.a; path = ../../../bindings/ios/3rdparty/lib/libcurl.a; sourceTree = ""; }; + A8BF109221ED0BD8006B283A /* libssl.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libssl.a; path = ../../../bindings/ios/3rdparty/lib/libssl.a; sourceTree = ""; }; + A8BF109321ED0BD8006B283A /* libzen.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libzen.a; path = ../../../bindings/ios/3rdparty/lib/libzen.a; sourceTree = ""; }; + A8BF109421ED0BD8006B283A /* libmediainfo.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libmediainfo.a; path = ../../../bindings/ios/3rdparty/lib/libmediainfo.a; sourceTree = ""; }; + A8BF109521ED0BD8006B283A /* libcares.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libcares.a; path = ../../../bindings/ios/3rdparty/lib/libcares.a; sourceTree = ""; }; + A8BF109F21ED0BF7006B283A /* libMEGASDK.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; path = libMEGASDK.a; sourceTree = BUILT_PRODUCTS_DIR; }; + A8BF10A121ED0CF9006B283A /* libc++.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = "libc++.tbd"; path = "usr/lib/libc++.tbd"; sourceTree = SDKROOT; }; + A8BF10A321ED0D04006B283A /* libsqlite3.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libsqlite3.tbd; path = usr/lib/libsqlite3.tbd; sourceTree = SDKROOT; }; + A8BF10A521ED0D0D006B283A /* libz.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libz.tbd; path = usr/lib/libz.tbd; sourceTree = SDKROOT; }; + A8BF10A721ED0D15006B283A /* libresolv.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libresolv.tbd; path = usr/lib/libresolv.tbd; sourceTree = SDKROOT; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -115,27 +104,22 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - A88EE22D1F0A648600AECF76 /* libcares.a in Frameworks */, - A88EE22E1F0A648600AECF76 /* libcrypto.a in Frameworks */, - A88EE22F1F0A648600AECF76 /* libcryptopp.a in Frameworks */, - A88EE2301F0A648600AECF76 /* libcurl.a in Frameworks */, - A88EE2311F0A648600AECF76 /* libsodium.a in Frameworks */, - A88EE2321F0A648600AECF76 /* libssl.a in Frameworks */, - A88EE2331F0A648600AECF76 /* libuv.a in Frameworks */, + A8BF10A821ED0D15006B283A /* libresolv.tbd in Frameworks */, + A8BF10A621ED0D0D006B283A /* libz.tbd in Frameworks */, + A8BF10A421ED0D04006B283A /* libsqlite3.tbd in Frameworks */, + A8BF10A221ED0CF9006B283A /* libc++.tbd in Frameworks */, + A8BF10A021ED0BF7006B283A /* libMEGASDK.a in Frameworks */, + A8BF109621ED0BD8006B283A /* libsodium.a in Frameworks */, + A8BF109721ED0BD8006B283A /* libuv.a in Frameworks */, + A8BF109821ED0BD8006B283A /* libcrypto.a in Frameworks */, + A8BF109921ED0BD8006B283A /* libcryptopp.a in Frameworks */, + A8BF109A21ED0BD8006B283A /* libcurl.a in Frameworks */, + A8BF109B21ED0BD8006B283A /* libssl.a in Frameworks */, + A8BF109C21ED0BD8006B283A /* libzen.a in Frameworks */, + A8BF109D21ED0BD8006B283A /* libmediainfo.a in Frameworks */, + A8BF109E21ED0BD8006B283A /* libcares.a in Frameworks */, 41ABFDF11CBB942D00CC9D71 /* CoreMedia.framework in Frameworks */, 41ABFDEF1CBB93F700CC9D71 /* AVFoundation.framework in Frameworks */, - A88EE2121F0A62AF00AECF76 /* libsodium.a in Frameworks */, - A88EE2101F0A62AF00AECF76 /* libssl.a in Frameworks */, - A88EE2111F0A62AF00AECF76 /* libuv.a in Frameworks */, - 41C346BC1B4C47C9002091F8 /* libMEGASDK.a in Frameworks */, - 41F175AA1A51F1C200570E30 /* libsqlite3.dylib in Frameworks */, - A88EE20E1F0A62AF00AECF76 /* libcryptopp.a in Frameworks */, - 41F175A81A51F1B700570E30 /* libz.dylib in Frameworks */, - 41F175A61A51F1AF00570E30 /* libc++.dylib in Frameworks */, - A88EE20D1F0A62AF00AECF76 /* libcrypto.a in Frameworks */, - A88EE20C1F0A62AF00AECF76 /* libcares.a in Frameworks */, - A88EE20F1F0A62AF00AECF76 /* libcurl.a in Frameworks */, - 41F175A41A51F19F00570E30 /* libresolv.dylib in Frameworks */, 41F175A21A51F18B00570E30 /* MobileCoreServices.framework in Frameworks */, 41F175A01A51F17E00570E30 /* ImageIO.framework in Frameworks */, ); @@ -281,30 +265,24 @@ 41F175931A51E57C00570E30 /* Frameworks */ = { isa = PBXGroup; children = ( - A88EE2261F0A648600AECF76 /* libcares.a */, - A88EE2271F0A648600AECF76 /* libcrypto.a */, - A88EE2281F0A648600AECF76 /* libcryptopp.a */, - A88EE2291F0A648600AECF76 /* libcurl.a */, - A88EE22A1F0A648600AECF76 /* libsodium.a */, - A88EE22B1F0A648600AECF76 /* libssl.a */, - A88EE22C1F0A648600AECF76 /* libuv.a */, - A88EE2051F0A62AF00AECF76 /* libcares.a */, - A88EE2061F0A62AF00AECF76 /* libcrypto.a */, - A88EE2071F0A62AF00AECF76 /* libcryptopp.a */, - A88EE2081F0A62AF00AECF76 /* libcurl.a */, - A88EE2091F0A62AF00AECF76 /* libssl.a */, - A88EE20A1F0A62AF00AECF76 /* libuv.a */, - A88EE20B1F0A62AF00AECF76 /* libsodium.a */, + A8BF10A721ED0D15006B283A /* libresolv.tbd */, + A8BF10A521ED0D0D006B283A /* libz.tbd */, + A8BF10A321ED0D04006B283A /* libsqlite3.tbd */, + A8BF10A121ED0CF9006B283A /* libc++.tbd */, + A8BF109F21ED0BF7006B283A /* libMEGASDK.a */, + A8BF109521ED0BD8006B283A /* libcares.a */, + A8BF108F21ED0BD7006B283A /* libcrypto.a */, + A8BF109021ED0BD7006B283A /* libcryptopp.a */, + A8BF109121ED0BD8006B283A /* libcurl.a */, + A8BF109421ED0BD8006B283A /* libmediainfo.a */, + A8BF108D21ED0BD7006B283A /* libsodium.a */, + A8BF109221ED0BD8006B283A /* libssl.a */, + A8BF108E21ED0BD7006B283A /* libuv.a */, + A8BF109321ED0BD8006B283A /* libzen.a */, 41ABFDF01CBB942D00CC9D71 /* CoreMedia.framework */, 41ABFDEE1CBB93F700CC9D71 /* AVFoundation.framework */, - 41C346BB1B4C47C9002091F8 /* libMEGASDK.a */, - 41F175A91A51F1C200570E30 /* libsqlite3.dylib */, - 41F175A71A51F1B700570E30 /* libz.dylib */, - 41F175A51A51F1AF00570E30 /* libc++.dylib */, - 41F175A31A51F19F00570E30 /* libresolv.dylib */, 41F175A11A51F18B00570E30 /* MobileCoreServices.framework */, 41F1759F1A51F17E00570E30 /* ImageIO.framework */, - 41F175901A51E3A500570E30 /* libmega.a */, ); name = Frameworks; sourceTree = ""; @@ -344,7 +322,7 @@ 41F175681A51E22500570E30 = { CreatedOnToolsVersion = 6.1.1; DevelopmentTeam = T9RH74Y7L9; - LastSwiftMigration = 0830; + LastSwiftMigration = 1010; }; }; }; @@ -517,7 +495,8 @@ PRODUCT_BUNDLE_IDENTIFIER = "nz.mega.$(PRODUCT_NAME:rfc1034identifier)"; PRODUCT_NAME = "$(TARGET_NAME)"; SWIFT_OBJC_BRIDGING_HEADER = "$(SRCROOT)/MEGA/MEGA-Bridging-Header.h"; - SWIFT_VERSION = 3.0; + SWIFT_SWIFT3_OBJC_INFERENCE = Default; + SWIFT_VERSION = 4.2; USER_HEADER_SEARCH_PATHS = "../../../bindings/ios ../../../include"; }; name = Debug; @@ -537,7 +516,8 @@ PRODUCT_BUNDLE_IDENTIFIER = "nz.mega.$(PRODUCT_NAME:rfc1034identifier)"; PRODUCT_NAME = "$(TARGET_NAME)"; SWIFT_OBJC_BRIDGING_HEADER = "$(SRCROOT)/MEGA/MEGA-Bridging-Header.h"; - SWIFT_VERSION = 3.0; + SWIFT_SWIFT3_OBJC_INFERENCE = Default; + SWIFT_VERSION = 4.2; USER_HEADER_SEARCH_PATHS = "../../../bindings/ios ../../../include"; }; name = Release; diff --git a/examples/Swift/MEGA/MEGA/AppDelegate.swift b/examples/Swift/MEGA/MEGA/AppDelegate.swift index baa9c38f70..524a906657 100644 --- a/examples/Swift/MEGA/MEGA/AppDelegate.swift +++ b/examples/Swift/MEGA/MEGA/AppDelegate.swift @@ -27,7 +27,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate, MEGARequestDelegate { var window: UIWindow? let megaapi: MEGASdk = MEGASdk(appKey: "iOS Swift/1.0", userAgent: "hNF3ELhK", basePath: nil) - func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { MEGASdk.setLogLevel(MEGALogLevel.debug) @@ -71,7 +71,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate, MEGARequestDelegate { // MARK: - MEGA Request delegate func onRequestStart(_ api: MEGASdk!, request: MEGARequest!) { - if request.type == MEGARequestType.fetchNodes { + if request.type == MEGARequestType.MEGARequestTypeFetchNodes { SVProgressHUD.show(withStatus: "Updating nodes...") } } @@ -81,7 +81,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate, MEGARequestDelegate { return } - if request.type == MEGARequestType.login { + if request.type == MEGARequestType.MEGARequestTypeLogin { megaapi.fetchNodes(with: self) } } diff --git a/examples/Swift/MEGA/MEGA/CloudDrive/CloudDriveTableViewController.swift b/examples/Swift/MEGA/MEGA/CloudDrive/CloudDriveTableViewController.swift index 29a1667645..7e64a6887c 100644 --- a/examples/Swift/MEGA/MEGA/CloudDrive/CloudDriveTableViewController.swift +++ b/examples/Swift/MEGA/MEGA/CloudDrive/CloudDriveTableViewController.swift @@ -171,7 +171,7 @@ class CloudDriveTableViewController: UITableViewController, MEGADelegate, UIActi return 20.0 } - override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCell.EditingStyle, forRowAt indexPath: IndexPath) { if editingStyle == .delete { let node = nodes.node(at: indexPath.row) megaapi.remove(node) @@ -217,7 +217,7 @@ class CloudDriveTableViewController: UITableViewController, MEGADelegate, UIActi } else if buttonIndex == 2 { //Upload photo let imagePickerController = UIImagePickerController() imagePickerController.modalPresentationStyle = UIModalPresentationStyle.currentContext - imagePickerController.sourceType = UIImagePickerControllerSourceType.photoLibrary + imagePickerController.sourceType = UIImagePickerController.SourceType.photoLibrary imagePickerController.delegate = self self.tabBarController?.present(imagePickerController, animated: true, completion: nil) @@ -239,15 +239,18 @@ class CloudDriveTableViewController: UITableViewController, MEGADelegate, UIActi } // MARK: - UIImagePickerControllerDelegate - func imagePickerController(_ picker: UIImagePickerController, didFinishPickingMediaWithInfo info: [String : Any]) { - let assetURL = info[UIImagePickerControllerReferenceURL] as! URL + func imagePickerController(_ picker: UIImagePickerController, didFinishPickingMediaWithInfo info: [UIImagePickerController.InfoKey : Any]) { + // Local variable inserted by Swift 4.2 migrator. + let info = convertFromUIImagePickerControllerInfoKeyDictionary(info) + + let assetURL = info[convertFromUIImagePickerControllerInfoKey(UIImagePickerController.InfoKey.referenceURL)] as! URL let library = ALAssetsLibrary() library.asset(for: assetURL, resultBlock: { (asset: ALAsset!) in let name: String = asset.defaultRepresentation().filename() let modificationTime: Date = asset.value(forProperty: ALAssetPropertyDate) as! Date let imageView = UIImageView() - imageView.image = (info[UIImagePickerControllerOriginalImage] as! UIImage) - let webData: Data = UIImageJPEGRepresentation(imageView.image!, 0.9)! + imageView.image = (info[convertFromUIImagePickerControllerInfoKey(UIImagePickerController.InfoKey.originalImage)] as! UIImage) + let webData: Data = imageView.image!.jpegData(compressionQuality: 0.9)! let localFileURL = URL(fileURLWithPath:NSTemporaryDirectory()); let localFilePath = localFileURL.appendingPathComponent(name) @@ -279,10 +282,10 @@ class CloudDriveTableViewController: UITableViewController, MEGADelegate, UIActi } switch request.type { - case MEGARequestType.fetchNodes: + case MEGARequestType.MEGARequestTypeFetchNodes: SVProgressHUD.dismiss() - case MEGARequestType.getAttrFile: + case MEGARequestType.MEGARequestTypeGetAttrFile: for tableViewCell in tableView.visibleCells as! [NodeTableViewCell] { if request?.nodeHandle == tableViewCell.nodeHandle { let node = megaapi.node(forHandle: request.nodeHandle) @@ -307,3 +310,13 @@ class CloudDriveTableViewController: UITableViewController, MEGADelegate, UIActi } } + +// Helper function inserted by Swift 4.2 migrator. +fileprivate func convertFromUIImagePickerControllerInfoKeyDictionary(_ input: [UIImagePickerController.InfoKey: Any]) -> [String: Any] { + return Dictionary(uniqueKeysWithValues: input.map {key, value in (key.rawValue, value)}) +} + +// Helper function inserted by Swift 4.2 migrator. +fileprivate func convertFromUIImagePickerControllerInfoKey(_ input: UIImagePickerController.InfoKey) -> String { + return input.rawValue +} diff --git a/examples/Swift/MEGA/MEGA/CloudDrive/DetailsNodeInfoViewController.swift b/examples/Swift/MEGA/MEGA/CloudDrive/DetailsNodeInfoViewController.swift index 66793e2be7..060964bdc2 100644 --- a/examples/Swift/MEGA/MEGA/CloudDrive/DetailsNodeInfoViewController.swift +++ b/examples/Swift/MEGA/MEGA/CloudDrive/DetailsNodeInfoViewController.swift @@ -99,7 +99,7 @@ class DetailsNodeInfoViewController: UIViewController, MEGADelegate, UIAlertView downloadProgressView.isHidden = true cancelButton.isHidden = true saveLabel.isHidden = false - downloadButton.setImage(UIImage(named: "savedFile"), for: UIControlState()) + downloadButton.setImage(UIImage(named: "savedFile"), for: UIControl.State()) saveLabel.text = "Saved for offline" } else if megaapi.transfers.size.int32Value > 0 { downloadProgressView.isHidden = true @@ -193,7 +193,7 @@ class DetailsNodeInfoViewController: UIViewController, MEGADelegate, UIAlertView // MARK: - MEGA Request delegate func onRequestStart(_ api: MEGASdk!, request: MEGARequest!) { - if request.type == MEGARequestType.export { + if request.type == MEGARequestType.MEGARequestTypeExport { SVProgressHUD.show(withStatus: "Generate link...") } } @@ -204,7 +204,7 @@ class DetailsNodeInfoViewController: UIViewController, MEGADelegate, UIAlertView } switch request.type { - case MEGARequestType.getAttrFile: + case MEGARequestType.MEGARequestTypeGetAttrFile: if request.nodeHandle == node.handle { let node = megaapi.node(forHandle: request.nodeHandle) let thumbnailFilePath = Helper.pathForNode(node!, path: FileManager.SearchPathDirectory.cachesDirectory, directory: "thumbs") @@ -215,12 +215,12 @@ class DetailsNodeInfoViewController: UIViewController, MEGADelegate, UIAlertView } } - case MEGARequestType.export: + case MEGARequestType.MEGARequestTypeExport: SVProgressHUD.showSuccess(withStatus: "Link Generate") SVProgressHUD.dismiss() let items = [request.link] - let activity : UIActivityViewController = UIActivityViewController(activityItems: items, applicationActivities: nil) - activity.excludedActivityTypes = [UIActivityType.print, UIActivityType.copyToPasteboard, UIActivityType.assignToContact, UIActivityType.saveToCameraRoll] + let activity : UIActivityViewController = UIActivityViewController(activityItems: items as [Any], applicationActivities: nil) + activity.excludedActivityTypes = [UIActivity.ActivityType.print, UIActivity.ActivityType.copyToPasteboard, UIActivity.ActivityType.assignToContact, UIActivity.ActivityType.saveToCameraRoll] self.present(activity, animated: true, completion: nil) default: @@ -261,7 +261,7 @@ class DetailsNodeInfoViewController: UIViewController, MEGADelegate, UIAlertView } else { downloadProgressView.setProgress(1.0, animated: true) saveLabel.isHidden = false - downloadButton.setImage(UIImage(named: "savedFile"), for: UIControlState()) + downloadButton.setImage(UIImage(named: "savedFile"), for: UIControl.State()) saveLabel.text = "Saved for offline" } } diff --git a/examples/Swift/MEGA/MEGA/Contacts/ContactsTableViewController.swift b/examples/Swift/MEGA/MEGA/Contacts/ContactsTableViewController.swift index 5c6ed92db2..5a2f9fec91 100644 --- a/examples/Swift/MEGA/MEGA/Contacts/ContactsTableViewController.swift +++ b/examples/Swift/MEGA/MEGA/Contacts/ContactsTableViewController.swift @@ -96,7 +96,7 @@ class ContactsTableViewController: UITableViewController, MEGARequestDelegate { } switch request.type { - case MEGARequestType.getAttrUser: + case MEGARequestType.MEGARequestTypeGetAttrUser: for tableViewCell in tableView.visibleCells as! [ContactTableViewCell] { if request?.email == tableViewCell.nameLabel.text { let filename = request.email diff --git a/examples/Swift/MEGA/MEGA/Images.xcassets/AppIcon.appiconset/Contents.json b/examples/Swift/MEGA/MEGA/Images.xcassets/AppIcon.appiconset/Contents.json index 609c7491f4..d2fcbbd1a5 100644 --- a/examples/Swift/MEGA/MEGA/Images.xcassets/AppIcon.appiconset/Contents.json +++ b/examples/Swift/MEGA/MEGA/Images.xcassets/AppIcon.appiconset/Contents.json @@ -1,5 +1,15 @@ { "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, { "idiom" : "iphone", "size" : "29x29", @@ -48,6 +58,16 @@ "filename" : "icon-60@3x.png", "scale" : "3x" }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, { "idiom" : "ipad", "size" : "29x29", @@ -108,8 +128,8 @@ "scale" : "2x" }, { - "idiom" : "car", - "size" : "120x120", + "idiom" : "ios-marketing", + "size" : "1024x1024", "scale" : "1x" } ], diff --git a/examples/Swift/MEGA/MEGA/Login/LoginViewController.swift b/examples/Swift/MEGA/MEGA/Login/LoginViewController.swift index 6f7b8c030d..cea4408a6c 100644 --- a/examples/Swift/MEGA/MEGA/Login/LoginViewController.swift +++ b/examples/Swift/MEGA/MEGA/Login/LoginViewController.swift @@ -55,16 +55,16 @@ class LoginViewController: UIViewController, MEGARequestDelegate { func validateForm() -> Bool { if !validateEmail(emailTextField.text!) { - let alertController = UIAlertController(title: "Invalid email", message: "Enter a valid email", preferredStyle: UIAlertControllerStyle.alert) - alertController.addAction(UIAlertAction(title: "Dismiss", style: UIAlertActionStyle.default,handler: nil)) + let alertController = UIAlertController(title: "Invalid email", message: "Enter a valid email", preferredStyle: UIAlertController.Style.alert) + alertController.addAction(UIAlertAction(title: "Dismiss", style: UIAlertAction.Style.default,handler: nil)) self.present(alertController, animated: true, completion: nil) emailTextField.becomeFirstResponder() return false } else if !validatePassword(passwordTextField.text!) { - let alertController = UIAlertController(title: "Invalid password", message: "Enter a valid password", preferredStyle: UIAlertControllerStyle.alert) - alertController.addAction(UIAlertAction(title: "Dismiss", style: UIAlertActionStyle.default,handler: nil)) + let alertController = UIAlertController(title: "Invalid password", message: "Enter a valid password", preferredStyle: UIAlertController.Style.alert) + alertController.addAction(UIAlertAction(title: "Dismiss", style: UIAlertAction.Style.default,handler: nil)) self.present(alertController, animated: true, completion: nil) passwordTextField.becomeFirstResponder() @@ -89,7 +89,7 @@ class LoginViewController: UIViewController, MEGARequestDelegate { // MARK: - MEGA Request delegate func onRequestStart(_ api: MEGASdk!, request: MEGARequest!) { - if request.type == MEGARequestType.login { + if request.type == MEGARequestType.MEGARequestTypeLogin { loginButton.isEnabled = false loginProgressView.isHidden = false } @@ -104,13 +104,13 @@ class LoginViewController: UIViewController, MEGARequestDelegate { switch error.type { case MEGAErrorType.apiEArgs: - let alertController = UIAlertController(title: "Error", message: "Email or password invalid", preferredStyle: UIAlertControllerStyle.alert) - alertController.addAction(UIAlertAction(title: "Dismiss", style: UIAlertActionStyle.default,handler: nil)) + let alertController = UIAlertController(title: "Error", message: "Email or password invalid", preferredStyle: UIAlertController.Style.alert) + alertController.addAction(UIAlertAction(title: "Dismiss", style: UIAlertAction.Style.default,handler: nil)) self.present(alertController, animated: true, completion: nil) case MEGAErrorType.apiENoent: - let alertController = UIAlertController(title: "Error", message: "User does not exist", preferredStyle: UIAlertControllerStyle.alert) - alertController.addAction(UIAlertAction(title: "Dismiss", style: UIAlertActionStyle.default,handler: nil)) + let alertController = UIAlertController(title: "Error", message: "User does not exist", preferredStyle: UIAlertController.Style.alert) + alertController.addAction(UIAlertAction(title: "Dismiss", style: UIAlertAction.Style.default,handler: nil)) self.present(alertController, animated: true, completion: nil) default: @@ -121,12 +121,12 @@ class LoginViewController: UIViewController, MEGARequestDelegate { } switch request.type { - case MEGARequestType.login: + case MEGARequestType.MEGARequestTypeLogin: let session = megaapi.dumpSession() SSKeychain.setPassword(session, forService: "MEGA", account: "session") api.fetchNodes(with: self) - case MEGARequestType.fetchNodes: + case MEGARequestType.MEGARequestTypeFetchNodes: self.performSegue(withIdentifier: "showCloudDrive", sender: self) default: @@ -135,7 +135,7 @@ class LoginViewController: UIViewController, MEGARequestDelegate { } func onRequestUpdate(_ api: MEGASdk!, request: MEGARequest!) { - if request.type == MEGARequestType.fetchNodes { + if request.type == MEGARequestType.MEGARequestTypeFetchNodes { let progress = request.transferredBytes.floatValue / request.totalBytes.floatValue if progress > 0 && progress < 0.99 { informationLabel.text = "Fectching nodes" diff --git a/examples/Swift/MEGA/MEGA/Settings/SettingsViewController.swift b/examples/Swift/MEGA/MEGA/Settings/SettingsViewController.swift index ac5c877480..9922ed5000 100644 --- a/examples/Swift/MEGA/MEGA/Settings/SettingsViewController.swift +++ b/examples/Swift/MEGA/MEGA/Settings/SettingsViewController.swift @@ -67,7 +67,7 @@ class SettingsViewController: UIViewController, MEGARequestDelegate { // MARK: - MEGA Request delegate func onRequestStart(_ api: MEGASdk!, request: MEGARequest!) { - if request.type == MEGARequestType.logout { + if request.type == MEGARequestType.MEGARequestTypeLogout { SVProgressHUD.show(withStatus: "Logout") } } @@ -78,7 +78,7 @@ class SettingsViewController: UIViewController, MEGARequestDelegate { } switch request.type { - case MEGARequestType.logout: + case MEGARequestType.MEGARequestTypeLogout: SSKeychain.deletePassword(forService: "MEGA", account: "session") let thumbsURL = FileManager.default.urls(for: .cachesDirectory, in: .userDomainMask)[0] @@ -94,7 +94,7 @@ class SettingsViewController: UIViewController, MEGARequestDelegate { success = false } if (!success || error != nil) { - print("(Cache) Remove file error: \(error)") + print("(Cache) Remove file error: \(error!)") } let documentDirectory : String = NSSearchPathForDirectoriesInDomains(FileManager.SearchPathDirectory.documentDirectory, FileManager.SearchPathDomainMask.userDomainMask, true)[0] @@ -106,7 +106,7 @@ class SettingsViewController: UIViewController, MEGARequestDelegate { success = false } if (!success || error != nil) { - print("(Document) Remove file error: \(error)") + print("(Document) Remove file error: \(error!)") } SVProgressHUD.dismiss() @@ -114,10 +114,10 @@ class SettingsViewController: UIViewController, MEGARequestDelegate { let lvc = storyboard.instantiateViewController(withIdentifier: "LoginViewControllerID") as! LoginViewController present(lvc, animated: true, completion: nil) - case MEGARequestType.getAttrUser: + case MEGARequestType.MEGARequestTypeGetAttrUser: setUserAvatar() - case MEGARequestType.accountDetails: + case MEGARequestType.MEGARequestTypeAccountDetails: spaceUsedLabel.text = "\(ByteCountFormatter.string(fromByteCount: request.megaAccountDetails.storageUsed.int64Value, countStyle: ByteCountFormatter.CountStyle.memory)) of \(ByteCountFormatter.string(fromByteCount: request.megaAccountDetails.storageMax.int64Value, countStyle: ByteCountFormatter.CountStyle.memory))" let progress = request.megaAccountDetails.storageUsed.floatValue / request.megaAccountDetails.storageMax.floatValue spaceUsedProgressView.setProgress(progress, animated: true) diff --git a/examples/Swift/MEGA/MEGA/Utils/Helper.swift b/examples/Swift/MEGA/MEGA/Utils/Helper.swift index e2ea56a36e..983a5917f2 100644 --- a/examples/Swift/MEGA/MEGA/Utils/Helper.swift +++ b/examples/Swift/MEGA/MEGA/Utils/Helper.swift @@ -197,13 +197,10 @@ class Helper { } - class func imageForNode(_ node : MEGANode) -> UIImage { - - let megaapi : MEGASdk! = (UIApplication.shared.delegate as! AppDelegate).megaapi - + class func imageForNode(_ node : MEGANode) -> UIImage { switch node.type { case MEGANodeType.folder: - if megaapi.isSharedNode(node) { + if node.isInShare() { return UIImage(named: "folder_shared")! } else { return UIImage(named: "folder")! diff --git a/examples/Swift/README.md b/examples/Swift/README.md index 17a9a4850c..40ac44d5aa 100644 --- a/examples/Swift/README.md +++ b/examples/Swift/README.md @@ -27,7 +27,7 @@ To build and run the project, follow theses steps: 1. Download or clone the whole SDK -2. Download the prebuilt third party dependencies from this link: https://mega.nz/#!YIdnRKSR!UIOuMq_h8A5CHwt7OX_THnyZ_OR1eS_cPmiwm8yxsb0 +2. Download the prebuilt third party dependencies from this link: https://mega.nz/#!gN9w0I7Q!-OPUWBoEnvXeZWkkC5oUho2MFm_49nwBwN6q07sxKII 3. Uncompress the content and move `include`and `lib`to the directory `sdk/bindings/ios/3rdparty` diff --git a/examples/android/ExampleApp/.idea/compiler.xml b/examples/android/ExampleApp/.idea/compiler.xml deleted file mode 100644 index 96cc43efa6..0000000000 --- a/examples/android/ExampleApp/.idea/compiler.xml +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/examples/android/ExampleApp/.idea/copyright/profiles_settings.xml b/examples/android/ExampleApp/.idea/copyright/profiles_settings.xml deleted file mode 100644 index e7bedf3377..0000000000 --- a/examples/android/ExampleApp/.idea/copyright/profiles_settings.xml +++ /dev/null @@ -1,3 +0,0 @@ - - - \ No newline at end of file diff --git a/examples/android/ExampleApp/.idea/misc.xml b/examples/android/ExampleApp/.idea/misc.xml index c64217c111..39c65f6495 100644 --- a/examples/android/ExampleApp/.idea/misc.xml +++ b/examples/android/ExampleApp/.idea/misc.xml @@ -1,69 +1,9 @@ - - - - - - - - - - - - - - - - - - - - - + - - - - - 1.7 - - - - - - - \ No newline at end of file diff --git a/examples/android/ExampleApp/.idea/vcs.xml b/examples/android/ExampleApp/.idea/vcs.xml deleted file mode 100644 index 6564d52db2..0000000000 --- a/examples/android/ExampleApp/.idea/vcs.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/examples/android/ExampleApp/README.md b/examples/android/ExampleApp/README.md index 5353054207..c24bc6a905 100644 --- a/examples/android/ExampleApp/README.md +++ b/examples/android/ExampleApp/README.md @@ -20,7 +20,7 @@ You have two options, using a prebuilt native library or building it by yourself ``` git clone --recursive https://github.com/meganz/sdk.git ``` -* Download the prebuilt libraries (`libmega.so`) along with its corresponding Java classes from [here](https://mega.nz/#!F9MDiIYR!Udguz_byyIttpjaa2twcWZGqcqWCfalhGO-_jg7kNCo). Generated with commit: 08adf46ca80dd8aa9f54916b998c2efe1f7a444d +* Download the prebuilt libraries (`libmega.so`) along with its corresponding Java classes from [here](https://mega.nz/#!UdJwVKJL!_0XsoFtnuVzzuQTb8Qiiwd5wpAk_SnXKJywhTiLhvdY). Generated with commit: 73f8a3ed6c7c9f49e3233fc90996735de233092e * Extract the content into `app/src/main`, keeping the folder structure. * Open the project with Android Studio, let it build the project and hit _*Run*_ diff --git a/examples/android/ExampleApp/app/build.gradle b/examples/android/ExampleApp/app/build.gradle index b2ea7bf371..59fa3ce6d8 100644 --- a/examples/android/ExampleApp/app/build.gradle +++ b/examples/android/ExampleApp/app/build.gradle @@ -1,13 +1,13 @@ apply plugin: 'com.android.application' android { - compileSdkVersion 23 - buildToolsVersion "23.0.3" - + compileSdkVersion 27 + buildToolsVersion '28.0.3' + defaultConfig { applicationId "nz.mega.android.bindingsample" - minSdkVersion 9 - targetSdkVersion 23 + minSdkVersion 14 + targetSdkVersion 27 versionCode 1 versionName "1.0" } @@ -30,6 +30,6 @@ android { } dependencies { - compile fileTree(dir: 'libs', include: ['*.jar']) - compile 'com.android.support:appcompat-v7:23.2.1' + implementation fileTree(dir: 'libs', include: ['*.jar']) + implementation 'com.android.support:appcompat-v7:27.1.1' } diff --git a/examples/android/ExampleApp/app/src/main/AndroidManifest.xml b/examples/android/ExampleApp/app/src/main/AndroidManifest.xml index 6cccbb4a27..6af9201083 100644 --- a/examples/android/ExampleApp/app/src/main/AndroidManifest.xml +++ b/examples/android/ExampleApp/app/src/main/AndroidManifest.xml @@ -4,11 +4,8 @@ android:versionCode="1" android:versionName="1.0" > - - + { - - @Override - protected String[] doInBackground(String... args) { - String privateKey = megaApi.getBase64PwKey(args[1]); - String publicKey = megaApi.getStringHash(privateKey, args[0]); - return new String[]{new String(privateKey), new String(publicKey)}; - } - - - @Override - protected void onPostExecute(String[] key) { - onKeysGenerated(key[0], key[1]); - } - - } - @Override protected void onCreate(Bundle savedInstanceState) { @@ -128,9 +108,9 @@ private void initLogin(){ passwordText.setVisibility(View.GONE); loginButton.setVisibility(View.GONE); - title.setText(getResources().getString(R.string.generating_hash)); - - new HashTask().execute(email, password); + title.setText(getResources().getString(R.string.logging_in)); + + megaApi.login(email, password, this); } /* @@ -177,13 +157,6 @@ private String getPasswordError() { } return null; } - - private void onKeysGenerated(String privateKey, String publicKey) { - this.gPrivateKey = privateKey; - this.gPublicKey = publicKey; - - megaApi.fastLogin(email, publicKey, privateKey, this); - } @Override public void onRequestStart(MegaApiJava api, MegaRequest request) { diff --git a/examples/android/ExampleApp/app/src/main/jni/Application.mk b/examples/android/ExampleApp/app/src/main/jni/Application.mk index 7e37bfd2f2..14690fecef 100644 --- a/examples/android/ExampleApp/app/src/main/jni/Application.mk +++ b/examples/android/ExampleApp/app/src/main/jni/Application.mk @@ -6,8 +6,8 @@ APP_OPTIM := release APP_PIE := false # then enable c++11 extentions in source code -APP_CPPFLAGS += -std=c++11 -Wno-extern-c-compat -mno-unaligned-access -# or use APP_CPPFLAGS := -std=gnu++11 +APP_CPPFLAGS += -std=c++11 -Wno-extern-c-compat -mno-unaligned-access -fexceptions -frtti DISABLE_WEBRTC = true +USE_LIBWEBSOCKETS = false diff --git a/examples/android/ExampleApp/app/src/main/jni/bindings/Android.mk b/examples/android/ExampleApp/app/src/main/jni/bindings/Android.mk index d36932e53d..c44e7e02ec 100644 --- a/examples/android/ExampleApp/app/src/main/jni/bindings/Android.mk +++ b/examples/android/ExampleApp/app/src/main/jni/bindings/Android.mk @@ -5,7 +5,7 @@ LOCAL_PATH := $(call my-dir) # The link step uses -Wl,-dead_strip,-gc-sections to strip all unused code include $(CLEAR_VARS) LOCAL_MODULE := mega -LOCAL_CFLAGS := -fexceptions -frtti -fdata-sections -ffunction-sections -DDEBUG +LOCAL_CFLAGS := -fdata-sections -ffunction-sections -DDEBUG LOCAL_SRC_FILES := $(LOCAL_PATH)/megasdk.cpp LOCAL_LDLIBS := -lm -lz -llog -lGLESv2 -lOpenSLES -latomic LOCAL_LDFLAGS := -Wl,-gc-sections diff --git a/examples/android/ExampleApp/app/src/main/jni/build.sh b/examples/android/ExampleApp/app/src/main/jni/build.sh index b6915a8a51..e2271384a9 100755 --- a/examples/android/ExampleApp/app/src/main/jni/build.sh +++ b/examples/android/ExampleApp/app/src/main/jni/build.sh @@ -19,11 +19,11 @@ APP_PLATFORM=`grep APP_PLATFORM Application.mk | cut -d '=' -f 2` LOG_FILE=/dev/null CRYPTOPP=cryptopp -CRYPTOPP_VERSION=563 +CRYPTOPP_VERSION=800 CRYPTOPP_SOURCE_FILE=cryptopp${CRYPTOPP_VERSION}.zip CRYPTOPP_SOURCE_FOLDER=${CRYPTOPP}/${CRYPTOPP} CRYPTOPP_DOWNLOAD_URL=http://www.cryptopp.com/${CRYPTOPP_SOURCE_FILE} -CRYPTOPP_SHA1="f2fcd1fbf884bed70a69b565970ecd8b33a68cc4" +CRYPTOPP_SHA1="dd0dc0586c0a3e0696cd323efc6fa2e2945ad920" SQLITE=sqlite SQLITE_VERSION=3120200 @@ -36,7 +36,7 @@ SQLITE_SHA1="22632bf0cfacedbeddde9f92695f71cab8d8c0a5" CURL=curl CURL_VERSION=7.48.0 -C_ARES_VERSION=1.11.0 +C_ARES_VERSION=1.15.0 CURL_EXTRA="--disable-smb --disable-ftp --disable-file --disable-ldap --disable-ldaps --disable-rtsp --disable-proxy --disable-dict --disable-telnet --disable-tftp --disable-pop3 --disable-imap --disable-smtp --disable-gopher --disable-sspi" CURL_SOURCE_FILE=curl-${CURL_VERSION}.tar.gz CURL_SOURCE_FOLDER=curl-${CURL_VERSION} @@ -47,7 +47,7 @@ ARES_SOURCE_FILE=c-ares-${C_ARES_VERSION}.tar.gz ARES_SOURCE_FOLDER=c-ares-${C_ARES_VERSION} ARES_CONFIGURED=${CURL}/${ARES_SOURCE_FOLDER}/Makefile.inc ARES_DOWNLOAD_URL=http://c-ares.haxx.se/download/${ARES_SOURCE_FILE} -ARES_SHA1="8c20b2680099ac73861a780c731edd59e010383a" +ARES_SHA1="74a50c02b7f051c4fb66c0f60f187350f196d908" OPENSSL=openssl OPENSSL_VERSION=1.0.2h @@ -271,6 +271,7 @@ echo "* Setting up Crypto++" if [ ! -f ${CRYPTOPP}/${CRYPTOPP_SOURCE_FILE}.ready ]; then mkdir -p ${CRYPTOPP}/${CRYPTOPP} downloadCheckAndUnpack ${CRYPTOPP_DOWNLOAD_URL} ${CRYPTOPP}/${CRYPTOPP_SOURCE_FILE} ${CRYPTOPP_SHA1} ${CRYPTOPP}/${CRYPTOPP} + cp ${NDK_ROOT}/sources/android/cpufeatures/cpu-features.h ${CRYPTOPP}/${CRYPTOPP}/ touch ${CRYPTOPP}/${CRYPTOPP_SOURCE_FILE}.ready fi echo "* Crypto++ is ready" diff --git a/examples/android/ExampleApp/app/src/main/jni/cryptopp/Android.mk b/examples/android/ExampleApp/app/src/main/jni/cryptopp/Android.mk index 3a607582e0..1157124c54 100644 --- a/examples/android/ExampleApp/app/src/main/jni/cryptopp/Android.mk +++ b/examples/android/ExampleApp/app/src/main/jni/cryptopp/Android.mk @@ -3,9 +3,10 @@ LOCAL_PATH := $(call my-dir) include $(CLEAR_VARS) LOCAL_MODULE := cryptopp -LOCAL_CFLAGS := -DCRYPTOPP_DISABLE_X86ASM -DCRYPTOPP_DISABLE_SSSE3 -DCRYPTOPP_DISABLE_AESNI -D__ILP32__=0 -D_ILP32=0 -Wno-macro-redefined -fexceptions -frtti -fvisibility=hidden -fvisibility-inlines-hidden -fdata-sections -ffunction-sections -LOCAL_SRC_FILES := $(addprefix cryptopp/, 3way.cpp crc.cpp eax.cpp idea.cpp mqv.cpp rabin.cpp safer.cpp socketft.cpp twofish.cpp zinflate.cpp bfinit.cpp cryptlib_bds.cpp ec2n.cpp gcm.cpp integer.cpp nbtheory.cpp randpool.cpp salsa.cpp sosemanuk.cpp zlib.cpp adler32.cpp blowfish.cpp cryptlib.cpp eccrypto.cpp gf2_32.cpp iterhash.cpp network.cpp rc2.cpp seal.cpp square.cpp algebra.cpp blumshub.cpp ecp.cpp gf256.cpp luc.cpp oaep.cpp rc5.cpp seed.cpp squaretb.cpp algparam.cpp camellia.cpp default.cpp elgamal.cpp gf2n.cpp mars.cpp osrng.cpp rc6.cpp serpent.cpp strciphr.cpp vmac.cpp arc4.cpp cast.cpp des.cpp emsa2.cpp gfpcrypt.cpp marss.cpp panama.cpp rdtables.cpp sha3.cpp tea.cpp wait.cpp asn.cpp casts.cpp dessp.cpp eprecomp.cpp gost.cpp md2.cpp pch.cpp shacal2.cpp wake.cpp authenc.cpp cbcmac.cpp dh2.cpp esign.cpp gzip.cpp md4.cpp pkcspad.cpp rijndael.cpp sha.cpp tftables.cpp whrlpool.cpp base32.cpp ccm.cpp dh.cpp files.cpp hex.cpp md5.cpp polynomi.cpp ripemd.cpp sharkbox.cpp tiger.cpp winpipes.cpp base64.cpp channels.cpp dll.cpp filters.cpp hmac.cpp misc.cpp pssr.cpp rng.cpp shark.cpp tigertab.cpp xtr.cpp basecode.cpp cmac.cpp fips140.cpp hrtimer.cpp modes.cpp pubkey.cpp rsa.cpp simple.cpp trdlocal.cpp xtrcrypt.cpp cpu.cpp dsa.cpp fipsalgt.cpp ida.cpp mqueue.cpp queue.cpp rw.cpp skipjack.cpp ttmac.cpp zdeflate.cpp) +LOCAL_CFLAGS := -DCRYPTOPP_DISABLE_ASM -fvisibility=hidden -fvisibility-inlines-hidden -fdata-sections -ffunction-sections +LOCAL_SRC_FILES := $(addprefix cryptopp/, cryptlib.cpp cpu.cpp integer.cpp 3way.cpp adler32.cpp algebra.cpp algparam.cpp arc4.cpp aria.cpp aria_simd.cpp ariatab.cpp asn.cpp authenc.cpp base32.cpp base64.cpp basecode.cpp bfinit.cpp blake2.cpp blake2b_simd.cpp blake2s_simd.cpp blowfish.cpp blumshub.cpp camellia.cpp cast.cpp casts.cpp cbcmac.cpp ccm.cpp chacha.cpp chacha_avx.cpp chacha_simd.cpp cham.cpp cham_simd.cpp channels.cpp cmac.cpp crc.cpp crc_simd.cpp darn.cpp default.cpp des.cpp dessp.cpp dh.cpp dh2.cpp dll.cpp donna_32.cpp donna_64.cpp donna_sse.cpp dsa.cpp eax.cpp ec2n.cpp eccrypto.cpp ecp.cpp elgamal.cpp emsa2.cpp eprecomp.cpp esign.cpp files.cpp filters.cpp fips140.cpp fipstest.cpp gcm.cpp gcm_simd.cpp gf256.cpp gf2_32.cpp gf2n.cpp gfpcrypt.cpp gost.cpp gzip.cpp hc128.cpp hc256.cpp hex.cpp hight.cpp hmac.cpp hrtimer.cpp ida.cpp idea.cpp iterhash.cpp kalyna.cpp kalynatab.cpp keccak.cpp keccakc.cpp lea.cpp lea_simd.cpp luc.cpp mars.cpp marss.cpp md2.cpp md4.cpp md5.cpp misc.cpp modes.cpp mqueue.cpp mqv.cpp nbtheory.cpp neon_simd.cpp oaep.cpp osrng.cpp padlkrng.cpp panama.cpp pkcspad.cpp poly1305.cpp polynomi.cpp ppc_power7.cpp ppc_power8.cpp ppc_power9.cpp ppc_simd.cpp pssr.cpp pubkey.cpp queue.cpp rabbit.cpp rabin.cpp randpool.cpp rc2.cpp rc5.cpp rc6.cpp rdrand.cpp rdtables.cpp rijndael.cpp rijndael_simd.cpp ripemd.cpp rng.cpp rsa.cpp rw.cpp safer.cpp salsa.cpp scrypt.cpp seal.cpp seed.cpp serpent.cpp sha.cpp sha3.cpp sha_simd.cpp shacal2.cpp shacal2_simd.cpp shark.cpp sharkbox.cpp simeck.cpp simeck_simd.cpp simon.cpp simon128_simd.cpp simon64_simd.cpp skipjack.cpp sm3.cpp sm4.cpp sm4_simd.cpp sosemanuk.cpp speck.cpp speck128_simd.cpp speck64_simd.cpp square.cpp squaretb.cpp sse_simd.cpp strciphr.cpp tea.cpp tftables.cpp threefish.cpp tiger.cpp tigertab.cpp ttmac.cpp tweetnacl.cpp twofish.cpp vmac.cpp wake.cpp whrlpool.cpp xed25519.cpp xtr.cpp xtrcrypt.cpp zdeflate.cpp zinflate.cpp zlib.cpp) LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH) -LOCAL_EXPORT_CFLAGS := -DCRYPTOPP_DISABLE_X86ASM -DCRYPTOPP_DISABLE_SSSE3 -DCRYPTOPP_DISABLE_AESNI -D__ILP32__=0 -D_ILP32=0 -Wno-macro-redefined +LOCAL_EXPORT_CFLAGS := -DCRYPTOPP_DISABLE_ASM include $(BUILD_STATIC_LIBRARY) + diff --git a/examples/android/ExampleApp/app/src/main/jni/curl/Android.mk b/examples/android/ExampleApp/app/src/main/jni/curl/Android.mk index 64ef046027..de388cf8bc 100644 --- a/examples/android/ExampleApp/app/src/main/jni/curl/Android.mk +++ b/examples/android/ExampleApp/app/src/main/jni/curl/Android.mk @@ -8,7 +8,7 @@ LOCAL_MODULE := curl LOCAL_SRC_FILES := $(addprefix curl/lib/,$(CSOURCES)) LOCAL_C_INCLUDES += $(LOCAL_PATH)/curl/include $(LOCAL_PATH)/curl/lib $(LOCAL_PATH)/include LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/curl/include $(LOCAL_PATH)/include -LOCAL_CFLAGS += $(CFLAGS) -DHAVE_CONFIG_H -fexceptions -frtti -fvisibility=hidden -fdata-sections -ffunction-sections +LOCAL_CFLAGS += $(CFLAGS) -DHAVE_CONFIG_H -fvisibility=hidden -fdata-sections -ffunction-sections LOCAL_STATIC_LIBRARIES := ares ssl crypto include $(BUILD_STATIC_LIBRARY) @@ -18,7 +18,7 @@ LOCAL_MODULE := ares LOCAL_SRC_FILES := $(addprefix ares/,$(CSOURCES)) LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/ares $(LOCAL_PATH)/include LOCAL_C_INCLUDES += $(LOCAL_PATH)/ares $(LOCAL_PATH)/include -LOCAL_CFLAGS += $(CFLAGS) -DHAVE_CONFIG_H -fexceptions -frtti -fvisibility=hidden -fdata-sections -ffunction-sections +LOCAL_CFLAGS += $(CFLAGS) -DHAVE_CONFIG_H -fvisibility=hidden -fdata-sections -ffunction-sections LOCAL_STATIC_LIBRARIES := crypto ssl include $(BUILD_STATIC_LIBRARY) diff --git a/examples/android/ExampleApp/app/src/main/jni/libuv/Android.mk b/examples/android/ExampleApp/app/src/main/jni/libuv/Android.mk index af848e9311..5421494141 100644 --- a/examples/android/ExampleApp/app/src/main/jni/libuv/Android.mk +++ b/examples/android/ExampleApp/app/src/main/jni/libuv/Android.mk @@ -2,7 +2,7 @@ LOCAL_PATH := $(call my-dir) include $(CLEAR_VARS) LOCAL_MODULE := libuv -LOCAL_CFLAGS := -fexceptions -frtti -fvisibility=hidden -fdata-sections -ffunction-sections +LOCAL_CFLAGS := -fvisibility=hidden -fdata-sections -ffunction-sections ifneq ($(TARGET_ARCH_ABI),arm64-v8a) LOCAL_CFLAGS += -DHAVE_PTHREAD_COND_TIMEDWAIT_MONOTONIC diff --git a/examples/android/ExampleApp/app/src/main/jni/mediainfo/Android.mk b/examples/android/ExampleApp/app/src/main/jni/mediainfo/Android.mk index 6de2bf5ac0..0d4ca7b5d2 100644 --- a/examples/android/ExampleApp/app/src/main/jni/mediainfo/Android.mk +++ b/examples/android/ExampleApp/app/src/main/jni/mediainfo/Android.mk @@ -4,7 +4,7 @@ include $(CLEAR_VARS) LOCAL_MODULE := zenlib LOCAL_C_INCLUDES := $(LOCAL_PATH)/ZenLib/Source $(LOCAL_PATH)/ZenLib/Source/ZenLib LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/ZenLib/Source -LOCAL_CFLAGS := -fexceptions -frtti -fvisibility=hidden -fvisibility-inlines-hidden -fdata-sections -ffunction-sections -DUNICODE -D_LARGE_FILES -D_FILE_OFFSET_BITS=64 +LOCAL_CFLAGS := -fvisibility=hidden -fvisibility-inlines-hidden -fdata-sections -ffunction-sections -DUNICODE -D_LARGE_FILES -D_FILE_OFFSET_BITS=64 LOCAL_SRC_FILES := $(addprefix ZenLib/Source/ZenLib/, \ Conf.cpp \ CriticalSection.cpp \ @@ -40,7 +40,7 @@ LOCAL_C_INCLUDES := $(LOCAL_PATH)/mediainfo/Source $(LOCAL_PATH)/mediainfo/Sourc $(LOCAL_PATH)/mediainfo/Source/ThirdParty/sha1-gladman $(LOCAL_PATH)/mediainfo/Source/ThirdParty/sha2-gladman LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/mediainfo/Source -LOCAL_CFLAGS := -fexceptions -frtti -fvisibility=hidden -fvisibility-inlines-hidden -fdata-sections -ffunction-sections -DMEDIAINFO_MINIMIZESIZE -DMEDIAINFO_MINIMAL_YES -DMEDIAINFO_ARCHIVE_NO -DMEDIAINFO_IMAGE_NO \ +LOCAL_CFLAGS := -fvisibility=hidden -fvisibility-inlines-hidden -fdata-sections -ffunction-sections -DMEDIAINFO_MINIMIZESIZE -DMEDIAINFO_MINIMAL_YES -DMEDIAINFO_ARCHIVE_NO -DMEDIAINFO_IMAGE_NO \ -DMEDIAINFO_TAG_NO -DMEDIAINFO_TEXT_NO -DMEDIAINFO_SWF_NO -DMEDIAINFO_FLV_NO -DMEDIAINFO_HDSF4M_NO -DMEDIAINFO_CDXA_NO -DMEDIAINFO_DPG_NO -DMEDIAINFO_PMP_NO -DMEDIAINFO_RM_NO -DMEDIAINFO_WTV_NO -DMEDIAINFO_MXF_NO \ -DMEDIAINFO_DCP_NO -DMEDIAINFO_AAF_NO -DMEDIAINFO_BDAV_NO -DMEDIAINFO_BDMV_NO -DMEDIAINFO_DVDV_NO -DMEDIAINFO_GXF_NO -DMEDIAINFO_MIXML_NO -DMEDIAINFO_SKM_NO -DMEDIAINFO_NUT_NO -DMEDIAINFO_TSP_NO -DMEDIAINFO_HLS_NO \ -DMEDIAINFO_DXW_NO -DMEDIAINFO_DVDIF_NO -DMEDIAINFO_DASHMPD_NO -DMEDIAINFO_AIC_NO -DMEDIAINFO_AVSV_NO -DMEDIAINFO_CANOPUS_NO -DMEDIAINFO_FFV1_NO -DMEDIAINFO_FLIC_NO -DMEDIAINFO_HUFFYUV_NO -DMEDIAINFO_PRORES_NO -DMEDIAINFO_Y4M_NO \ diff --git a/examples/android/ExampleApp/app/src/main/jni/mega/Android.mk b/examples/android/ExampleApp/app/src/main/jni/mega/Android.mk index 3bd1360710..a760eb9136 100644 --- a/examples/android/ExampleApp/app/src/main/jni/mega/Android.mk +++ b/examples/android/ExampleApp/app/src/main/jni/mega/Android.mk @@ -11,7 +11,7 @@ local_c_includes := \ include $(CLEAR_VARS) include $(LOCAL_PATH)/Makefile.inc LOCAL_MODULE := megasdk -LOCAL_CFLAGS := -fexceptions -frtti -fvisibility=hidden -fvisibility-inlines-hidden -fdata-sections -ffunction-sections -DDEBUG -DENABLE_CHAT +LOCAL_CFLAGS := -fvisibility=hidden -fvisibility-inlines-hidden -fdata-sections -ffunction-sections -DDEBUG -DENABLE_CHAT LOCAL_SRC_FILES := $(CPP_SOURCES) $(C_SOURCES) $(C_WRAPPER_SOURCES) LOCAL_C_INCLUDES += $(local_c_includes) LOCAL_EXPORT_C_INCLUDES += $(local_c_includes) diff --git a/examples/android/ExampleApp/app/src/main/jni/openssl/Android.mk b/examples/android/ExampleApp/app/src/main/jni/openssl/Android.mk index 7fd41d923d..2d830371d4 100644 --- a/examples/android/ExampleApp/app/src/main/jni/openssl/Android.mk +++ b/examples/android/ExampleApp/app/src/main/jni/openssl/Android.mk @@ -20,7 +20,7 @@ include $(CLEAR_VARS) LOCAL_SRC_FILES := $(addprefix openssl/ssl/, ssl_conf.c t1_ext.c t1_trce.c bio_ssl.c d1_lib.c d1_srvr.c s23_meth.c s2_enc.c s2_srvr.c s3_enc.c s3_srvr.c ssl_ciph.c ssl_rsa.c t1_lib.c tls_srp.c d1_both.c d1_meth.c kssl.c s23_pkt.c s2_lib.c s3_both.c s3_lib.c ssl_algs.c ssl_err2.c ssl_sess.c ssl_txt.c t1_meth.c d1_clnt.c d1_pkt.c s23_clnt.c s23_srvr.c s2_meth.c s3_cbc.c s3_meth.c ssl_asn1.c ssl_err.c ssl_stat.c t1_clnt.c t1_reneg.c d1_srtp.c s23_lib.c s2_clnt.c s2_pkt.c s3_clnt.c s3_pkt.c ssl_cert.c ssl_lib.c t1_enc.c t1_srvr.c) LOCAL_C_INCLUDES := $(local_c_includes) LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/openssl $(LOCAL_PATH)/openssl/include $(LOCAL_PATH)/openssl/crypto -LOCAL_CFLAGS := $(local_c_flags) -fexceptions -frtti -fvisibility=hidden -fdata-sections -ffunction-sections +LOCAL_CFLAGS := $(local_c_flags) -fvisibility=hidden -fdata-sections -ffunction-sections LOCAL_SHARED_LIBRARIES := crypto LOCAL_MODULE_TAGS := optional LOCAL_MODULE := ssl @@ -28,7 +28,7 @@ include $(BUILD_STATIC_LIBRARY) include $(CLEAR_VARS) LOCAL_SRC_FILES := $(addprefix openssl/crypto/, cms/cms_asn1.c cms/cms_att.c cms/cms_cd.c cms/cms_dd.c cms/cms_enc.c cms/cms_env.c cms/cms_err.c cms/cms_ess.c cms/cms_io.c cms/cms_kari.c cms/cms_lib.c cms/cms_pwri.c cms/cms_sd.c cms/cms_smime.c ec/ec2_mult.c ec/ec2_oct.c ec/ec2_smpl.c ec/ec_ameth.c ec/ec_asn1.c ec/ec_check.c ec/ec_curve.c ec/ec_cvt.c ec/ec_err.c ec/ec_key.c ec/eck_prn.c ec/ec_lib.c ec/ec_mult.c ec/ec_oct.c ec/ec_pmeth.c ec/ecp_mont.c ec/ecp_nist.c ec/ecp_nistp224.c ec/ecp_nistp256.c ec/ecp_nistp521.c ec/ecp_nistputil.c ec/ecp_oct.c ec/ec_print.c ec/ecp_smpl.c ecdsa/ecs_asn1.c ecdsa/ecs_err.c ecdsa/ecs_lib.c ecdsa/ecs_ossl.c ecdsa/ecs_sign.c ecdsa/ecs_vrf.c ecdh/ech_err.c ecdh/ech_kdf.c ecdh/ech_key.c ecdh/ech_lib.c ecdh/ech_ossl.c stack/stack.c o_fips.c asn1/f_int.c asn1/asn1_err.c asn1/x_spki.c asn1/d2i_pu.c asn1/x_val.c asn1/x_bignum.c asn1/x_info.c asn1/p5_pbe.c asn1/a_object.c asn1/asn1_par.c asn1/asn_moid.c asn1/a_verify.c asn1/tasn_typ.c asn1/x_attrib.c asn1/x_algor.c asn1/a_octet.c asn1/a_digest.c asn1/tasn_utl.c asn1/x_exten.c asn1/a_print.c asn1/a_strnid.c asn1/p8_pkey.c asn1/t_req.c asn1/bio_asn1.c asn1/a_utctm.c asn1/t_crl.c asn1/x_req.c asn1/t_pkey.c asn1/nsseq.c asn1/a_dup.c asn1/a_set.c asn1/f_enum.c asn1/x_nx509.c asn1/evp_asn1.c asn1/t_bitst.c asn1/x_x509.c asn1/t_x509.c asn1/n_pkey.c asn1/a_type.c asn1/x_sig.c asn1/tasn_new.c asn1/t_spki.c asn1/asn_pack.c asn1/a_bool.c asn1/p5_pbev2.c asn1/a_mbstr.c asn1/a_utf8.c asn1/tasn_dec.c asn1/x_crl.c asn1/asn1_gen.c asn1/x_long.c asn1/tasn_enc.c asn1/bio_ndef.c asn1/asn_mime.c asn1/tasn_fre.c asn1/ameth_lib.c asn1/a_bitstr.c asn1/x_pkey.c asn1/a_strex.c asn1/x_name.c asn1/i2d_pr.c asn1/a_time.c asn1/a_int.c asn1/t_x509a.c asn1/a_bytes.c asn1/f_string.c asn1/i2d_pu.c asn1/x_pubkey.c asn1/a_sign.c asn1/a_i2d_fp.c asn1/a_enum.c asn1/x_x509a.c asn1/a_gentm.c asn1/d2i_pr.c asn1/asn1_lib.c asn1/tasn_prn.c asn1/a_d2i_fp.c cmac/cm_ameth.c cmac/cmac.c cmac/cm_pmeth.c o_dir.c hmac/hm_ameth.c hmac/hm_pmeth.c hmac/hmac.c fips_ers.c sparcv9cap.c bio/b_sock.c bio/b_dump.c bio/bss_log.c bio/bss_mem.c bio/bss_fd.c bio/bss_null.c bio/bss_acpt.c bio/bio_err.c bio/bio_lib.c bio/bss_bio.c bio/bf_null.c bio/bf_nbio.c bio/bss_sock.c bio/bss_file.c bio/bss_conn.c bio/bf_buff.c bio/bf_lbuf.c bio/bio_cb.c bio/b_print.c bio/bss_dgram.c o_time.c pkcs12/p12_decr.c pkcs12/p12_attr.c pkcs12/p12_mutl.c pkcs12/p12_utl.c pkcs12/p12_crt.c pkcs12/p12_asn.c pkcs12/p12_add.c pkcs12/p12_key.c pkcs12/p12_npas.c pkcs12/p12_p8e.c pkcs12/p12_crpt.c pkcs12/pk12err.c pkcs12/p12_kiss.c pkcs12/p12_p8d.c pkcs12/p12_init.c txt_db/txt_db.c err/err_all.c err/err_prn.c err/err.c sha/sha1dgst.c sha/sha512.c sha/sha_one.c sha/sha1_one.c sha/sha_dgst.c sha/sha256.c objects/obj_dat.c objects/obj_xref.c objects/obj_err.c objects/o_names.c objects/obj_lib.c ppccap.c uid.c rand/randfile.c rand/rand_win.c rand/rand_unix.c rand/rand_egd.c rand/rand_nw.c rand/rand_vms.c rand/rand_os2.c rand/rand_lib.c rand/rand_err.c rand/md_rand.c aes/aes_core.c aes/aes_ofb.c aes/aes_cbc.c aes/aes_cfb.c aes/aes_ctr.c aes/aes_ige.c aes/aes_ecb.c aes/aes_wrap.c aes/aes_misc.c conf/conf_mod.c conf/conf_lib.c conf/conf_mall.c conf/conf_err.c conf/conf_api.c conf/conf_def.c conf/conf_sap.c ts/ts_rsp_sign.c ts/ts_rsp_print.c ts/ts_rsp_verify.c ts/ts_err.c ts/ts_rsp_utils.c ts/ts_conf.c ts/ts_lib.c ts/ts_req_print.c ts/ts_req_utils.c ts/ts_verify_ctx.c ts/ts_asn1.c srp/srp_vfy.c srp/srp_lib.c o_str.c pem/pem_oth.c pem/pem_lib.c pem/pem_all.c pem/pem_xaux.c pem/pem_pkey.c pem/pvkfmt.c pem/pem_seal.c pem/pem_err.c pem/pem_sign.c pem/pem_x509.c pem/pem_info.c pem/pem_pk8.c mem_clr.c rsa/rsa_err.c rsa/rsa_none.c rsa/rsa_eay.c rsa/rsa_prn.c rsa/rsa_ameth.c rsa/rsa_depr.c rsa/rsa_ssl.c rsa/rsa_chk.c rsa/rsa_pss.c rsa/rsa_lib.c rsa/rsa_oaep.c rsa/rsa_asn1.c rsa/rsa_saos.c rsa/rsa_null.c rsa/rsa_x931.c rsa/rsa_crpt.c rsa/rsa_gen.c rsa/rsa_sign.c rsa/rsa_pmeth.c rsa/rsa_pk1.c x509v3/v3_scts.c x509v3/v3_prn.c x509v3/v3_akeya.c x509v3/v3_lib.c x509v3/v3_extku.c x509v3/v3_purp.c x509v3/v3_enum.c x509v3/v3_ocsp.c x509v3/v3_skey.c x509v3/v3_pcia.c x509v3/v3_pci.c x509v3/v3_sxnet.c x509v3/v3_ncons.c x509v3/v3_addr.c x509v3/v3_int.c x509v3/v3_genn.c x509v3/v3_ia5.c x509v3/v3_pku.c x509v3/pcy_map.c x509v3/v3_asid.c x509v3/v3_utl.c x509v3/v3_bcons.c x509v3/pcy_node.c x509v3/pcy_data.c x509v3/v3_cpols.c x509v3/v3_info.c x509v3/v3_akey.c x509v3/v3_pcons.c x509v3/v3_alt.c x509v3/pcy_cache.c x509v3/v3_crld.c x509v3/pcy_lib.c x509v3/v3_bitst.c x509v3/v3_pmaps.c x509v3/pcy_tree.c x509v3/v3_conf.c x509v3/v3err.c o_init.c evp/bio_b64.c evp/bio_enc.c evp/bio_md.c evp/bio_ok.c evp/c_all.c evp/c_allc.c evp/c_alld.c evp/digest.c evp/e_aes.c evp/e_aes_cbc_hmac_sha1.c evp/e_aes_cbc_hmac_sha256.c evp/e_bf.c evp/e_camellia.c evp/e_cast.c evp/e_des3.c evp/e_des.c evp/e_idea.c evp/encode.c evp/e_null.c evp/e_old.c evp/e_rc2.c evp/e_rc4.c evp/e_rc4_hmac_md5.c evp/e_rc5.c evp/e_seed.c evp/evp_acnf.c evp/evp_cnf.c evp/evp_enc.c evp/evp_err.c evp/evp_key.c evp/evp_lib.c evp/evp_pbe.c evp/evp_pkey.c evp/e_xcbc_d.c evp/m_dss1.c evp/m_dss.c evp/m_ecdsa.c evp/m_md2.c evp/m_md4.c evp/m_md5.c evp/m_mdc2.c evp/m_null.c evp/m_ripemd.c evp/m_sha1.c evp/m_sha.c evp/m_sigver.c evp/m_wp.c evp/names.c evp/openbsd_hw.c evp/p5_crpt2.c evp/p5_crpt.c evp/p_dec.c evp/p_enc.c evp/p_lib.c evp/pmeth_fn.c evp/pmeth_gn.c evp/pmeth_lib.c evp/p_open.c evp/p_seal.c evp/p_sign.c evp/p_verify.c cversion.c threads/th-lock.c krb5/krb5_asn.c des/ecb_enc.c des/set_key.c des/enc_writ.c des/fcrypt.c des/cfb_enc.c des/cfb64enc.c des/ede_cbcm_enc.c des/cfb64ede.c des/des_old.c des/enc_read.c des/cbc_enc.c des/ofb_enc.c des/des_old2.c des/cbc_cksm.c des/cbc3_enc.c des/fcrypt_b.c des/des_enc.c des/ncbc_enc.c des/rpc_enc.c des/xcbc_enc.c des/ecb3_enc.c des/ofb64ede.c des/qud_cksm.c des/ofb64enc.c des/pcbc_enc.c des/str2key.c des/read2pwd.c des/rand_key.c buffer/buffer.c buffer/buf_err.c buffer/buf_str.c mem_dbg.c rc2/rc2cfb64.c rc2/rc2_ecb.c rc2/rc2_skey.c rc2/rc2ofb64.c rc2/rc2_cbc.c bn/bn_rand.c bn/bn_sqrt.c bn/bn_mul.c bn/bn_exp.c bn/bn_const.c bn/bn_print.c bn/bn_gcd.c bn/bn_word.c bn/bn_div.c bn/bn_gf2m.c bn/bn_mod.c bn/bn_mont.c bn/bn_exp2.c bn/vms-helper.c bn/bn_asm.c bn/bn_recp.c bn/bn_shift.c bn/bn_depr.c bn/bn_mpi.c bn/bn_kron.c bn/bn_ctx.c bn/bn_prime.c bn/bn_err.c bn/bn_nist.c bn/bn_sqr.c bn/bn_blind.c bn/bn_lib.c bn/bn_x931p.c bn/bn_add.c cpt_err.c lhash/lh_stats.c lhash/lhash.c cryptlib.c ripemd/rmd_one.c ripemd/rmd_dgst.c modes/wrap128.c modes/ccm128.c modes/gcm128.c modes/ofb128.c modes/cfb128.c modes/ctr128.c modes/cts128.c modes/cbc128.c modes/xts128.c ebcdic.c s390xcap.c x509/x509_att.c x509/x509_v3.c x509/x509type.c x509/by_file.c x509/x509_lu.c x509/x509_vpm.c x509/x509cset.c x509/x509spki.c x509/x509_trs.c x509/x509_ext.c x509/x_all.c x509/x509_d2.c x509/x509_req.c x509/x509_set.c x509/x509rset.c x509/x509name.c x509/x509_def.c x509/x509_txt.c x509/x509_r2x.c x509/x509_obj.c x509/x509_vfy.c x509/x509_cmp.c x509/by_dir.c x509/x509_err.c md5/md5_one.c md5/md5_dgst.c ocsp/ocsp_asn.c ocsp/ocsp_prn.c ocsp/ocsp_ext.c ocsp/ocsp_ht.c ocsp/ocsp_cl.c ocsp/ocsp_vfy.c ocsp/ocsp_lib.c ocsp/ocsp_srv.c ocsp/ocsp_err.c md4/md4_dgst.c md4/md4_one.c dso/dso_lib.c dso/dso_dlfcn.c dso/dso_win32.c dso/dso_beos.c dso/dso_openssl.c dso/dso_vms.c dso/dso_dl.c dso/dso_null.c dso/dso_err.c ex_data.c ui/ui_lib.c ui/ui_openssl.c ui/ui_util.c ui/ui_compat.c ui/ui_err.c pkcs7/pk7_dgst.c pkcs7/pkcs7err.c pkcs7/pk7_attr.c pkcs7/pk7_lib.c pkcs7/pk7_doit.c pkcs7/bio_pk7.c pkcs7/pk7_asn1.c pkcs7/pk7_mime.c pkcs7/pk7_smime.c mem.c pqueue/pqueue.c comp/c_rle.c comp/comp_err.c comp/c_zlib.c comp/comp_lib.c rc4/rc4_utl.c rc4/rc4_skey.c rc4/rc4_enc.c) -LOCAL_CFLAGS := $(local_c_flags) -fexceptions -frtti -fvisibility=hidden -fdata-sections -ffunction-sections +LOCAL_CFLAGS := $(local_c_flags) -fvisibility=hidden -fdata-sections -ffunction-sections LOCAL_C_INCLUDES := $(local_c_includes) LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/openssl $(LOCAL_PATH)/openssl/include $(LOCAL_PATH)/openssl/crypto LOCAL_MODULE_TAGS := optional diff --git a/examples/android/ExampleApp/app/src/main/jni/sqlite/Android.mk b/examples/android/ExampleApp/app/src/main/jni/sqlite/Android.mk index b2f6c57688..41bd43e91b 100644 --- a/examples/android/ExampleApp/app/src/main/jni/sqlite/Android.mk +++ b/examples/android/ExampleApp/app/src/main/jni/sqlite/Android.mk @@ -2,7 +2,7 @@ LOCAL_PATH := $(call my-dir) include $(CLEAR_VARS) LOCAL_MODULE := sqlite -LOCAL_CFLAGS := -fexceptions -frtti -fvisibility=hidden -fvisibility-inlines-hidden -fdata-sections -ffunction-sections +LOCAL_CFLAGS := -fvisibility=hidden -fvisibility-inlines-hidden -fdata-sections -ffunction-sections LOCAL_SRC_FILES := sqlite/sqlite3.c LOCAL_C_INCLUDES += sqlite/sqlite3.h LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/sqlite diff --git a/examples/android/ExampleApp/build.gradle b/examples/android/ExampleApp/build.gradle index e0b366a781..e60d05d293 100644 --- a/examples/android/ExampleApp/build.gradle +++ b/examples/android/ExampleApp/build.gradle @@ -3,10 +3,10 @@ buildscript { repositories { jcenter() + google() } dependencies { - classpath 'com.android.tools.build:gradle:1.5.0' - + classpath 'com.android.tools.build:gradle:3.2.1' // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files } @@ -15,6 +15,7 @@ buildscript { allprojects { repositories { jcenter() + google() } } diff --git a/examples/android/ExampleApp/gradle/wrapper/gradle-wrapper.properties b/examples/android/ExampleApp/gradle/wrapper/gradle-wrapper.properties index f23df6e463..5b8a5255c1 100644 --- a/examples/android/ExampleApp/gradle/wrapper/gradle-wrapper.properties +++ b/examples/android/ExampleApp/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ -#Wed Oct 21 11:34:03 PDT 2015 +#Wed Sep 26 14:04:24 CEST 2018 distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-2.8-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-all.zip diff --git a/examples/iOS/Demo/Demo.xcodeproj/project.pbxproj b/examples/iOS/Demo/Demo.xcodeproj/project.pbxproj index e76edde3ac..2075528b44 100644 --- a/examples/iOS/Demo/Demo.xcodeproj/project.pbxproj +++ b/examples/iOS/Demo/Demo.xcodeproj/project.pbxproj @@ -39,16 +39,20 @@ 41C681F31A23658C0088F2E6 /* MEGASdkManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 41C681F21A23658C0088F2E6 /* MEGASdkManager.m */; }; 41D4EADD19EED5270097C00F /* libresolv.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 41D4EADC19EED5270097C00F /* libresolv.dylib */; }; 943D11F91A25F25100318442 /* MEGAphoto.m in Sources */ = {isa = PBXBuildFile; fileRef = 943D11F81A25F25100318442 /* MEGAphoto.m */; }; - A88EE21B1F0A63B600AECF76 /* libcares.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2151F0A63B600AECF76 /* libcares.a */; }; - A88EE21C1F0A63B600AECF76 /* libcrypto.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2161F0A63B600AECF76 /* libcrypto.a */; }; - A88EE21D1F0A63B600AECF76 /* libcryptopp.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2171F0A63B600AECF76 /* libcryptopp.a */; }; - A88EE21E1F0A63B600AECF76 /* libcurl.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2181F0A63B600AECF76 /* libcurl.a */; }; - A88EE21F1F0A63B600AECF76 /* libssl.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2191F0A63B600AECF76 /* libssl.a */; }; - A88EE2201F0A63B600AECF76 /* libuv.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE21A1F0A63B600AECF76 /* libuv.a */; }; A88EE2211F0A63FB00AECF76 /* ImageIO.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 41AB68FD1A094459003FE608 /* ImageIO.framework */; }; A88EE2221F0A641400AECF76 /* MobileCoreServices.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 41AB68F91A0943FE003FE608 /* MobileCoreServices.framework */; }; - A88EE2241F0A642300AECF76 /* libsodium.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2231F0A642300AECF76 /* libsodium.a */; }; A88EE2251F0A642F00AECF76 /* MapKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 41ACFBC61A1155AC00905ACF /* MapKit.framework */; }; + A8BF10C121ED1114006B283A /* AVFoundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF10C021ED1114006B283A /* AVFoundation.framework */; }; + A8BF10C321ED111A006B283A /* CoreMedia.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF10C221ED1119006B283A /* CoreMedia.framework */; }; + A8BF10C421ED1175006B283A /* libcares.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2151F0A63B600AECF76 /* libcares.a */; }; + A8BF10C521ED1175006B283A /* libcrypto.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2161F0A63B600AECF76 /* libcrypto.a */; }; + A8BF10C621ED1175006B283A /* libcryptopp.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2171F0A63B600AECF76 /* libcryptopp.a */; }; + A8BF10C721ED1175006B283A /* libcurl.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2181F0A63B600AECF76 /* libcurl.a */; }; + A8BF10C821ED1175006B283A /* libmediainfo.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF10BD21ED10E5006B283A /* libmediainfo.a */; }; + A8BF10C921ED1175006B283A /* libsodium.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2231F0A642300AECF76 /* libsodium.a */; }; + A8BF10CA21ED1175006B283A /* libssl.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE2191F0A63B600AECF76 /* libssl.a */; }; + A8BF10CB21ED1175006B283A /* libuv.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A88EE21A1F0A63B600AECF76 /* libuv.a */; }; + A8BF10CC21ED1175006B283A /* libzen.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A8BF10BB21ED10E5006B283A /* libzen.a */; }; E80D15911A236C7100148421 /* Helper.m in Sources */ = {isa = PBXBuildFile; fileRef = E80D15901A236C7100148421 /* Helper.m */; }; /* End PBXBuildFile section */ @@ -124,6 +128,10 @@ A88EE2191F0A63B600AECF76 /* libssl.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libssl.a; path = ../../../bindings/ios/3rdparty/lib/libssl.a; sourceTree = ""; }; A88EE21A1F0A63B600AECF76 /* libuv.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libuv.a; path = ../../../bindings/ios/3rdparty/lib/libuv.a; sourceTree = ""; }; A88EE2231F0A642300AECF76 /* libsodium.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libsodium.a; path = ../../../bindings/ios/3rdparty/lib/libsodium.a; sourceTree = ""; }; + A8BF10BB21ED10E5006B283A /* libzen.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libzen.a; path = ../../../bindings/ios/3rdparty/lib/libzen.a; sourceTree = ""; }; + A8BF10BD21ED10E5006B283A /* libmediainfo.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libmediainfo.a; path = ../../../bindings/ios/3rdparty/lib/libmediainfo.a; sourceTree = ""; }; + A8BF10C021ED1114006B283A /* AVFoundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AVFoundation.framework; path = System/Library/Frameworks/AVFoundation.framework; sourceTree = SDKROOT; }; + A8BF10C221ED1119006B283A /* CoreMedia.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreMedia.framework; path = System/Library/Frameworks/CoreMedia.framework; sourceTree = SDKROOT; }; E80D158F1A236C7100148421 /* Helper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Helper.h; sourceTree = ""; }; E80D15901A236C7100148421 /* Helper.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = Helper.m; sourceTree = ""; }; E85477501A24944900C848F8 /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/Main.strings; sourceTree = ""; }; @@ -137,16 +145,20 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( + A8BF10C421ED1175006B283A /* libcares.a in Frameworks */, + A8BF10C521ED1175006B283A /* libcrypto.a in Frameworks */, + A8BF10C621ED1175006B283A /* libcryptopp.a in Frameworks */, + A8BF10C721ED1175006B283A /* libcurl.a in Frameworks */, + A8BF10C821ED1175006B283A /* libmediainfo.a in Frameworks */, + A8BF10C921ED1175006B283A /* libsodium.a in Frameworks */, + A8BF10CA21ED1175006B283A /* libssl.a in Frameworks */, + A8BF10CB21ED1175006B283A /* libuv.a in Frameworks */, + A8BF10CC21ED1175006B283A /* libzen.a in Frameworks */, + A8BF10C321ED111A006B283A /* CoreMedia.framework in Frameworks */, + A8BF10C121ED1114006B283A /* AVFoundation.framework in Frameworks */, A88EE2251F0A642F00AECF76 /* MapKit.framework in Frameworks */, - A88EE2241F0A642300AECF76 /* libsodium.a in Frameworks */, A88EE2221F0A641400AECF76 /* MobileCoreServices.framework in Frameworks */, A88EE2211F0A63FB00AECF76 /* ImageIO.framework in Frameworks */, - A88EE21B1F0A63B600AECF76 /* libcares.a in Frameworks */, - A88EE21C1F0A63B600AECF76 /* libcrypto.a in Frameworks */, - A88EE21D1F0A63B600AECF76 /* libcryptopp.a in Frameworks */, - A88EE21E1F0A63B600AECF76 /* libcurl.a in Frameworks */, - A88EE21F1F0A63B600AECF76 /* libssl.a in Frameworks */, - A88EE2201F0A63B600AECF76 /* libuv.a in Frameworks */, 414295FB1B13399800639A20 /* libMEGASDK.a in Frameworks */, 4135AEA819F58ED700A8A56A /* libMWPhotoBrowser.a in Frameworks */, 41D4EADD19EED5270097C00F /* libresolv.dylib in Frameworks */, @@ -225,6 +237,10 @@ 4168129C19EE6E6D00C72800 /* Frameworks */ = { isa = PBXGroup; children = ( + A8BF10C221ED1119006B283A /* CoreMedia.framework */, + A8BF10C021ED1114006B283A /* AVFoundation.framework */, + A8BF10BD21ED10E5006B283A /* libmediainfo.a */, + A8BF10BB21ED10E5006B283A /* libzen.a */, A88EE2231F0A642300AECF76 /* libsodium.a */, A88EE2151F0A63B600AECF76 /* libcares.a */, A88EE2161F0A63B600AECF76 /* libcrypto.a */, @@ -375,7 +391,7 @@ isa = PBXProject; attributes = { CLASSPREFIX = ""; - LastUpgradeCheck = 0600; + LastUpgradeCheck = 1010; ORGANIZATIONNAME = MEGA; TargetAttributes = { 4168127019EE6E5700C72800 = { @@ -534,25 +550,38 @@ isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = YES; + CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; COPY_PHASE_STRIP = NO; ENABLE_BITCODE = NO; ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; GCC_C_LANGUAGE_STANDARD = gnu99; GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; GCC_OPTIMIZATION_LEVEL = 0; GCC_PREPROCESSOR_DEFINITIONS = ( "DEBUG=1", @@ -565,7 +594,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 9.0; + IPHONEOS_DEPLOYMENT_TARGET = 12.1; MTL_ENABLE_DEBUG_INFO = YES; ONLY_ACTIVE_ARCH = YES; SDKROOT = iphoneos; @@ -576,17 +605,28 @@ isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = YES; + CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; @@ -595,13 +635,14 @@ ENABLE_NS_ASSERTIONS = NO; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; GCC_WARN_64_TO_32_BIT_CONVERSION = YES; GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; GCC_WARN_UNDECLARED_SELECTOR = YES; GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 9.0; + IPHONEOS_DEPLOYMENT_TARGET = 12.1; MTL_ENABLE_DEBUG_INFO = NO; SDKROOT = iphoneos; VALIDATE_PRODUCT = YES; @@ -615,13 +656,14 @@ CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; INFOPLIST_FILE = Demo/Info.plist; - IPHONEOS_DEPLOYMENT_TARGET = 7.0; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; LIBRARY_SEARCH_PATHS = ( "$(inherited)", "$(PROJECT_DIR)/../../../bindings/ios/3rdparty/lib", ); - OTHER_LDFLAGS = "-ObjC"; + OTHER_LDFLAGS = ""; + PRODUCT_BUNDLE_IDENTIFIER = "MEGA.$(PRODUCT_NAME:rfc1034identifier)"; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE = ""; USER_HEADER_SEARCH_PATHS = "../../../bindings/ios ../../../include/** Demo/vendor/MWPhotoBrowser/**"; @@ -635,13 +677,14 @@ CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; INFOPLIST_FILE = Demo/Info.plist; - IPHONEOS_DEPLOYMENT_TARGET = 7.0; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; LIBRARY_SEARCH_PATHS = ( "$(inherited)", "$(PROJECT_DIR)/../../../bindings/ios/3rdparty/lib", ); - OTHER_LDFLAGS = "-ObjC"; + OTHER_LDFLAGS = ""; + PRODUCT_BUNDLE_IDENTIFIER = "MEGA.$(PRODUCT_NAME:rfc1034identifier)"; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE = ""; USER_HEADER_SEARCH_PATHS = "../../../bindings/ios ../../../include/** Demo/vendor/MWPhotoBrowser/**"; diff --git a/examples/iOS/Demo/Demo/Info.plist b/examples/iOS/Demo/Demo/Info.plist index 2cda3bbca3..993496b977 100644 --- a/examples/iOS/Demo/Demo/Info.plist +++ b/examples/iOS/Demo/Demo/Info.plist @@ -5,7 +5,7 @@ CFBundleExecutable $(EXECUTABLE_NAME) CFBundleIdentifier - MEGA.$(PRODUCT_NAME:rfc1034identifier) + $(PRODUCT_BUNDLE_IDENTIFIER) CFBundleInfoDictionaryVersion 6.0 CFBundleLocalizations diff --git a/examples/iOS/Demo/Demo/Login/LoginViewController.m b/examples/iOS/Demo/Demo/Login/LoginViewController.m index 779a0dd230..009a9e9478 100644 --- a/examples/iOS/Demo/Demo/Login/LoginViewController.m +++ b/examples/iOS/Demo/Demo/Login/LoginViewController.m @@ -53,10 +53,7 @@ - (IBAction)tapLogin:(id)sender { } - (void)generateKeys { - NSString *privateKey = [[MEGASdkManager sharedMEGASdk] base64pwkeyForPassword:self.passwordTextField.text]; - NSString *publicKey = [[MEGASdkManager sharedMEGASdk] hashForBase64pwkey:privateKey email:self.emailTextField.text]; - - [[MEGASdkManager sharedMEGASdk] fastLoginWithEmail:self.emailTextField.text stringHash:publicKey base64pwKey:privateKey delegate:self]; + [[MEGASdkManager sharedMEGASdk] loginWithEmail:self.emailTextField.text password:self.passwordTextField.text delegate:self]; } - (BOOL)validateForm { diff --git a/examples/iOS/Demo/Demo/Utils/Helper.m b/examples/iOS/Demo/Demo/Utils/Helper.m index 8ff2b0e0c6..c1bc7a8b7b 100644 --- a/examples/iOS/Demo/Demo/Utils/Helper.m +++ b/examples/iOS/Demo/Demo/Utils/Helper.m @@ -181,7 +181,7 @@ + (UIImage *)imageForNode:(MEGANode *)node { switch (nodeType) { case MEGANodeTypeFolder: { - if ([[MEGASdkManager sharedMEGASdk] isSharedNode:node]) + if (node.isInShare) return [UIImage imageNamed:@"folder_shared"]; else return [UIImage imageNamed:@"folder"]; diff --git a/examples/iOS/Demo/Demo/vendor/MWPhotoBrowser/MWPhotoBrowser.xcodeproj/project.pbxproj b/examples/iOS/Demo/Demo/vendor/MWPhotoBrowser/MWPhotoBrowser.xcodeproj/project.pbxproj index 3e43c93e06..f410e248c3 100644 --- a/examples/iOS/Demo/Demo/vendor/MWPhotoBrowser/MWPhotoBrowser.xcodeproj/project.pbxproj +++ b/examples/iOS/Demo/Demo/vendor/MWPhotoBrowser/MWPhotoBrowser.xcodeproj/project.pbxproj @@ -475,7 +475,7 @@ 4C6F96BB14AF704100F8389A /* Project object */ = { isa = PBXProject; attributes = { - LastUpgradeCheck = 0600; + LastUpgradeCheck = 1010; }; buildConfigurationList = 4C6F96BE14AF704100F8389A /* Build configuration list for PBXProject "MWPhotoBrowser" */; compatibilityVersion = "Xcode 3.2"; @@ -548,16 +548,27 @@ isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; COPY_PHASE_STRIP = YES; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; GCC_WARN_64_TO_32_BIT_CONVERSION = YES; GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES; @@ -566,7 +577,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 5.1.1; + IPHONEOS_DEPLOYMENT_TARGET = 12.1; SDKROOT = iphoneos; VALIDATE_PRODUCT = YES; }; @@ -588,17 +599,29 @@ isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; COPY_PHASE_STRIP = NO; ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; GCC_C_LANGUAGE_STANDARD = gnu99; GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; GCC_OPTIMIZATION_LEVEL = 0; GCC_PREPROCESSOR_DEFINITIONS = ( "DEBUG=1", @@ -613,7 +636,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 5.1.1; + IPHONEOS_DEPLOYMENT_TARGET = 12.1; ONLY_ACTIVE_ARCH = YES; SDKROOT = iphoneos; }; @@ -623,16 +646,27 @@ isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; COPY_PHASE_STRIP = YES; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; GCC_WARN_64_TO_32_BIT_CONVERSION = YES; GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES; @@ -641,7 +675,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 5.1.1; + IPHONEOS_DEPLOYMENT_TARGET = 12.1; SDKROOT = iphoneos; VALIDATE_PRODUCT = YES; }; diff --git a/examples/iOS/README.md b/examples/iOS/README.md index 93aac7f9f1..44a81bbe3a 100644 --- a/examples/iOS/README.md +++ b/examples/iOS/README.md @@ -27,7 +27,7 @@ To build and run the project, follow theses steps: 1. Download or clone the whole SDK -2. Download the prebuilt third party dependencies from this link: https://mega.nz/#!YIdnRKSR!UIOuMq_h8A5CHwt7OX_THnyZ_OR1eS_cPmiwm8yxsb0 +2. Download the prebuilt third party dependencies from this link: https://mega.nz/#!gN9w0I7Q!-OPUWBoEnvXeZWkkC5oUho2MFm_49nwBwN6q07sxKII 3. Uncompress the content and move `include`and `lib`to the directory `sdk/bindings/ios/3rdparty` diff --git a/examples/megacli.cpp b/examples/megacli.cpp index dc2c81e82e..5b152220dd 100644 --- a/examples/megacli.cpp +++ b/examples/megacli.cpp @@ -5244,6 +5244,14 @@ static void process_line(char* l) { shownew = true; } + else if (words[1] == "test_reminder") + { + client->useralerts.add(new UserAlert::PaymentReminder(time(NULL) - 86000*3 /2, client->useralerts.nextId())); + } + else if (words[1] == "test_payment") + { + client->useralerts.add(new UserAlert::Payment(true, 1, time(NULL) + 86000 * 1, client->useralerts.nextId())); + } else if (atoi(words[1].c_str()) > 0) { showN = atoi(words[1].c_str()); diff --git a/examples/megasimplesync.cpp b/examples/megasimplesync.cpp index 3677a6c756..9ece8fcc78 100644 --- a/examples/megasimplesync.cpp +++ b/examples/megasimplesync.cpp @@ -30,6 +30,49 @@ using std::cout; using std::cerr; using std::endl; + + +struct Login +{ + string email, password, salt, pin; + int version; + + Login() : version(0) + { + } + + void reset() + { + *this = Login(); + } + + void login(MegaClient* client) + { + byte pwkey[SymmCipher::KEYLENGTH]; + + if (version == 1) + { + if (error e = client->pw_key(password.c_str(), pwkey)) + { + cout << "Login error: " << e << endl; + } + else + { + client->login(email.c_str(), pwkey, pin.c_str()); + } + } + else if (version == 2 && !salt.empty()) + { + client->login2(email.c_str(), password.c_str(), &salt, pin.c_str()); + } + else + { + cout << "Login unexpected error" << endl; + } + } +}; +static Login login; + class SyncApp : public MegaApp, public Logger { string local_folder; @@ -37,6 +80,8 @@ class SyncApp : public MegaApp, public Logger handle cwd; bool initial_fetch; + void prelogin_result(int version, string* email, string *salt, error e); + void login_result(error e); void fetchnodes_result(error e); @@ -319,6 +364,28 @@ void SyncApp::log(const char *time, int loglevel, const char *source, const char cout << "[" << time << "][" << SimpleLogger::toStr((LogLevel)loglevel) << "] " << message << endl; } +void SyncApp::prelogin_result(int version, std::string* email, std::string *salt, error e) +{ + if (e) + { + cout << "Login error: " << e << endl; + return; + } + + login.version = version; + login.salt = (version == 2 && salt ? *salt : string()); + + if (login.password.empty()) + { + cerr << "invalid empty password" << endl; + } + else + { + login.login(client); + } +} + + // this callback function is called when we have login result (success or // error) // TODO: check for errors @@ -570,8 +637,9 @@ int main(int argc, char *argv[]) //client->followsymlinks = true; // get values from env - client->pw_key(getenv("MEGA_PWD"), pwkey); - client->login(getenv("MEGA_EMAIL"), pwkey); + login.password = getenv("MEGA_PWD"); + login.email = getenv("MEGA_EMAIL"); + client->prelogin(login.email.c_str()); while (true) { diff --git a/include/mega/autocomplete.h b/include/mega/autocomplete.h index 1a5d394d23..6a5a721204 100644 --- a/include/mega/autocomplete.h +++ b/include/mega/autocomplete.h @@ -99,6 +99,8 @@ namespace autocomplete { // output suitable for user 'help' virtual std::ostream& describe(std::ostream& s) const = 0; + + virtual ~ACNode(); }; std::ostream& operator<<(std::ostream&, const ACNode&); diff --git a/include/mega/http.h b/include/mega/http.h index 43764c9a83..aac106e703 100644 --- a/include/mega/http.h +++ b/include/mega/http.h @@ -92,7 +92,7 @@ namespace mega { #define MEGA_DNS_SERVERS "2001:678:25c:2215::554,89.44.169.136," \ "2001:67c:1998:2212::13,31.216.148.13," \ - "2405:f900:3e6a:1::103,103.244.183.5," \ + "2405:f900:3e6a:1::103,31.216.148.11," \ "2403:9800:c020::43,122.56.56.216" class MEGA_API SpeedController diff --git a/include/mega/megaclient.h b/include/mega/megaclient.h index 87bc925cd6..5195089197 100644 --- a/include/mega/megaclient.h +++ b/include/mega/megaclient.h @@ -361,7 +361,7 @@ class MEGA_API MegaClient error rename(Node*, Node*, syncdel_t = SYNCDEL_NONE, handle = UNDEF); // start/stop/pause file transfer - bool startxfer(direction_t, File*, bool skipdupes = false, bool startfirst = false); + bool startxfer(direction_t, File*, bool skipdupes = false, bool startfirst = false, bool donotpersist = false); void stopxfer(File* f); void pausexfers(direction_t, bool, bool = false); @@ -373,7 +373,7 @@ class MEGA_API MegaClient // enqueue/abort direct read void pread(Node*, m_off_t, m_off_t, void*); - void pread(handle, SymmCipher* key, int64_t, m_off_t, m_off_t, void*, bool = false, const char* = NULL, const char* = NULL); + void pread(handle, SymmCipher* key, int64_t, m_off_t, m_off_t, void*, bool = false, const char* = NULL, const char* = NULL, const char* = NULL); void preadabort(Node*, m_off_t = -1, m_off_t = -1); void preadabort(handle, m_off_t = -1, m_off_t = -1); @@ -828,7 +828,7 @@ class MEGA_API MegaClient bool isprivatehandle(handle*); // add direct read - void queueread(handle, bool, SymmCipher*, int64_t, m_off_t, m_off_t, void*, const char* = NULL, const char* = NULL); + void queueread(handle, bool, SymmCipher*, int64_t, m_off_t, m_off_t, void*, const char* = NULL, const char* = NULL, const char* = NULL); // execute pending direct reads bool execdirectreads(); diff --git a/include/mega/transfer.h b/include/mega/transfer.h index 0680f8d50a..df4585f37b 100644 --- a/include/mega/transfer.h +++ b/include/mega/transfer.h @@ -131,6 +131,8 @@ struct MEGA_API Transfer : public FileFingerprint // state of the transfer transferstate_t state; + bool skipserialization; + Transfer(MegaClient*, direction_t); virtual ~Transfer(); @@ -234,6 +236,7 @@ struct MEGA_API DirectReadNode bool p; string publicauth; string privateauth; + string chatauth; m_off_t partiallen; dstime partialstarttime; @@ -270,7 +273,7 @@ struct MEGA_API DirectReadNode // report failure to app and abort or retry all reads void retry(error, dstime = 0); - DirectReadNode(MegaClient*, handle, bool, SymmCipher*, int64_t, const char*, const char*); + DirectReadNode(MegaClient*, handle, bool, SymmCipher*, int64_t, const char*, const char*, const char*); ~DirectReadNode(); }; } // namespace diff --git a/include/mega/types.h b/include/mega/types.h index 53b3fd527c..4e9b50193a 100644 --- a/include/mega/types.h +++ b/include/mega/types.h @@ -452,7 +452,8 @@ typedef enum { ATTR_RICH_PREVIEWS = 18, // private - byte array ATTR_RUBBISH_TIME = 19, // private, non-encrypted - char array in B64 - non-versioned ATTR_LAST_PSA = 20, // private - char array - ATTR_STORAGE_STATE = 21 // private - non-encrypted - char array in B64 - non-versioned + ATTR_STORAGE_STATE = 21, // private - non-encrypted - char array in B64 - non-versioned + ATTR_GEOLOCATION = 22 // private - byte array } attr_t; typedef map userattr_map; diff --git a/include/mega/user.h b/include/mega/user.h index af08aa06d5..34aa7ca57c 100644 --- a/include/mega/user.h +++ b/include/mega/user.h @@ -70,6 +70,7 @@ struct MEGA_API User : public Cachable bool lastPsa : 1; bool rubbishTime : 1; // days to keep nodes in rubbish bin before auto clean bool storageState : 1; // state of the storage (0 = green, 1 = orange, 2 = red) + bool geolocation : 1; // enable send geolocations } changed; // user's public key @@ -108,6 +109,7 @@ struct MEGA_API User : public Cachable void removeattr(attr_t at); static string attr2string(attr_t at); + static string attr2longname(attr_t at); static attr_t string2attr(const char *name); static bool needversioning(attr_t at); static char scope(attr_t at); diff --git a/include/mega/version.h b/include/mega/version.h index c2832c898d..9e89ef910d 100644 --- a/include/mega/version.h +++ b/include/mega/version.h @@ -5,5 +5,5 @@ #define MEGA_MINOR_VERSION 4 #endif #ifndef MEGA_MICRO_VERSION -#define MEGA_MICRO_VERSION 5 +#define MEGA_MICRO_VERSION 6 #endif diff --git a/include/mega/win32/megafs.h b/include/mega/win32/megafs.h index 2d8081c898..58f4c02085 100644 --- a/include/mega/win32/megafs.h +++ b/include/mega/win32/megafs.h @@ -90,7 +90,9 @@ struct MEGA_API WinDirNotify : public DirNotify { WinFileSystemAccess* fsaccess; +#ifdef ENABLE_SYNC LocalNode* localrootnode; +#endif HANDLE hDirectory; diff --git a/include/megaapi.h b/include/megaapi.h index 8d7ad7df46..cdf7e3296e 100644 --- a/include/megaapi.h +++ b/include/megaapi.h @@ -1171,7 +1171,8 @@ class MegaUser CHANGE_TYPE_CONTACT_LINK_VERIFICATION = 0x10000, CHANGE_TYPE_RICH_PREVIEWS = 0x20000, CHANGE_TYPE_RUBBISH_TIME = 0x40000, - CHANGE_TYPE_STORAGE_STATE = 0x80000 + CHANGE_TYPE_STORAGE_STATE = 0x80000, + CHANGE_TYPE_GEOLOCATION = 0x100000 }; /** @@ -1244,6 +1245,9 @@ class MegaUser * - MegaUser::CHANGE_TYPE_STORAGE_STATE = 0x80000 * Check if the state of the storage has changed * + * - MegaUser::CHANGE_TYPE_GEOLOCATION = 0x100000 + * Check if option for geolocation messages has changed + * * @return true if this user has an specific change */ virtual bool hasChanged(int changeType); @@ -1315,6 +1319,10 @@ class MegaUser * * - MegaUser::CHANGE_TYPE_STORAGE_STATE = 0x80000 * Check if the state of the storage has changed + * + * - MegaUser::CHANGE_TYPE_GEOLOCATION = 0x100000 + * Check if option for geolocation messages has changed + * */ virtual int getChanges(); @@ -3421,6 +3429,16 @@ class MegaTransfer */ virtual bool isSyncTransfer() const; + /** + * @brief Returns true if this transfer belongs to the backups engine + * + * This data is important to know if the transfer will resume when enableTransferResumption is called. + * Regular transfers are resumed, but backup transfers aren't. + * + * @return true if this transfer belongs to the backups engine, otherwise false + */ + virtual bool isBackupTransfer() const; + /** * @brief Returns true is this is a streaming transfer * @return true if this is a streaming transfer, false otherwise @@ -4111,7 +4129,7 @@ class MegaSync * @brief Get the path of the local folder that is being synced * * The SDK retains the ownership of the returned value. It will be valid until - * the MegaRequest object is deleted. + * the MegaSync object is deleted. * * @return Local folder that is being synced */ @@ -4210,8 +4228,13 @@ class MegaBackupListener * the application deletes it. * * There won't be more callbacks about this backup. - * The last parameter provides the result of the backup. If the backup finished without problems, - * the error code will be API_OK + * The last parameter provides the result of the backup: + * If the backup finished without problems, + * the error code will be API_OK. + * If some transfer failed, the error code will be API_EINCOMPLETE. + * If the backup has been skipped the error code will be API_EEXPIRED. + * If the backup folder cannot be found, the error will be API_ENOENT. + * * * @param api MegaApi object that started the backup * @param backup Information about the backup @@ -4295,7 +4318,7 @@ class MegaBackup * @brief Get the path of the local folder that is being backed up * * The SDK retains the ownership of the returned value. It will be valid until - * the MegaRequest object is deleted. + * the MegaBackup object is deleted. * * @return Local folder that is being backed up */ @@ -4426,25 +4449,25 @@ class MegaBackup virtual int64_t getCurrentBKStartTime() const; /** - * @brief Returns the number of transferred bytes during this request + * @brief Returns the number of transferred bytes during last backup * @return Transferred bytes during this backup */ virtual long long getTransferredBytes() const; /** - * @brief Returns the total bytes to be transferred to complete the backup + * @brief Returns the total bytes to be transferred to complete last backup * @return Total bytes to be transferred to complete the backup */ virtual long long getTotalBytes() const; /** - * @brief Returns the current speed of this backup + * @brief Returns the current speed of last backup * @return Current speed of this backup */ virtual long long getSpeed() const; /** - * @brief Returns the average speed of this backup + * @brief Returns the average speed of last backup * @return Average speed of this backup */ virtual long long getMeanSpeed() const; @@ -4460,6 +4483,15 @@ class MegaBackup */ virtual int64_t getUpdateTime() const; + /** + * @brief Returns the list with the transfers that have failed for during last backup + * + * You take the ownership of the returned value + * + * @return Names of the custom attributes of the node + * @see MegaApi::setCustomNodeAttribute + */ + virtual MegaTransferList *getFailedTransfers(); }; @@ -5734,6 +5766,7 @@ class MegaApi }; enum { + USER_ATTR_UNKNOWN = -1, USER_ATTR_AVATAR = 0, // public - char array USER_ATTR_FIRSTNAME = 1, // public - char array USER_ATTR_LASTNAME = 2, // public - char array @@ -5751,7 +5784,8 @@ class MegaApi USER_ATTR_RICH_PREVIEWS = 18, // private - byte array USER_ATTR_RUBBISH_TIME = 19, // private - byte array USER_ATTR_LAST_PSA = 20, // private - char array - USER_ATTR_STORAGE_STATE = 21 // private - char array + USER_ATTR_STORAGE_STATE = 21, // private - char array + USER_ATTR_GEOLOCATION = 22 // private - byte array }; enum { @@ -6218,6 +6252,31 @@ class MegaApi */ void retryPendingConnections(bool disconnect = false, bool includexfers = false, MegaRequestListener* listener = NULL); + /** + * @brief Use custom DNS servers + * + * The SDK tries to automatically get and use DNS servers configured in the system at startup. This function can be used + * to override that automatic detection and use a custom list of DNS servers. It is also useful to provide working + * DNS servers to the SDK in platforms in which it can't get them from the system (Windows Phone and Universal Windows Platform). + * + * Since the usage of this function implies a change in DNS servers used by the SDK, all connections are + * closed and restarted using the new list of new DNS servers, so calling this function too often can cause + * many retries and problems to complete requests. Please use it only at startup or when DNS servers need to be changed. + * + * The associated request type with this request is MegaRequest::TYPE_RETRY_PENDING_CONNECTIONS. + * Valid data in the MegaRequest object received on callbacks: + * - MegaRequest::getText - Returns the new list of DNS servers + * + * @param dnsServers New list of DNS servers. It must be a list of IPs separated by a comma character ",". + * IPv6 servers are allowed (without brackets). + * + * The usage of this function will trigger the callback MegaGlobalListener::onEvent and the callback + * MegaListener::onEvent with the event type MegaEvent::EVENT_DISCONNECT. + * + * @param listener MegaRequestListener to track this request + */ + void setDnsServers(const char *dnsServers, MegaRequestListener* listener = NULL); + /** * @brief Check if server-side Rubbish Bin autopurging is enabled for the current account * @return True if this feature is enabled. Otherwise false. @@ -7953,11 +8012,40 @@ class MegaApi * Get number of days for rubbish-bin cleaning scheduler (private non-encrypted) * MegaApi::USER_ATTR_STORAGE_STATE = 21 * Get the state of the storage (private non-encrypted) + * MegaApi::USER_ATTR_GEOLOCATION = 22 + * Get whether the user has enabled send geolocation messages (private) * * @param listener MegaRequestListener to track this request */ void getUserAttribute(int type, MegaRequestListener *listener = NULL); + /** + * @brief Get the name associated to a user attribute + * + * You take the ownership of the returned value. + * + * @param attr Attribute + * @return name associated to the user attribute + */ + const char *userAttributeToString(int attr); + + /** + * @brief Get the long descriptive name associated to a user attribute + * + * You take the ownership of the returned value. + * + * @param attr Attribute + * @return descriptive name associated to the user attribute + */ + const char *userAttributeToLongName(int attr); + + /** + * @brief Get numeric value for user attribute given a string + * @param name Name of the attribute + * @return numeric value for user attribute + */ + int userAttributeFromString(const char *name); + /** * @brief Get the email address of any user in MEGA. * @@ -8098,6 +8186,8 @@ class MegaApi * Get whether user generates rich-link messages or not (private) * MegaApi::USER_ATTR_RUBBISH_TIME = 19 * Set number of days for rubbish-bin cleaning scheduler (private non-encrypted) + * MegaApi::USER_ATTR_GEOLOCATION = 22 + * Set whether the user can send geolocation messages (private) * * @param value New attribute value * @param listener MegaRequestListener to track this request @@ -8605,6 +8695,7 @@ class MegaApi */ void isMasterKeyExported(MegaRequestListener *listener = NULL); +#ifdef ENABLE_CHAT /** * @brief Enable or disable the generation of rich previews * @@ -8672,6 +8763,33 @@ class MegaApi */ void setRichLinkWarningCounterValue(int value, MegaRequestListener *listener = NULL); + /** + * @brief Enable the sending of geolocation messages + * + * The associated request type with this request is MegaRequest::TYPE_SET_ATTR_USER + * Valid data in the MegaRequest object received on callbacks: + * - MegaRequest::getParamType - Returns the attribute type MegaApi::USER_ATTR_GEOLOCATION + * + * @param listener MegaRequestListener to track this request + */ + void enableGeolocation(MegaRequestListener *listener = NULL); + + /** + * @brief Check if the sending of geolocation messages is enabled + * + * The associated request type with this request is MegaRequest::TYPE_GET_ATTR_USER + * Valid data in the MegaRequest object received on callbacks: + * - MegaRequest::getParamType - Returns the attribute type MegaApi::USER_ATTR_GEOLOCATION + * + * Sending a Geolocation message is enabled if the MegaRequest object, received in onRequestFinish, + * has error code MegaError::API_OK. In other cases, send geolocation messages is not enabled and + * the application has to answer before send a message of this type. + * + * @param listener MegaRequestListener to track this request + */ + void isGeolocationEnabled(MegaRequestListener *listener = NULL); +#endif + /** * @brief Get the number of days for rubbish-bin cleaning scheduler * @@ -12774,8 +12892,8 @@ class MegaApi * is MegaError::API_OK: * - MegaRequest::getMegaTextChatList - Returns the new chat's information * - * @note If you are trying to create a chat with more than 1 other person, then it will be forced - * to be a group chat. + * On the onRequestFinish error, the error code associated to the MegaError can be: + * - MegaError::API_EACCESS - If more than 1 peer is provided for a 1on1 chatroom. * * @note If peers list contains only one person, group chat is not set and a permament chat already * exists with that person, then this call will return the information for the existing chat, rather @@ -12816,6 +12934,9 @@ class MegaApi * is MegaError::ERROR_OK: * - MegaChatRequest::getChatHandle - Returns the handle of the new chatroom * + * On the onRequestFinish error, the error code associated to the MegaError can be: + * - MegaError::API_EARGS - If the number of keys doesn't match the number of peers plus one (own user) + * * @param peers MegaChatPeerList including other users and their privilege level * @param title Byte array that contains the chat topic if exists. NULL if no custom title is required. * @param userKeyMap MegaStringMap of user handles in B64 as keys, and unified keys in B64 as values. Own user included @@ -12841,10 +12962,11 @@ class MegaApi * - MegaRequest::getFlag - Returns false (private/closed mode) * - MegaRequest::getSessionKey - Returns the unified key for the new peer * - * On the onTransferFinish error, the error code associated to the MegaError can be: - * - MegaError::API_EACCESS - If the logged in user doesn't have privileges to invite peers. - * - MegaError::API_EARGS - If there's a title and it's not Base64url encoded. - + * On the onRequestFinish error, the error code associated to the MegaError can be: + * - MegaError::API_EACCESS - If the logged in user doesn't have privileges to invite peers or the chatroom is in public mode. + * - MegaError::API_EINCOMPLETE - If no valid title is provided and the chatroom has a custom title already. + * - MegaError::API_ENOENT- If no valid chatid or user handle is provided, of if the chatroom does not exists. + * * @param chatid MegaHandle that identifies the chat room * @param uh MegaHandle that identifies the user * @param privilege Privilege level for the new peers. Valid values are: @@ -12871,10 +12993,12 @@ class MegaApi * - MegaRequest::getFlag - Returns true (open/public mode) * - MegaRequest::getSessionKey - Returns the unified key for the new peer * - * On the onTransferFinish error, the error code associated to the MegaError can be: - * - MegaError::API_EACCESS - If the logged in user doesn't have privileges to invite peers. + * On the onRequestFinish error, the error code associated to the MegaError can be: + * - MegaError::API_EACCESS - If the logged in user doesn't have privileges to invite peers or the chatroom is in private mode. * - MegaError::API_EARGS - If there's a title and it's not Base64url encoded. - + * - MegaError::API_ENOENT- If no valid chatid or user handle is provided, of if the chatroom does not exists. + * - MegaError::API_EINCOMPLETE - If no unified key is provided. + * * @param chatid MegaHandle that identifies the chat room * @param uh MegaHandle that identifies the user * @param privilege Privilege level for the new peers. Valid values are: @@ -12898,6 +13022,11 @@ class MegaApi * - MegaRequest::getNodeHandle - Returns the chat identifier * - MegaRequest::getParentHandle - Returns the MegaHandle of the user to be removed * + * On the onRequestFinish error, the error code associated to the MegaError can be: + * - MegaError::API_ENOENT- If no valid chatid is provided or the chatroom does not exists. + * - MegaError::API_EACCESS - If the chatroom is 1on1 or the caller is not operator or is not a + * chat member, or the target is not a chat member. + * * @param chatid MegaHandle that identifies the chat room * @param uh MegaHandle that identifies the user. If not provided (INVALID_HANDLE), the requester is removed * @param listener MegaRequestListener to track this request @@ -12932,6 +13061,12 @@ class MegaApi * - MegaRequest::getParentHandle - Returns the chat identifier * - MegaRequest::getEmail - Returns the MegaHandle of the user in Base64 enconding * + * On the onRequestFinish error, the error code associated to the MegaError can be: + * - MegaError::API_ENOENT- If the chatroom, the node or the target user don't exist. + * - MegaError::API_EACCESS- If the target user is the same as caller, or if the target + * user is anonymous but the chatroom is in private mode, or if caller is not an operator + * or the target user is not a chat member. + * * @param chatid MegaHandle that identifies the chat room * @param n MegaNode that wants to be shared * @param uh MegaHandle that identifies the user @@ -12948,6 +13083,9 @@ class MegaApi * - MegaRequest::getParentHandle - Returns the chat identifier * - MegaRequest::getEmail - Returns the MegaHandle of the user in Base64 enconding * + * On the onRequestFinish error, the error code associated to the MegaError can be: + * - MegaError::API_ENOENT- If the chatroom, the node or the target user don't exist. + * * @param chatid MegaHandle that identifies the chat room * @param n MegaNode whose access wants to be revokesd * @param uh MegaHandle that identifies the user @@ -12966,6 +13104,10 @@ class MegaApi * is to be upgraded * - MegaRequest::getAccess - Returns the privilege level wanted for the user * + * On the onRequestFinish error, the error code associated to the MegaError can be: + * - MegaError::API_ENOENT- If the chatroom doesn't exist or if the user specified is not a participant. + * - MegaError::API_EACCESS- If caller is not operator or the chatroom is 1on1. + * * @param chatid MegaHandle that identifies the chat room * @param uh MegaHandle that identifies the user * @param privilege Privilege level for the existing peer. Valid values are: @@ -13003,7 +13145,7 @@ class MegaApi * Valid data in the MegaRequest object received on callbacks: * - MegaRequest::getText - Returns the title of the chat. * - * On the onTransferFinish error, the error code associated to the MegaError can be: + * On the onRequestFinish error, the error code associated to the MegaError can be: * - MegaError::API_EACCESS - If the logged in user doesn't have privileges to invite peers. * - MegaError::API_EARGS - If there's a title and it's not Base64url encoded. * @@ -13139,6 +13281,9 @@ class MegaApi * - MegaRequest::getNodeHandle - Returns the chat identifier * - MegaRequest::getFlag - Returns chat desired state * + * On the onRequestFinish error, the error code associated to the MegaError can be: + * - MegaError::API_ENOENT - If the chatroom does not exists. + * * @param chatid MegaHandle that identifies the chat room * @param archive Desired chat state * @param listener MegaRequestListener to track this request @@ -13176,9 +13321,9 @@ class MegaApi * is MegaError::API_OK: * - MegaRequest::getParentHandle - Returns the public handle of the chat link, if any * - * If caller is not operator or the chat is not a public chat or it's a 1on1 room, this request - * will return API_EACCESS. - * If the chatroom does not have a chatlink, this request will return MegaError::API_ENOENT. + * On the onTransferFinish error, the error code associated to the MegaError can be: + * - MegaError::API_ENOENT - If the chatroom does not have a valid chatlink, or the chatroom does not exists. + * - MegaError::API_EACCESS - If caller is not operator or the chat is not a public chat or it's a 1on1 room. * * @param chatid MegaHandle that identifies the chat room * @param listener MegaRequestListener to track this request @@ -13200,8 +13345,9 @@ class MegaApi * is MegaError::API_OK: * - MegaRequest::getParentHandle - Returns the public handle of the chat link * - * If caller is not operator or the chat is not a public chat or it's a 1on1 room, this request - * will return API_EACCESS. + * On the onRequestFinish error, the error code associated to the MegaError can be: + * - MegaError::API_ENOENT - If the chatroom does not have a valid chatlink, or the chatroom does not exists. + * - MegaError::API_EACCESS - If caller is not operator or the chat is not a public chat or it's a 1on1 room. * * @param chatid MegaHandle that identifies the chat room * @param listener MegaRequestListener to track this request @@ -13219,9 +13365,9 @@ class MegaApi * Valid data in the MegaRequest object received on all callbacks: * - MegaRequest::getNodeHandle - Returns the chat identifier * - * If caller is not operator or the chat is not an public chat or it's a 1on1 room, this request - * will return MegaError::API_EACCESS. - * If the chatroom does not have a chatlink, this request will return MegaError::API_ENOENT. + * On the onRequestFinish error, the error code associated to the MegaError can be: + * - MegaError::API_ENOENT - If the chatroom does not have a valid chatlink, or the chatroom does not exists. + * - MegaError::API_EACCESS - If caller is not operator or the chat is not a public chat or it's a 1on1 room. * * @param chatid MegaHandle that identifies the chat room * @param listener MegaRequestListener to track this request @@ -13252,6 +13398,9 @@ class MegaApi * - MegaRequest::getNumDetails - Returns the current number of participants * - MegaRequest::getNumber - Returns the creation timestamp * + * On the onRequestFinish error, the error code associated to the MegaError can be: + * - MegaError::API_ENOENT - If the public handle is not valid or the chatroom does not exists. + * * @note This function can be called without being logged in. In that case, the returned * URL will be different than for logged in users, so chatd knows whether user has a session. * @@ -13275,8 +13424,11 @@ class MegaApi * - MegaRequest::getNodeHandle - Returns the chat identifier * - MegaRequest::getText - Returns the title of the chat * - * If caller is not operator or it's a 1on1 room, this request will return MegaError::API_EACCESS. - * If the chat is not an public chat, this request will return MegaError::API_EEXIST. + * On the onRequestFinish error, the error code associated to the MegaError can be: + * - MegaError::API_ENOENT - If the chatroom does not exists. + * - MegaError::API_EACCESS - If caller is not operator or it's a 1on1 room. + * - MegaError::API_EEXIST - If the chat is already in private mode. + * - MegaError::API_EARGS - If custom title is set and no title is provided. * * @param chatid MegaHandle that identifies the chat room * @param title Byte array representing the title, already encrypted and converted to Base64url @@ -13299,6 +13451,10 @@ class MegaApi * - MegaRequest::getNodeHandle - Returns the public handle of the chat link * - MegaRequest::getSessionKey - Returns the unified key of the chat link * + * On the onRequestFinish error, the error code associated to the MegaError can be: + * - MegaError::API_ENOENT - If the public handle is not valid. + * - MegaError::API_EINCOMPLETE - If the no unified key is provided. + * * @param publichandle MegaHandle that represents the public handle of the chat link * @param unifiedKey Byte array that contains the unified key, already encrypted and * converted to Base64url encoding. diff --git a/include/megaapi_impl.h b/include/megaapi_impl.h index a36c0ebdb7..25c9b28871 100644 --- a/include/megaapi_impl.h +++ b/include/megaapi_impl.h @@ -229,7 +229,7 @@ class MegaBackupController : public MegaBackup, public MegaRequestListener, publ void update(); void start(bool skip = false); - void removeexceeding(); + void removeexceeding(bool currentoneOK); void abortCurrent(); // MegaBackup interface @@ -243,6 +243,8 @@ class MegaBackupController : public MegaBackup, public MegaRequestListener, publ int getState() const; long long getNextStartTime(long long oldStartTimeAbsolute = -1) const; bool getAttendPastBackups() const; + MegaTransferList *getFailedTransfers(); + // MegaBackup setters void setLocalFolder(const std::string &value); @@ -299,7 +301,7 @@ class MegaBackupController : public MegaBackup, public MegaRequestListener, publ handle currentHandle; std::string currentName; std::list pendingFolders; - std::list failedTransfers; + std::vector failedTransfers; int recursive; int pendingTransfers; int pendingTags; @@ -331,6 +333,7 @@ class MegaBackupController : public MegaBackup, public MegaRequestListener, publ virtual void onRequestFinish(MegaApi* api, MegaRequest *request, MegaError *e); virtual void onTransferStart(MegaApi *api, MegaTransfer *transfer); virtual void onTransferUpdate(MegaApi *api, MegaTransfer *transfer); + virtual void onTransferTemporaryError(MegaApi *, MegaTransfer *t, MegaError* e); virtual void onTransferFinish(MegaApi* api, MegaTransfer *transfer, MegaError *e); long long getNumberFolders() const; @@ -651,6 +654,7 @@ class MegaTransferPrivate : public MegaTransfer, public Cachable void setSyncTransfer(bool syncTransfer); void setSourceFileTemporary(bool temporary); void setStartFirst(bool startFirst); + void setBackupTransfer(bool backupTransfer); void setStreamingTransfer(bool streamingTransfer); void setLastBytes(char *lastBytes); void setLastError(MegaError e); @@ -689,6 +693,7 @@ class MegaTransferPrivate : public MegaTransfer, public Cachable virtual bool isFinished() const; virtual bool isSourceFileTemporary() const; virtual bool shouldStartFirst() const; + virtual bool isBackupTransfer() const; virtual char *getLastBytes() const; virtual MegaError getLastError() const; virtual bool isFolderTransfer() const; @@ -716,6 +721,7 @@ class MegaTransferPrivate : public MegaTransfer, public Cachable bool streamingTransfer : 1; bool temporarySourceFile : 1; bool startFirst : 1; + bool backupTransfer : 1; }; int64_t startTime; @@ -1753,8 +1759,11 @@ class MegaApiImpl : public MegaApp static char *userHandleToBase64(MegaHandle handle); static const char* ebcEncryptKey(const char* encryptionKey, const char* plainKey); void retryPendingConnections(bool disconnect = false, bool includexfers = false, MegaRequestListener* listener = NULL); + void setDnsServers(const char *dnsServers, MegaRequestListener* listener = NULL); static void addEntropy(char* data, unsigned int size); static string userAttributeToString(int); + static string userAttributeToLongName(int); + static int userAttributeFromString(const char *name); static char userAttributeToScope(int); static void setStatsID(const char *id); @@ -1863,10 +1872,6 @@ class MegaApiImpl : public MegaApp void getChatUserAttr(const char* email_or_handle, int type, const char *dstFilePath, const char *ph = NULL, int number = 0, MegaRequestListener *listener = NULL); void setUserAttribute(int type, const char* value, MegaRequestListener *listener = NULL); void setUserAttribute(int type, const MegaStringMap* value, MegaRequestListener *listener = NULL); - void enableRichPreviews(bool enable, MegaRequestListener *listener = NULL); - void isRichPreviewsEnabled(MegaRequestListener *listener = NULL); - void shouldShowRichLinkWarning(MegaRequestListener *listener = NULL); - void setRichLinkWarningCounterValue(int value, MegaRequestListener *listener = NULL); void getRubbishBinAutopurgePeriod(MegaRequestListener *listener = NULL); void setRubbishBinAutopurgePeriod(int days, MegaRequestListener *listener = NULL); void getUserEmail(MegaHandle handle, MegaRequestListener *listener = NULL); @@ -1923,7 +1928,7 @@ class MegaApiImpl : public MegaApp void startUpload(const char* localPath, MegaNode *parent, MegaTransferListener *listener=NULL); void startUpload(const char* localPath, MegaNode *parent, int64_t mtime, MegaTransferListener *listener=NULL); void startUpload(const char* localPath, MegaNode* parent, const char* fileName, MegaTransferListener *listener = NULL); - void startUpload(bool startFirst, const char* localPath, MegaNode* parent, const char* fileName, int64_t mtime, int folderTransferTag = 0, const char *appData = NULL, bool isSourceFileTemporary = false, MegaTransferListener *listener = NULL); + void startUpload(bool startFirst, const char* localPath, MegaNode* parent, const char* fileName, int64_t mtime, int folderTransferTag, bool isBackup, const char *appData, bool isSourceFileTemporary, MegaTransferListener *listener); void startDownload(MegaNode* node, const char* localPath, MegaTransferListener *listener = NULL); void startDownload(bool startFirst, MegaNode *node, const char* target, int folderTransferTag, const char *appData, MegaTransferListener *listener); void startStreaming(MegaNode* node, m_off_t startPos, m_off_t size, MegaTransferListener *listener); @@ -2259,6 +2264,12 @@ class MegaApiImpl : public MegaApp void getChatLinkURL(MegaHandle publichandle, MegaRequestListener *listener = NULL); void chatLinkClose(MegaHandle chatid, const char *title, MegaRequestListener *listener = NULL); void chatLinkJoin(MegaHandle publichandle, const char *unifiedkey, MegaRequestListener *listener = NULL); + void enableRichPreviews(bool enable, MegaRequestListener *listener = NULL); + void isRichPreviewsEnabled(MegaRequestListener *listener = NULL); + void shouldShowRichLinkWarning(MegaRequestListener *listener = NULL); + void setRichLinkWarningCounterValue(int value, MegaRequestListener *listener = NULL); + void enableGeolocation(MegaRequestListener *listener = NULL); + void isGeolocationEnabled(MegaRequestListener *listener = NULL); #endif void getAccountAchievements(MegaRequestListener *listener = NULL); diff --git a/src/autocomplete.cpp b/src/autocomplete.cpp index d5388f7fc6..b26af5da82 100644 --- a/src/autocomplete.cpp +++ b/src/autocomplete.cpp @@ -76,7 +76,7 @@ ACState::quoting::quoting() ACState::quoting::quoting(std::string& s) { - quoted = !s.empty() && s[0] == '\"' || s[0] == '\''; + quoted = (!s.empty() && s[0] == '\"') || (s[0] == '\''); if (quoted) { quote_char = s[0]; @@ -187,6 +187,10 @@ std::ostream& operator<<(std::ostream& s, const ACNode& n) return n.describe(s); } +ACNode::~ACNode() +{ +} + Optional::Optional(ACN n) : subnode(n) { @@ -211,7 +215,7 @@ std::ostream& Optional::describe(std::ostream& s) const if (auto e = dynamic_cast(subnode.get())) { std::ostringstream s2; - s2 << *subnode; + s2 << *e; std::string str = s2.str(); if (str.size() >= 2 && str.front() == '(' && str.back() == ')') { @@ -542,8 +546,8 @@ bool LocalFS::addCompletions(ACState& s) { for (fs::directory_iterator iter(searchPath); iter != fs::directory_iterator(); ++iter) { - if (reportFolders && fs::is_directory(iter->status()) || - reportFiles && fs::is_regular_file(iter->status())) + if ((reportFolders && fs::is_directory(iter->status())) || + (reportFiles && fs::is_regular_file(iter->status()))) { s.addPathCompletion(iter->path().u8string(), cp, fs::is_directory(iter->status()), sep, true); } @@ -580,10 +584,10 @@ std::ostream& LocalFS::describe(std::ostream& s) const } MegaFS::MegaFS(bool files, bool folders, MegaClient* c, ::mega::handle* curDirHandle, const std::string descriptionPrefix) - : reportFiles(files) - , reportFolders(folders) - , client(c) + : client(c) , cwd(curDirHandle) + , reportFiles(files) + , reportFolders(folders) , descPref(descriptionPrefix) { } @@ -713,8 +717,8 @@ bool MegaFS::addCompletions(ACState& s) { for (Node* subnode : n->children) { - if (reportFolders && subnode->type == FOLDERNODE || - reportFiles && subnode->type == FILENODE) + if ((reportFolders && subnode->type == FOLDERNODE) || + (reportFiles && subnode->type == FILENODE)) { s.addPathCompletion(pathprefix + subnode->displayname(), "", subnode->type == FOLDERNODE, '/', false); } diff --git a/src/commands.cpp b/src/commands.cpp index b6d1c2083f..bbcd2566c6 100644 --- a/src/commands.cpp +++ b/src/commands.cpp @@ -408,6 +408,11 @@ CommandDirectRead::CommandDirectRead(MegaClient *client, DirectReadNode* cdrn) arg("en", drn->publicauth.c_str()); } + if (drn->chatauth.size()) + { + arg("cauth", drn->chatauth.c_str()); + } + if (client->usehttps) { arg("ssl", 2); @@ -2473,8 +2478,6 @@ CommandPutMultipleUAVer::CommandPutMultipleUAVer(MegaClient *client, const usera endarray(); } - notself(client); - tag = ctag; } @@ -2603,8 +2606,6 @@ CommandPutUAVer::CommandPutUAVer(MegaClient* client, attr_t at, const byte* av, endarray(); - notself(client); - tag = ctag; } @@ -2669,8 +2670,6 @@ CommandPutUA::CommandPutUA(MegaClient* client, attr_t at, const byte* av, unsign arg(an.c_str(), av, avl); } - notself(client); - tag = ctag; } @@ -5390,6 +5389,10 @@ void CommandChatRemove::procresult() if (uh == client->me) { chat->priv = PRIV_RM; + + // clear the list of peers (if re-invited, peers will be re-added) + delete chat->userpriv; + chat->userpriv = NULL; } chat->setTag(tag ? tag : -1); diff --git a/src/megaapi.cpp b/src/megaapi.cpp index bacf82238e..7ab22d4d08 100644 --- a/src/megaapi.cpp +++ b/src/megaapi.cpp @@ -994,6 +994,11 @@ bool MegaTransfer::isFinished() const return false; } +bool MegaTransfer::isBackupTransfer() const +{ + return false; +} + char *MegaTransfer::getLastBytes() const { return NULL; @@ -1646,6 +1651,11 @@ void MegaApi::retryPendingConnections(bool disconnect, bool includexfers, MegaRe pImpl->retryPendingConnections(disconnect, includexfers, listener); } +void MegaApi::setDnsServers(const char *dnsServers, MegaRequestListener *listener) +{ + pImpl->setDnsServers(dnsServers, listener); +} + bool MegaApi::serverSideRubbishBinAutopurgeEnabled() { return pImpl->serverSideRubbishBinAutopurgeEnabled(); @@ -2048,6 +2058,21 @@ void MegaApi::getUserAttribute(int type, MegaRequestListener *listener) pImpl->getUserAttribute((MegaUser*)NULL, type, listener); } +const char *MegaApi::userAttributeToString(int attr) +{ + return MegaApi::strdup(pImpl->userAttributeToString(attr).c_str()); +} + +const char *MegaApi::userAttributeToLongName(int attr) +{ + return MegaApi::strdup(pImpl->userAttributeToLongName(attr).c_str()); +} + +int MegaApi::userAttributeFromString(const char *name) +{ + return pImpl->userAttributeFromString(name); +} + void MegaApi::getUserEmail(MegaHandle handle, MegaRequestListener *listener) { pImpl->getUserEmail(handle, listener); @@ -2213,6 +2238,7 @@ void MegaApi::isMasterKeyExported(MegaRequestListener *listener) pImpl->getUserAttr((const char*)NULL, MegaApi::USER_ATTR_PWD_REMINDER, NULL, 0, listener); } +#ifdef ENABLE_CHAT void MegaApi::enableRichPreviews(bool enable, MegaRequestListener *listener) { pImpl->enableRichPreviews(enable, listener); @@ -2233,6 +2259,17 @@ void MegaApi::setRichLinkWarningCounterValue(int value, MegaRequestListener *lis pImpl->setRichLinkWarningCounterValue(value, listener); } +void MegaApi::enableGeolocation(MegaRequestListener *listener) +{ + pImpl->enableGeolocation(listener); +} + +void MegaApi::isGeolocationEnabled(MegaRequestListener *listener) +{ + pImpl->isGeolocationEnabled(listener); +} +#endif + void MegaApi::getRubbishBinAutopurgePeriod(MegaRequestListener *listener) { pImpl->getRubbishBinAutopurgePeriod(listener); @@ -2497,17 +2534,17 @@ void MegaApi::startTimer( int64_t period, MegaRequestListener *listener) void MegaApi::startUploadWithData(const char *localPath, MegaNode *parent, const char *appData, MegaTransferListener *listener) { - pImpl->startUpload(false, localPath, parent, (const char *)NULL, -1, 0, appData, false, listener); + pImpl->startUpload(false, localPath, parent, (const char *)NULL, -1, 0, false, appData, false, listener); } void MegaApi::startUploadWithData(const char *localPath, MegaNode *parent, const char *appData, bool isSourceTemporary, MegaTransferListener *listener) { - pImpl->startUpload(false, localPath, parent, (const char *)NULL, -1, 0, appData, isSourceTemporary, listener); + pImpl->startUpload(false, localPath, parent, (const char *)NULL, -1, 0, false, appData, isSourceTemporary, listener); } void MegaApi::startUploadWithTopPriority(const char *localPath, MegaNode *parent, const char *appData, bool isSourceTemporary, MegaTransferListener *listener) { - pImpl->startUpload(true, localPath, parent, (const char *)NULL, -1, 0, appData, isSourceTemporary, listener); + pImpl->startUpload(true, localPath, parent, (const char *)NULL, -1, 0, false, appData, isSourceTemporary, listener); } void MegaApi::startUpload(const char *localPath, MegaNode *parent, int64_t mtime, MegaTransferListener *listener) @@ -2517,7 +2554,7 @@ void MegaApi::startUpload(const char *localPath, MegaNode *parent, int64_t mtime void MegaApi::startUpload(const char *localPath, MegaNode *parent, int64_t mtime, bool isSourceTemporary, MegaTransferListener *listener) { - pImpl->startUpload(false, localPath, parent, (const char *)NULL, mtime, 0, NULL, isSourceTemporary, listener); + pImpl->startUpload(false, localPath, parent, (const char *)NULL, mtime, 0, false, NULL, isSourceTemporary, listener); } void MegaApi::startUpload(const char* localPath, MegaNode* parent, const char* fileName, MegaTransferListener *listener) @@ -2527,7 +2564,7 @@ void MegaApi::startUpload(const char* localPath, MegaNode* parent, const char* f void MegaApi::startUpload(const char *localPath, MegaNode *parent, const char *fileName, int64_t mtime, MegaTransferListener *listener) { - pImpl->startUpload(false, localPath, parent, fileName, mtime, 0, NULL, false, listener); + pImpl->startUpload(false, localPath, parent, fileName, mtime, 0, false, NULL, false, listener); } void MegaApi::startDownload(MegaNode *node, const char* localFolder, MegaTransferListener *listener) @@ -5034,6 +5071,11 @@ int64_t MegaBackup::getUpdateTime() const return 0; } +MegaTransferList *MegaBackup::getFailedTransfers() +{ + return NULL; +} + MegaAccountBalance::~MegaAccountBalance() { diff --git a/src/megaapi_impl.cpp b/src/megaapi_impl.cpp index c182a4bb44..3b64562543 100644 --- a/src/megaapi_impl.cpp +++ b/src/megaapi_impl.cpp @@ -1577,6 +1577,10 @@ MegaUserPrivate::MegaUserPrivate(User *user) : MegaUser() { changed |= MegaUser::CHANGE_TYPE_STORAGE_STATE; } + if(user->changed.geolocation) + { + changed |= MegaUser::CHANGE_TYPE_GEOLOCATION; + } } MegaUserPrivate::MegaUserPrivate(MegaUser *user) : MegaUser() @@ -2007,6 +2011,7 @@ MegaTransferPrivate::MegaTransferPrivate(int type, MegaTransferListener *listene this->streamingTransfer = false; this->temporarySourceFile = false; this->startFirst = false; + this->backupTransfer = false; this->lastError = API_OK; this->folderTransferTag = 0; this->appData = NULL; @@ -2054,6 +2059,7 @@ MegaTransferPrivate::MegaTransferPrivate(const MegaTransferPrivate *transfer) this->setStreamingTransfer(transfer->isStreamingTransfer()); this->setSourceFileTemporary(transfer->isSourceFileTemporary()); this->setStartFirst(transfer->shouldStartFirst()); + this->setBackupTransfer(transfer->isBackupTransfer()); this->setLastError(transfer->getLastError()); this->setFolderTransferTag(transfer->getFolderTransferTag()); this->setAppData(transfer->getAppData()); @@ -2130,6 +2136,11 @@ bool MegaTransferPrivate::isFinished() const return state == STATE_COMPLETED || state == STATE_CANCELLED || state == STATE_FAILED; } +bool MegaTransferPrivate::isBackupTransfer() const +{ + return backupTransfer; +} + bool MegaTransferPrivate::isSourceFileTemporary() const { return temporarySourceFile; @@ -2525,6 +2536,11 @@ void MegaTransferPrivate::setStartFirst(bool startFirst) this->startFirst = startFirst; } +void MegaTransferPrivate::setBackupTransfer(bool backupTransfer) +{ + this->backupTransfer = backupTransfer; +} + void MegaTransferPrivate::setStreamingTransfer(bool streamingTransfer) { this->streamingTransfer = streamingTransfer; @@ -4946,6 +4962,17 @@ void MegaApiImpl::retryPendingConnections(bool disconnect, bool includexfers, Me waiter->notify(); } +void MegaApiImpl::setDnsServers(const char *dnsServers, MegaRequestListener *listener) +{ + MegaRequestPrivate *request = new MegaRequestPrivate(MegaRequest::TYPE_RETRY_PENDING_CONNECTIONS); + request->setFlag(true); + request->setNumber(true); + request->setText(dnsServers); + request->setListener(listener); + requestQueue.push(request); + waiter->notify(); +} + void MegaApiImpl::addEntropy(char *data, unsigned int size) { if(PrnGen::rng.CanIncorporateEntropy()) @@ -4960,83 +4987,21 @@ void MegaApiImpl::addEntropy(char *data, unsigned int size) string MegaApiImpl::userAttributeToString(int type) { - string attrname; - - switch(type) - { - case MegaApi::USER_ATTR_AVATAR: - attrname = "+a"; - break; - - case MegaApi::USER_ATTR_FIRSTNAME: - attrname = "firstname"; - break; - - case MegaApi::USER_ATTR_LASTNAME: - attrname = "lastname"; - break; - - case MegaApi::USER_ATTR_AUTHRING: - attrname = "*!authring"; - break; - - case MegaApi::USER_ATTR_LAST_INTERACTION: - attrname = "*!lstint"; - break; - - case MegaApi::USER_ATTR_ED25519_PUBLIC_KEY: - attrname = "+puEd255"; - break; - - case MegaApi::USER_ATTR_CU25519_PUBLIC_KEY: - attrname = "+puCu255"; - break; - - case MegaApi::USER_ATTR_SIG_RSA_PUBLIC_KEY: - attrname = "+sigPubk"; - break; - - case MegaApi::USER_ATTR_SIG_CU255_PUBLIC_KEY: - attrname = "+sigCu255"; - break; - - case MegaApi::USER_ATTR_KEYRING: - attrname = "*keyring"; - break; - - case MegaApi::USER_ATTR_LANGUAGE: - attrname = "^!lang"; - - case MegaApi::USER_ATTR_PWD_REMINDER: - attrname = "^!prd"; - break; - - case MegaApi::USER_ATTR_DISABLE_VERSIONS: - attrname = "^!dv"; - break; - - case MegaApi::USER_ATTR_CONTACT_LINK_VERIFICATION: - attrname = "^clv"; - break; - - case MegaApi::USER_ATTR_RICH_PREVIEWS: - attrname = "*!rp"; - break; - - case MegaApi::USER_ATTR_LAST_PSA: - attrname = "^!lastPsa"; - break; + return User::attr2string((::mega::attr_t) type); +} - case MegaApi::USER_ATTR_RUBBISH_TIME: - attrname = "^!rubbishtime"; - break; +string MegaApiImpl::userAttributeToLongName(int type) +{ + return User::attr2longname((::mega::attr_t) type); +} - case MegaApi::USER_ATTR_STORAGE_STATE: - attrname = "^!usl"; - break; +int MegaApiImpl::userAttributeFromString(const char *name) +{ + if (!name) + { + return MegaApi::USER_ATTR_UNKNOWN; } - - return attrname; + return User::string2attr(name); } char MegaApiImpl::userAttributeToScope(int type) @@ -5062,6 +5027,7 @@ char MegaApiImpl::userAttributeToScope(int type) case MegaApi::USER_ATTR_LAST_INTERACTION: case MegaApi::USER_ATTR_KEYRING: case MegaApi::USER_ATTR_RICH_PREVIEWS: + case MegaApi::USER_ATTR_GEOLOCATION: scope = '*'; break; @@ -5547,7 +5513,7 @@ void MegaApiImpl::loop() while (true) { #ifdef WINDOWS_PHONE - client->httpio->getMEGADNSservers(&servers); + client->httpio->getMEGADNSservers(&servers, false); #else __res_state res; bool valid; @@ -5596,9 +5562,8 @@ void MegaApiImpl::loop() #endif } - LOG_debug << "Using MEGA DNS servers " << servers; + LOG_debug << "Using DNS servers " << servers; httpio->setdnsservers(servers.c_str()); - #elif _WIN32 httpio->lock(); #endif @@ -5922,47 +5887,6 @@ void MegaApiImpl::setUserAttribute(int type, const MegaStringMap *value, MegaReq waiter->notify(); } -void MegaApiImpl::enableRichPreviews(bool enable, MegaRequestListener *listener) -{ - MegaStringMap *stringMap = new MegaStringMapPrivate(); - string rawvalue = enable ? "1" : "0"; - string base64value; - Base64::btoa(rawvalue, base64value); - stringMap->set("num", base64value.c_str()); - setUserAttribute(MegaApi::USER_ATTR_RICH_PREVIEWS, stringMap, listener); - delete stringMap; -} - -void MegaApiImpl::isRichPreviewsEnabled(MegaRequestListener *listener) -{ - MegaRequestPrivate *request = new MegaRequestPrivate(MegaRequest::TYPE_GET_ATTR_USER, listener); - request->setParamType(MegaApi::USER_ATTR_RICH_PREVIEWS); - request->setNumDetails(0); // 0 --> flag should indicate whether rich-links are enabled or not - requestQueue.push(request); - waiter->notify(); -} - -void MegaApiImpl::shouldShowRichLinkWarning(MegaRequestListener *listener) -{ - MegaRequestPrivate *request = new MegaRequestPrivate(MegaRequest::TYPE_GET_ATTR_USER, listener); - request->setParamType(MegaApi::USER_ATTR_RICH_PREVIEWS); - request->setNumDetails(1); // 1 --> flag should indicate whether to show the warning or not - requestQueue.push(request); - waiter->notify(); -} - -void MegaApiImpl::setRichLinkWarningCounterValue(int value, MegaRequestListener *listener) -{ - MegaStringMap *stringMap = new MegaStringMapPrivate(); - std::ostringstream oss; - oss << value; - string base64value; - Base64::btoa(oss.str(), base64value); - stringMap->set("c", base64value.c_str()); - setUserAttribute(MegaApi::USER_ATTR_RICH_PREVIEWS, stringMap, listener); - delete stringMap; -} - void MegaApiImpl::getRubbishBinAutopurgePeriod(MegaRequestListener *listener) { MegaRequestPrivate *request = new MegaRequestPrivate(MegaRequest::TYPE_GET_ATTR_USER, listener); @@ -7174,9 +7098,7 @@ void MegaApiImpl::startTimer( int64_t period, MegaRequestListener *listener) waiter->notify(); } - - -void MegaApiImpl::startUpload(bool startFirst, const char *localPath, MegaNode *parent, const char *fileName, int64_t mtime, int folderTransferTag, const char *appData, bool isSourceFileTemporary, MegaTransferListener *listener) +void MegaApiImpl::startUpload(bool startFirst, const char *localPath, MegaNode *parent, const char *fileName, int64_t mtime, int folderTransferTag, bool isBackup, const char *appData, bool isSourceFileTemporary, MegaTransferListener *listener) { MegaTransferPrivate* transfer = new MegaTransferPrivate(MegaTransfer::TYPE_UPLOAD, listener); if(localPath) @@ -7199,6 +7121,8 @@ void MegaApiImpl::startUpload(bool startFirst, const char *localPath, MegaNode * transfer->setSourceFileTemporary(isSourceFileTemporary); transfer->setStartFirst(startFirst); + transfer->setBackupTransfer(isBackup); + if(fileName) { transfer->setFileName(fileName); @@ -7216,13 +7140,13 @@ void MegaApiImpl::startUpload(bool startFirst, const char *localPath, MegaNode * } void MegaApiImpl::startUpload(const char* localPath, MegaNode* parent, MegaTransferListener *listener) -{ return startUpload(false, localPath, parent, (const char *)NULL, -1, 0, NULL, false, listener); } +{ return startUpload(false, localPath, parent, (const char *)NULL, -1, 0, false, NULL, false, listener); } void MegaApiImpl::startUpload(const char *localPath, MegaNode *parent, int64_t mtime, MegaTransferListener *listener) -{ return startUpload(false, localPath, parent, (const char *)NULL, mtime, 0, NULL, false, listener); } +{ return startUpload(false, localPath, parent, (const char *)NULL, mtime, 0, false, NULL, false, listener); } void MegaApiImpl::startUpload(const char* localPath, MegaNode* parent, const char* fileName, MegaTransferListener *listener) -{ return startUpload(false, localPath, parent, fileName, -1, 0, NULL, false, listener); } +{ return startUpload(false, localPath, parent, fileName, -1, 0, false, NULL, false, listener); } void MegaApiImpl::startDownload(bool startFirst, MegaNode *node, const char* localPath, int folderTransferTag, const char *appData, MegaTransferListener *listener) { @@ -7338,7 +7262,7 @@ void MegaApiImpl::retryTransfer(MegaTransfer *transfer, MegaTransferListener *li { MegaNode *parent = getNodeByHandle(t->getParentHandle()); startUpload(t->shouldStartFirst(), t->getPath(), parent, t->getFileName(), t->getTime(), 0, - t->getAppData(), t->isSourceFileTemporary(), listener); + t->isBackupTransfer(), t->getAppData(), t->isSourceFileTemporary(), listener); delete parent; } } @@ -9054,6 +8978,65 @@ void MegaApiImpl::chatLinkJoin(MegaHandle publichandle, const char *unifiedkey, waiter->notify(); } +void MegaApiImpl::enableRichPreviews(bool enable, MegaRequestListener *listener) +{ + MegaStringMap *stringMap = new MegaStringMapPrivate(); + string rawvalue = enable ? "1" : "0"; + string base64value; + Base64::btoa(rawvalue, base64value); + stringMap->set("num", base64value.c_str()); + setUserAttribute(MegaApi::USER_ATTR_RICH_PREVIEWS, stringMap, listener); + delete stringMap; +} + +void MegaApiImpl::isRichPreviewsEnabled(MegaRequestListener *listener) +{ + MegaRequestPrivate *request = new MegaRequestPrivate(MegaRequest::TYPE_GET_ATTR_USER, listener); + request->setParamType(MegaApi::USER_ATTR_RICH_PREVIEWS); + request->setNumDetails(0); // 0 --> flag should indicate whether rich-links are enabled or not + requestQueue.push(request); + waiter->notify(); +} + +void MegaApiImpl::shouldShowRichLinkWarning(MegaRequestListener *listener) +{ + MegaRequestPrivate *request = new MegaRequestPrivate(MegaRequest::TYPE_GET_ATTR_USER, listener); + request->setParamType(MegaApi::USER_ATTR_RICH_PREVIEWS); + request->setNumDetails(1); // 1 --> flag should indicate whether to show the warning or not + requestQueue.push(request); + waiter->notify(); +} + +void MegaApiImpl::setRichLinkWarningCounterValue(int value, MegaRequestListener *listener) +{ + MegaStringMap *stringMap = new MegaStringMapPrivate(); + std::ostringstream oss; + oss << value; + string base64value; + Base64::btoa(oss.str(), base64value); + stringMap->set("c", base64value.c_str()); + setUserAttribute(MegaApi::USER_ATTR_RICH_PREVIEWS, stringMap, listener); + delete stringMap; +} + +void MegaApiImpl::enableGeolocation(MegaRequestListener *listener) +{ + MegaStringMap *stringMap = new MegaStringMapPrivate(); + string base64value; + Base64::btoa("1", base64value); + stringMap->set("v", base64value.c_str()); + setUserAttribute(MegaApi::USER_ATTR_GEOLOCATION, stringMap, listener); + delete stringMap; +} + +void MegaApiImpl::isGeolocationEnabled(MegaRequestListener *listener) +{ + MegaRequestPrivate *request = new MegaRequestPrivate(MegaRequest::TYPE_GET_ATTR_USER, listener); + request->setParamType(MegaApi::USER_ATTR_GEOLOCATION); + requestQueue.push(request); + waiter->notify(); +} + #endif void MegaApiImpl::getAccountAchievements(MegaRequestListener *listener) @@ -16189,7 +16172,7 @@ void MegaApiImpl::sendPendingTransfers() string wFileName = fileName; MegaFilePut *f = new MegaFilePut(client, &wLocalPath, &wFileName, transfer->getParentHandle(), "", mtime, isSourceTemporary); f->setTransfer(transfer); - bool started = client->startxfer(PUT, f, true, startFirst); + bool started = client->startxfer(PUT, f, true, startFirst, transfer->isBackupTransfer()); if (!started) { transfer->setState(MegaTransfer::STATE_QUEUED); @@ -16500,7 +16483,8 @@ void MegaApiImpl::sendPendingTransfers() MemAccess::get((const char*)publicNode->getNodeKey()->data() + SymmCipher::KEYLENGTH), startPos, totalBytes, transfer, publicNode->isForeign(), publicNode->getPrivateAuth()->c_str(), - publicNode->getPublicAuth()->c_str()); + publicNode->getPublicAuth()->c_str(), + publicNode->getChatAuth()); waiter->notify(); } } @@ -17880,20 +17864,24 @@ void MegaApiImpl::sendPendingRequests() { bool disconnect = request->getFlag(); bool includexfers = request->getNumber(); + const char *dnsservers = request->getText(); + client->abortbackoff(includexfers); - if(disconnect) + if (disconnect) { client->disconnect(); -#if defined(WINDOWS_PHONE) || TARGET_OS_IPHONE - // Workaround to get the IP of valid DNS servers on Windows Phone/iOS string servers; - + if (dnsservers && dnsservers[0]) + { + servers = dnsservers; + } + else + { +#if TARGET_OS_IPHONE + // Workaround to get the IP of valid DNS servers on iOS while (true) { - #ifdef WINDOWS_PHONE - client->httpio->getMEGADNSservers(&servers); - #else __res_state res; bool valid; if (res_ninit(&res) == 0) @@ -17929,20 +17917,20 @@ void MegaApiImpl::sendPendingRequests() res_ndestroy(&res); } - #endif if (servers.size()) break; - #ifdef WINDOWS_PHONE - std::this_thread::sleep_for(std::chrono::seconds(1)); - #else sleep(1); - #endif } - - LOG_debug << "Using MEGA DNS servers " << servers; - httpio->setdnsservers(servers.c_str()); +#endif + } +#ifndef __MINGW32__ + if (servers.size()) + { + LOG_debug << "Using DNS servers " << servers; + httpio->setdnsservers(servers.c_str()); + } #endif } @@ -19186,7 +19174,7 @@ void MegaApiImpl::sendPendingRequests() bool publicchat = (request->getAccess() == 1); MegaStringMap *userKeyMap = request->getMegaStringMap(); - if (!chatPeers) // emtpy groupchat + if (!chatPeers) // empty groupchat { MegaTextChatPeerListPrivate tmp = MegaTextChatPeerListPrivate(); request->setMegaTextChatPeerList(&tmp); @@ -19209,7 +19197,7 @@ void MegaApiImpl::sendPendingRequests() { if (!group && numPeers != 1) { - e = API_EARGS; + e = API_EACCESS; break; } } @@ -19234,11 +19222,17 @@ void MegaApiImpl::sendPendingRequests() bool publicMode = request->getFlag(); const char *unifiedKey = request->getSessionKey(); - if (chatid == INVALID_HANDLE || uh == INVALID_HANDLE || (publicMode && !unifiedKey)) + if (publicMode && !unifiedKey) { - e = API_EARGS; + e = API_EINCOMPLETE; + break; + } + + if (chatid == INVALID_HANDLE || uh == INVALID_HANDLE) + { + e = API_ENOENT; break; - } + } textchat_map::iterator it = client->chats.find(chatid); if (it == client->chats.end()) @@ -19250,7 +19244,7 @@ void MegaApiImpl::sendPendingRequests() TextChat *chat = it->second; if (chat->publicchat != publicMode) { - e = API_EARGS; + e = API_EACCESS; break; } @@ -19277,7 +19271,7 @@ void MegaApiImpl::sendPendingRequests() if (chatid == INVALID_HANDLE) { - e = API_EARGS; + e = API_ENOENT; break; } @@ -19326,7 +19320,7 @@ void MegaApiImpl::sendPendingRequests() if (chatid == INVALID_HANDLE || h == INVALID_HANDLE || !uid) { - e = API_EARGS; + e = API_ENOENT; break; } @@ -19341,7 +19335,7 @@ void MegaApiImpl::sendPendingRequests() if (chatid == INVALID_HANDLE || h == INVALID_HANDLE || !uid) { - e = API_EARGS; + e = API_ENOENT; break; } @@ -19356,10 +19350,9 @@ void MegaApiImpl::sendPendingRequests() if (chatid == INVALID_HANDLE || uh == INVALID_HANDLE) { - e = API_EARGS; + e = API_ENOENT; break; } - textchat_map::iterator it = client->chats.find(chatid); if (it == client->chats.end()) { @@ -19456,7 +19449,7 @@ void MegaApiImpl::sendPendingRequests() bool archive = request->getFlag(); if (chatid == INVALID_HANDLE) { - e = API_EARGS; + e = API_ENOENT; break; } @@ -19519,12 +19512,16 @@ void MegaApiImpl::sendPendingRequests() MegaHandle chatid = request->getNodeHandle(); bool del = request->getFlag(); bool createifmissing = request->getAccess(); - if (chatid == INVALID_HANDLE || (del && createifmissing)) + if (del && createifmissing) { e = API_EARGS; break; } - + if (chatid == INVALID_HANDLE) + { + e = API_ENOENT; + break; + } textchat_map::iterator it = client->chats.find(chatid); if (it == client->chats.end()) { @@ -19547,7 +19544,7 @@ void MegaApiImpl::sendPendingRequests() MegaHandle publichandle = request->getNodeHandle(); if (publichandle == INVALID_HANDLE) { - e = API_EARGS; + e = API_ENOENT; break; } client->chatlinkurl(publichandle); @@ -19560,7 +19557,7 @@ void MegaApiImpl::sendPendingRequests() const char *title = request->getText(); if (chatid == INVALID_HANDLE) { - e = API_EARGS; + e = API_ENOENT; break; } @@ -19583,7 +19580,7 @@ void MegaApiImpl::sendPendingRequests() } if (!chat->title.empty() && (!title || title[0] == '\0')) { - e = API_EINCOMPLETE; + e = API_EARGS; break; } @@ -19596,9 +19593,15 @@ void MegaApiImpl::sendPendingRequests() MegaHandle publichandle = request->getNodeHandle(); const char *unifiedkey = request->getSessionKey(); - if (publichandle == INVALID_HANDLE || unifiedkey == NULL) + if (publichandle == INVALID_HANDLE) { - e = API_EARGS; + e = API_ENOENT; + break; + } + + if (unifiedkey == NULL) + { + e = API_EINCOMPLETE; break; } client->chatlinkjoin(publichandle, unifiedkey); @@ -21396,7 +21399,7 @@ void MegaFolderUploadController::onFolderAvailable(MegaHandle handle) pendingTransfers++; string utf8path; client->fsaccess->local2path(&localPath, &utf8path); - megaApi->startUpload(false, utf8path.c_str(), parent, (const char *)NULL, -1, tag, NULL, false, this); + megaApi->startUpload(false, utf8path.c_str(), parent, (const char *)NULL, -1, tag, false, NULL, false, this); } else { @@ -21511,6 +21514,8 @@ MegaBackupController::MegaBackupController(MegaApiImpl *megaApi, int tag, int fo this->attendPastBackups = attendPastBackups; + this->pendingTags = 0; + clearCurrentBackupData(); lastbackuptime = getLastBackupTime(); @@ -21539,7 +21544,7 @@ MegaBackupController::MegaBackupController(MegaApiImpl *megaApi, int tag, int fo megaApi->startTimer(this->startTime - Waiter::ds + 1); //wake the sdk when required this->state = MegaBackup::BACKUP_ACTIVE; megaApi->fireOnBackupStateChanged(this); - removeexceeding(); + removeexceeding(false); } else { @@ -21570,7 +21575,7 @@ MegaBackupController::MegaBackupController(MegaBackupController *backup) this->pendingFolders.push_back(*it); } - for (std::list::iterator it = backup->failedTransfers.begin(); it != backup->failedTransfers.end(); it++) + for (std::vector::iterator it = backup->failedTransfers.begin(); it != backup->failedTransfers.end(); it++) { this->failedTransfers.push_back(((MegaTransfer *)*it)->copy()); } @@ -21696,7 +21701,7 @@ void MegaBackupController::update() } } -void MegaBackupController::removeexceeding() +void MegaBackupController::removeexceeding(bool currentoneOK) { map backupTimesNodes; int ncompleted=0; @@ -21724,7 +21729,9 @@ void MegaBackupController::removeexceeding() megaApi->setCustomNodeAttribute(childNode, "BACKST", "MISCARRIED", this); } - if (backstvalue && !strcmp(backstvalue,"COMPLETE")) + if ( (backstvalue && !strcmp(backstvalue,"COMPLETE")) + || ( childNode->getHandle() == currentHandle && currentoneOK ) //either its completed or is the current one and it went ok (it might not have backstvalue yet set + ) { ncompleted++; } @@ -21834,6 +21841,12 @@ bool MegaBackupController::getAttendPastBackups() const return attendPastBackups; } +MegaTransferList *MegaBackupController::getFailedTransfers() +{ + MegaTransferList *result = new MegaTransferListPrivate(failedTransfers.data(), int(failedTransfers.size())); + return result; +} + void MegaBackupController::setAttendPastBackups(bool value) { attendPastBackups = value; @@ -22026,9 +22039,8 @@ void MegaBackupController::clearCurrentBackupData() { this->recursive = 0; this->pendingTransfers = 0; - this->pendingTags = 0; this->pendingFolders.clear(); - for (std::list::iterator it = failedTransfers.begin(); it != failedTransfers.end(); it++) + for (std::vector::iterator it = failedTransfers.begin(); it != failedTransfers.end(); it++) { delete *it; } @@ -22168,7 +22180,7 @@ void MegaBackupController::onFolderAvailable(MegaHandle handle) client->fsaccess->local2path(&localPath, &utf8path); totalFiles++; - megaApi->startUpload(false, utf8path.c_str(), parent, (const char *)NULL, -1, folderTransferTag, NULL, false, this); + megaApi->startUpload(false, utf8path.c_str(), parent, (const char *)NULL, -1, folderTransferTag, true, NULL, false, this); } else { @@ -22213,6 +22225,7 @@ bool MegaBackupController::checkCompletion() { if(!recursive && !pendingFolders.size() && !pendingTransfers && !pendingTags) { + error e = API_OK; LOG_debug << "Folder transfer finished - " << this->getTransferredBytes() << " of " << this->getTotalBytes(); MegaNode *node = megaApi->getNodeByHandle(currentHandle); if (node) @@ -22221,24 +22234,30 @@ bool MegaBackupController::checkCompletion() { this->pendingTags++; megaApi->setCustomNodeAttribute(node, "BACKST", "INCOMPLETE", this); + e = API_EINCOMPLETE; } else if (state != BACKUP_SKIPPING) { this->pendingTags++; megaApi->setCustomNodeAttribute(node, "BACKST", "COMPLETE", this); } + else + { + e = API_EEXPIRED; + } delete node; } else { LOG_err << "Could not set backup attribute, node not found for: " << currentName; + e = API_ENOENT; } state = BACKUP_ACTIVE; - megaApi->fireOnBackupFinish(this, MegaError(API_OK)); + megaApi->fireOnBackupFinish(this, MegaError(e)); megaApi->fireOnBackupStateChanged(this); - removeexceeding(); + removeexceeding(e == API_OK); return true; } @@ -22281,7 +22300,7 @@ void MegaBackupController::abortCurrent() if (node) { this->pendingTags++; - megaApi->setCustomNodeAttribute(node, "BACKST", "ABORTED"); + megaApi->setCustomNodeAttribute(node, "BACKST", "ABORTED", this); delete node; } else @@ -22317,7 +22336,8 @@ void MegaBackupController::onRequestFinish(MegaApi *, MegaRequest *request, Mega pendingremovals--; if (!pendingremovals) { - if (!pendingTags) + assert(pendingTags>=0); + if (pendingTags <= 0) { state = BACKUP_ACTIVE; } @@ -22327,6 +22347,7 @@ void MegaBackupController::onRequestFinish(MegaApi *, MegaRequest *request, Mega else if(type == MegaRequest::TYPE_SET_ATTR_NODE) { pendingTags--; + assert(pendingTags>=0); if (!pendingTags) { @@ -22369,6 +22390,12 @@ void MegaBackupController::onTransferUpdate(MegaApi *, MegaTransfer *t) megaApi->fireOnBackupUpdate(this); } +void MegaBackupController::onTransferTemporaryError(MegaApi *, MegaTransfer *t, MegaError *e) +{ + LOG_verbose << " at MegaBackupController::onTransferTemporaryError"; + megaApi->fireOnBackupTemporaryError(this, e->getErrorCode()); +} + void MegaBackupController::onTransferFinish(MegaApi *, MegaTransfer *t, MegaError *e) { LOG_verbose << " at MegaackupController::onTransferFinish"; @@ -22556,11 +22583,10 @@ MegaBackupController::~MegaBackupController() megaApi->removeRequestListener(this); megaApi->removeTransferListener(this); - for (std::list::iterator it = failedTransfers.begin(); it != failedTransfers.end(); it++) + for (std::vector::iterator it = failedTransfers.begin(); it != failedTransfers.end(); it++) { delete *it; } - } MegaFolderDownloadController::MegaFolderDownloadController(MegaApiImpl *megaApi, MegaTransferPrivate *transfer) diff --git a/src/megaclient.cpp b/src/megaclient.cpp index 2b647d0171..e35bdcc6da 100644 --- a/src/megaclient.cpp +++ b/src/megaclient.cpp @@ -5171,13 +5171,12 @@ void MegaClient::sc_userattr() else if (ualist.size() == uavlist.size()) { // invalidate only out-of-date attributes - const string *cacheduav; for (itua = ualist.begin(), ituav = uavlist.begin(); itua != ualist.end(); itua++, ituav++) { attr_t type = User::string2attr(itua->c_str()); - cacheduav = u->getattrversion(type); + const string *cacheduav = u->getattrversion(type); if (cacheduav) { if (*cacheduav != *ituav) @@ -5190,6 +5189,11 @@ void MegaClient::sc_userattr() } #endif } + else + { + LOG_info << "User attribute already up to date"; + return; + } } else { @@ -5534,7 +5538,7 @@ void MegaClient::sc_upc(bool incoming) pcr->uts = uts; } - if (statecurrent && ou != me) + if (statecurrent && ou != me && (incoming || s != 2)) { string email; Node::copystring(&email, m); @@ -5866,6 +5870,15 @@ void MegaClient::sc_chatupdate() } } } + + if (chat->priv == PRIV_RM) + { + // clear the list of peers because API still includes peers in the + // actionpacket, but not in a fresh fetchnodes + delete userpriv; + userpriv = NULL; + } + delete chat->userpriv; // discard any existing `userpriv` chat->userpriv = userpriv; @@ -8781,7 +8794,7 @@ void MegaClient::notifynode(Node* n) void MegaClient::transfercacheadd(Transfer *transfer) { - if (tctable) + if (tctable && !transfer->skipserialization) { LOG_debug << "Caching transfer"; tctable->put(MegaClient::CACHEDTRANSFER, transfer, &tckey); @@ -9096,18 +9109,28 @@ void MegaClient::procmcf(JSON *j) // remove yourself from the list of users (only peers matter) if (userpriv) { - userpriv_vector::iterator upvit; - for (upvit = userpriv->begin(); upvit != userpriv->end(); upvit++) + if (chat->priv == PRIV_RM) { - if (upvit->first == me) + // clear the list of peers because API still includes peers in the + // actionpacket, but not in a fresh fetchnodes + delete userpriv; + userpriv = NULL; + } + else + { + userpriv_vector::iterator upvit; + for (upvit = userpriv->begin(); upvit != userpriv->end(); upvit++) { - userpriv->erase(upvit); - if (userpriv->empty()) + if (upvit->first == me) { - delete userpriv; - userpriv = NULL; + userpriv->erase(upvit); + if (userpriv->empty()) + { + delete userpriv; + userpriv = NULL; + } + break; } - break; } } } @@ -10831,9 +10854,9 @@ void MegaClient::pread(Node* n, m_off_t count, m_off_t offset, void* appdata) } // request direct read by exported handle / key -void MegaClient::pread(handle ph, SymmCipher* key, int64_t ctriv, m_off_t count, m_off_t offset, void* appdata, bool isforeign, const char *privauth, const char *pubauth) +void MegaClient::pread(handle ph, SymmCipher* key, int64_t ctriv, m_off_t count, m_off_t offset, void* appdata, bool isforeign, const char *privauth, const char *pubauth, const char *cauth) { - queueread(ph, isforeign, key, ctriv, count, offset, appdata, privauth, pubauth); + queueread(ph, isforeign, key, ctriv, count, offset, appdata, privauth, pubauth, cauth); } // since only the first six bytes of a handle are in use, we use the seventh to encode its type @@ -10850,7 +10873,7 @@ bool MegaClient::isprivatehandle(handle* hp) return ((char*)hp)[NODEHANDLE] != 0; } -void MegaClient::queueread(handle h, bool p, SymmCipher* key, int64_t ctriv, m_off_t offset, m_off_t count, void* appdata, const char* privauth, const char *pubauth) +void MegaClient::queueread(handle h, bool p, SymmCipher* key, int64_t ctriv, m_off_t offset, m_off_t count, void* appdata, const char* privauth, const char *pubauth, const char *cauth) { handledrn_map::iterator it; @@ -10861,7 +10884,7 @@ void MegaClient::queueread(handle h, bool p, SymmCipher* key, int64_t ctriv, m_o if (it == hdrns.end()) { // this handle is not being accessed yet: insert - it = hdrns.insert(hdrns.end(), pair(h, new DirectReadNode(this, h, p, key, ctriv, privauth, pubauth))); + it = hdrns.insert(hdrns.end(), pair(h, new DirectReadNode(this, h, p, key, ctriv, privauth, pubauth, cauth))); it->second->hdrn_it = it; it->second->enqueue(offset, count, reqtag, appdata); @@ -12561,7 +12584,7 @@ void MegaClient::putnodes_syncdebris_result(error, NewNode* nn) // inject file into transfer subsystem // if file's fingerprint is not valid, it will be obtained from the local file // (PUT) or the file's key (GET) -bool MegaClient::startxfer(direction_t d, File* f, bool skipdupes, bool startfirst) +bool MegaClient::startxfer(direction_t d, File* f, bool skipdupes, bool startfirst, bool donotpersist) { if (!f->transfer) { @@ -12625,7 +12648,7 @@ bool MegaClient::startxfer(direction_t d, File* f, bool skipdupes, bool startfir f->file_it = t->files.insert(t->files.end(), f); f->transfer = t; f->tag = reqtag; - if (!f->dbid) + if (!f->dbid && !donotpersist) { filecacheadd(f); } @@ -12723,6 +12746,8 @@ bool MegaClient::startxfer(direction_t d, File* f, bool skipdupes, bool startfir *(FileFingerprint*)t = *(FileFingerprint*)f; } + t->skipserialization = donotpersist; + t->lastaccesstime = m_time(); t->tag = reqtag; f->tag = reqtag; @@ -12730,7 +12755,7 @@ bool MegaClient::startxfer(direction_t d, File* f, bool skipdupes, bool startfir f->file_it = t->files.insert(t->files.end(), f); f->transfer = t; - if (!f->dbid) + if (!f->dbid && !donotpersist) { filecacheadd(f); } diff --git a/src/transfer.cpp b/src/transfer.cpp index ca3cb21ec2..fdb3d93a41 100644 --- a/src/transfer.cpp +++ b/src/transfer.cpp @@ -56,6 +56,8 @@ Transfer::Transfer(MegaClient* cclient, direction_t ctype) priority = 0; state = TRANSFERSTATE_NONE; + skipserialization = false; + faputcompletion_it = client->faputcompletion.end(); transfers_it = client->transfers[type].end(); } @@ -1038,7 +1040,7 @@ m_off_t Transfer::nextpos() return pos; } -DirectReadNode::DirectReadNode(MegaClient* cclient, handle ch, bool cp, SymmCipher* csymmcipher, int64_t cctriv, const char *privauth, const char *pubauth) +DirectReadNode::DirectReadNode(MegaClient* cclient, handle ch, bool cp, SymmCipher* csymmcipher, int64_t cctriv, const char *privauth, const char *pubauth, const char *cauth) { client = cclient; @@ -1055,6 +1057,11 @@ DirectReadNode::DirectReadNode(MegaClient* cclient, handle ch, bool cp, SymmCiph publicauth = pubauth; } + if (cauth) + { + chatauth = cauth; + } + symmcipher = *csymmcipher; ctriv = cctriv; diff --git a/src/user.cpp b/src/user.cpp index 8cd3220fe8..abcfb2ca7d 100644 --- a/src/user.cpp +++ b/src/user.cpp @@ -412,6 +412,10 @@ string User::attr2string(attr_t type) attrname = "^!usl"; break; + case ATTR_GEOLOCATION: + attrname = "*!geo"; + break; + case ATTR_UNKNOWN: // empty string break; } @@ -419,6 +423,113 @@ string User::attr2string(attr_t type) return attrname; } +string User::attr2longname(attr_t type) +{ + string longname; + + switch(type) + { + case ATTR_AVATAR: + longname = "AVATAR"; + break; + + case ATTR_FIRSTNAME: + longname = "FIRSTNAME"; + break; + + case ATTR_LASTNAME: + longname = "LASTNAME"; + break; + + case ATTR_AUTHRING: + longname = "AUTHRING"; + break; + + case ATTR_LAST_INT: + longname = "LAST_INT"; + break; + + case ATTR_ED25519_PUBK: + longname = "ED25519_PUBK"; + break; + + case ATTR_CU25519_PUBK: + longname = "CU25519_PUBK"; + break; + + case ATTR_SIG_RSA_PUBK: + longname = "SIG_RSA_PUBK"; + break; + + case ATTR_SIG_CU255_PUBK: + longname = "SIG_CU255_PUBK"; + break; + + case ATTR_KEYRING: + longname = "KEYRING"; + break; + + case ATTR_COUNTRY: + longname = "COUNTRY"; + break; + + case ATTR_BIRTHDAY: + longname = "BIRTHDAY"; + break; + + case ATTR_BIRTHMONTH: + longname = "BIRTHMONTH"; + break; + + case ATTR_BIRTHYEAR: + longname = "BIRTHYEAR"; + break; + + case ATTR_LANGUAGE: + longname = "LANGUAGE"; + break; + + case ATTR_PWD_REMINDER: + longname = "PWD_REMINDER"; + break; + + case ATTR_DISABLE_VERSIONS: + longname = "DISABLE_VERSIONS"; + break; + + case ATTR_CONTACT_LINK_VERIFICATION: + longname = "CONTACT_LINK_VERIFICATION"; + break; + + case ATTR_RICH_PREVIEWS: + longname = "RICH_PREVIEWS"; + break; + + case ATTR_LAST_PSA: + longname = "LAST_PSA"; + break; + + case ATTR_RUBBISH_TIME: + longname = "RUBBISH_TIME"; + break; + + case ATTR_STORAGE_STATE: + longname = "STORAGE_STATE"; + break; + + case ATTR_GEOLOCATION: + longname = "GEOLOCATION"; + break; + + case ATTR_UNKNOWN: + longname = ""; // empty string + break; + } + + return longname; +} + + attr_t User::string2attr(const char* name) { if (!strcmp(name, "*keyring")) @@ -509,6 +620,10 @@ attr_t User::string2attr(const char* name) { return ATTR_STORAGE_STATE; } + else if(!strcmp(name, "*!geo")) + { + return ATTR_GEOLOCATION; + } else { return ATTR_UNKNOWN; // attribute not recognized @@ -532,6 +647,7 @@ bool User::needversioning(attr_t at) case ATTR_RICH_PREVIEWS: case ATTR_LAST_PSA: case ATTR_RUBBISH_TIME: + case ATTR_GEOLOCATION: return 0; case ATTR_AUTHRING: @@ -558,6 +674,7 @@ char User::scope(attr_t at) case ATTR_AUTHRING: case ATTR_LAST_INT: case ATTR_RICH_PREVIEWS: + case ATTR_GEOLOCATION: return '*'; case ATTR_AVATAR: @@ -946,6 +1063,10 @@ bool User::setChanged(attr_t at) changed.storageState = true; break; + case ATTR_GEOLOCATION: + changed.geolocation = true; + break; + default: return false; } diff --git a/src/useralerts.cpp b/src/useralerts.cpp index 53dcbb97de..e3aca16d3b 100644 --- a/src/useralerts.cpp +++ b/src/useralerts.cpp @@ -594,25 +594,31 @@ UserAlert::PaymentReminder::PaymentReminder(UserAlertRaw& un, unsigned int id) : Base(un, id) { expiryTime = un.getint64(MAKENAMEID2('t', 's'), timestamp); - relevant = expiryTime > timestamp && expiryTime > m_time(); + relevant = true; // relevant until we see a subsequent payment } UserAlert::PaymentReminder::PaymentReminder(m_time_t expiryts, unsigned int id) : Base(type_pses, UNDEF, "", m_time(), id) { expiryTime = expiryts; - relevant = expiryTime > timestamp; + relevant = true; // relevant until we see a subsequent payment } void UserAlert::PaymentReminder::text(string& header, string& title, MegaClient* mc) { updateEmail(mc); m_time_t now = m_time(); - int days = expiryTime > now ? int((expiryTime - now) / 86400) : 0; + int days = int((expiryTime - now) / 86400); ostringstream s; - s << "Your PRO membership plan will expire in " << days << (days == 1 ? " day." : " days."); // 8596, 8597 - + if (expiryTime < now) + { + s << "Your PRO membership plan expired " << -days << (days == -1 ? " day" : " days") << " ago"; + } + else + { + s << "Your PRO membership plan will expire in " << days << (days == 1 ? " day." : " days."); // 8596, 8597 + } title = s.str(); header = "PRO membership plan expiring soon"; // 8598 } @@ -844,6 +850,22 @@ void UserAlerts::add(UserAlert::Base* unb) } } + if (!alerts.empty() && unb->type == UserAlert::type_psts && static_cast(unb)->success) + { + // if a successful payment is made then hide/remove any reminders received + for (Alerts::iterator i = alerts.begin(); i != alerts.end(); ++i) + { + if ((*i)->type == UserAlert::type_pses && (*i)->relevant) + { + (*i)->relevant = false; + if (catchupdone) + { + useralertnotify.push_back(*i); + } + } + } + } + unb->updateEmail(&mc); alerts.push_back(unb); LOG_debug << "Added user alert, type " << alerts.back()->type << " ts " << alerts.back()->timestamp; @@ -864,7 +886,7 @@ void UserAlerts::startprovisional() void UserAlerts::evalprovisional(handle originatinguser) { provisionalmode = false; - for (int i = 0; i < provisionals.size(); ++i) + for (unsigned i = 0; i < provisionals.size(); ++i) { if (provisionals[i]->checkprovisional(originatinguser, &mc)) { diff --git a/src/utils.cpp b/src/utils.cpp index 6732e61254..c14865c1d9 100644 --- a/src/utils.cpp +++ b/src/utils.cpp @@ -201,6 +201,12 @@ TextChat* TextChat::unserialize(class MegaClient *client, string *d) userpriv->push_back(userpriv_pair(uh, priv)); } + + if (priv == PRIV_RM) // clear peerlist if removed + { + delete userpriv; + userpriv = NULL; + } } if (ptr + sizeof(bool) + sizeof(unsigned short) > end) diff --git a/src/win32/fs.cpp b/src/win32/fs.cpp index bc4cb3a9d1..6f971b63fc 100644 --- a/src/win32/fs.cpp +++ b/src/win32/fs.cpp @@ -805,7 +805,7 @@ bool WinFileSystemAccess::copylocal(string* oldname, string* newname, m_time_t) newname->append("", 1); #ifdef WINDOWS_PHONE - bool r = !!CopyFile2((LPCWSTR)oldname->data(), (LPCWSTR)newname->data(), NULL); + bool r = SUCCEEDED(CopyFile2((LPCWSTR)oldname->data(), (LPCWSTR)newname->data(), NULL)); #else bool r = !!CopyFileW((LPCWSTR)oldname->data(), (LPCWSTR)newname->data(), FALSE); #endif @@ -1148,7 +1148,14 @@ bool WinFileSystemAccess::expanselocalpath(string *path, string *absolutepath) if (memcmp(absolutepath->data(), L"\\\\?\\", 8)) { - absolutepath->insert(0, (const char *)(const wchar_t*)L"\\\\?\\", 8); + if (!memcmp(absolutepath->data(), L"\\\\", 4)) //network location + { + absolutepath->insert(0, (const char *)(const wchar_t*)L"\\\\?\\UNC\\", 16); + } + else + { + absolutepath->insert(0, (const char *)(const wchar_t*)L"\\\\?\\", 8); + } } absolutepath->resize(absolutepath->size() - 2); return true; @@ -1272,11 +1279,13 @@ void WinDirNotify::process(DWORD dwBytes) #ifndef WINDOWS_PHONE if (!dwBytes) { +#ifdef ENABLE_SYNC LOG_err << "Empty filesystem notification: " << (localrootnode ? localrootnode->name.c_str() : "NULL") << " errors: " << error; error++; readchanges(); notify(DIREVENTS, localrootnode, NULL, 0); +#endif } else { @@ -1314,9 +1323,14 @@ void WinDirNotify::process(DWORD dwBytes) (char*)path.data(), int(path.size() + 1), NULL, NULL)); +#ifdef ENABLE_SYNC + LOG_debug << "Filesystem notification. Root: " << (localrootnode ? localrootnode->name.c_str() : "NULL") << " Path: " << path; +#endif } +#ifdef ENABLE_SYNC notify(DIREVENTS, localrootnode, (char*)fni->FileName, fni->FileNameLength); +#endif } else if (SimpleLogger::logCurrentLevel >= logDebug) { @@ -1328,7 +1342,9 @@ void WinDirNotify::process(DWORD dwBytes) (char*)path.data(), int(path.size() + 1), NULL, NULL)); +#ifdef ENABLE_SYNC LOG_debug << "Skipped filesystem notification. Root: " << (localrootnode ? localrootnode->name.c_str() : "NULL") << " Path: " << path; +#endif } diff --git a/tests/synctests.cpp b/tests/synctests.cpp index aa5ca3aa42..73f83bcee8 100644 --- a/tests/synctests.cpp +++ b/tests/synctests.cpp @@ -808,7 +808,7 @@ struct StandardClient : public MegaApp multimap ms; multimap ns; for (auto& m : mn->kids) ms.emplace(m->name, m.get()); - for (auto& n : n->children) ns.emplace(n->displayname(), n); + for (auto& n2 : n->children) ns.emplace(n2->displayname(), n2); int matched = 0; vector matchedlist; @@ -911,8 +911,14 @@ struct StandardClient : public MegaApp multimap ms; multimap ns; - for (auto& m : mn->kids) ms.emplace(m->name, m.get()); - for (auto& n : n->children) if (!n.second->deleted) ns.emplace(n.second->name, n.second); // todo: should LocalNodes marked as deleted actually have been removed by now? + for (auto& m : mn->kids) + { + ms.emplace(m->name, m.get()); + } + for (auto& n2 : n->children) + { + if (!n2.second->deleted) ns.emplace(n2.second->name, n2.second); // todo: should LocalNodes marked as deleted actually have been removed by now? + } int matched = 0; vector matchedlist; @@ -1482,6 +1488,35 @@ bool buildLocalFolders(fs::path targetfolder, const string& prefix, int n, int r return true; } +#ifdef __linux__ +bool createSpecialFiles(fs::path targetfolder, const string& prefix, int n = 1) +{ + fs::path p = targetfolder; + for (int i = 0; i < n; ++i) + { + string filename = "file" + to_string(i) + "_" + prefix; + fs::path fp = p / fs::u8path(filename); + + int fdtmp = openat(AT_FDCWD, p.c_str(), O_RDWR|O_CLOEXEC|O_TMPFILE, 0600); + write(fdtmp, filename.data(), filename.size()); + + stringstream fdproc; + fdproc << "/proc/self/fd/"; + fdproc << fdtmp; + + int r = linkat(AT_FDCWD, fdproc.str().c_str() , AT_FDCWD, fp.c_str(), AT_SYMLINK_FOLLOW); + if (r) + { + cerr << " errno =" << errno << endl; + return false; + } + close(fdtmp); + } + return true; +} +#endif + + GTEST_TEST(BasicSync, DelRemoteFolder) { // delete a remote folder and confirm the client sending the request and another also synced both correctly update the disk @@ -1749,7 +1784,7 @@ GTEST_TEST(BasicSync, MAX_NEWNODES2) // make new folders in the local filesystem and see if we catch up in A1 and A2 (adder and observer syncs) assert(MegaClient::MAX_NEWNODES < 3000); - ASSERT_TRUE(buildLocalFolders(clientA1.syncSet[1].localpath, "g", 3000, 1, 0)); + ASSERT_TRUE(buildLocalFolders(clientA1.syncSet[1].localpath, "g", 3000, 1, 0)); // let them catch up waitonsyncs(30s, &clientA1, &clientA2); @@ -1936,7 +1971,7 @@ GTEST_TEST(BasicSync, RemoveLocalNodeBeforeSessionResume) ASSERT_TRUE(pclientA1->confirmModel_mainthread(model.findnode("f"), 1)); } -/* not expected to work yet +/* not expected to work yet GTEST_TEST(BasicSync, RemoteFolderCreationRaceSamename) { // confirm change is synced to remote, and also seen and applied in a second client that syncs the same folder @@ -2152,7 +2187,7 @@ GTEST_TEST(CmdChecks, RRAttributeAfterMoveNode) // remove remote folder via A2 future p1 = pclientA1->thread_do([](StandardClient& sc, promise& pb) - { + { sc.movenodetotrash("f", pb); }); ASSERT_TRUE(waitonresults(&p1)); @@ -2178,13 +2213,98 @@ GTEST_TEST(CmdChecks, RRAttributeAfterMoveNode) WaitMillisec(3000); // allow for attribute delivery too - // check it's back and the rr attribute is gone + // check it's back and the rr attribute is gone f = pclientA1->drillchildnodebyname(pclientA1->gettestbasenode(), "f"); ASSERT_TRUE(f != nullptr); ASSERT_EQ(f->attrs.map[rrname], string()); } +#ifdef __linux__ +GTEST_TEST(BasicSync, SpecialCreateFile) +{ + // confirm change is synced to remote, and also seen and applied in a second client that syncs the same folder + fs::path localtestroot = makeNewTestRoot(LOCAL_TEST_FOLDER); + StandardClient clientA1(localtestroot, "clientA1"); // user 1 client 1 + StandardClient clientA2(localtestroot, "clientA2"); // user 1 client 2 + + ASSERT_TRUE(clientA1.login_reset_makeremotenodes("MEGAAUTOTESTUSER1", "MEGAAUTOTESTPWD1", "f", 2, 2)); + ASSERT_TRUE(clientA2.login_fetchnodes("MEGAAUTOTESTUSER1", "MEGAAUTOTESTPWD1")); + ASSERT_EQ(clientA1.basefolderhandle, clientA2.basefolderhandle); + + Model model; + model.root->addkid(model.buildModelSubdirs("f", 2, 2, 0)); + + // set up sync for A1, it should build matching local folders + ASSERT_TRUE(clientA1.setupSync_mainthread("sync1", "f", 1)); + ASSERT_TRUE(clientA2.setupSync_mainthread("sync2", "f", 2)); + + waitonsyncs(4s, &clientA1, &clientA2); + clientA1.logcb = clientA2.logcb = true; + // check everything matches (model has expected state of remote and local) + ASSERT_TRUE(clientA1.confirmModel_mainthread(model.findnode("f"), 1)); + ASSERT_TRUE(clientA2.confirmModel_mainthread(model.findnode("f"), 2)); + + // make new folders (and files) in the local filesystem and see if we catch up in A1 and A2 (adder and observer syncs) + ASSERT_TRUE(createSpecialFiles(clientA1.syncSet[1].localpath / "f_0", "newkid", 2)); + + for (int i = 0; i < 2; ++i) + { + string filename = "file" + to_string(i) + "_" + "newkid"; + model.findnode("f/f_0")->addkid(model.makeModelSubfile(filename)); + } + + // let them catch up + waitonsyncs(20s, &clientA1, &clientA2); + + // check everything matches (model has expected state of remote and local) + ASSERT_TRUE(clientA1.confirmModel_mainthread(model.findnode("f"), 1)); + model.ensureLocalDebrisTmpLock("f"); // since we downloaded files + ASSERT_TRUE(clientA2.confirmModel_mainthread(model.findnode("f"), 2)); +} +#endif + +GTEST_TEST(BasicSync, moveAndDeleteLocalFile) +{ + // confirm change is synced to remote, and also seen and applied in a second client that syncs the same folder + fs::path localtestroot = makeNewTestRoot(LOCAL_TEST_FOLDER); + StandardClient clientA1(localtestroot, "clientA1"); // user 1 client 1 + StandardClient clientA2(localtestroot, "clientA2"); // user 1 client 2 + + ASSERT_TRUE(clientA1.login_reset_makeremotenodes("MEGAAUTOTESTUSER1", "MEGAAUTOTESTPWD1", "f", 1, 1)); + ASSERT_TRUE(clientA2.login_fetchnodes("MEGAAUTOTESTUSER1", "MEGAAUTOTESTPWD1")); + ASSERT_EQ(clientA1.basefolderhandle, clientA2.basefolderhandle); + + Model model; + model.root->addkid(model.buildModelSubdirs("f", 1, 1, 0)); + + // set up sync for A1, it should build matching local folders + ASSERT_TRUE(clientA1.setupSync_mainthread("sync1", "f", 1)); + ASSERT_TRUE(clientA2.setupSync_mainthread("sync2", "f", 2)); + + waitonsyncs(4s, &clientA1, &clientA2); + clientA1.logcb = clientA2.logcb = true; + // check everything matches (model has expected state of remote and local) + ASSERT_TRUE(clientA1.confirmModel_mainthread(model.findnode("f"), 1)); + ASSERT_TRUE(clientA2.confirmModel_mainthread(model.findnode("f"), 2)); + + + // move something in the local filesystem and see if we catch up in A1 and A2 (deleter and observer syncs) + error_code rename_error; + fs::rename(clientA1.syncSet[1].localpath / "f_0", clientA1.syncSet[1].localpath / "renamed", rename_error); + ASSERT_TRUE(!rename_error) << rename_error; + fs::remove(clientA1.syncSet[1].localpath / "renamed"); + + // let them catch up + waitonsyncs(20s, &clientA1, &clientA2); + + // check everything matches (model has expected state of remote and local) + ASSERT_TRUE(model.movetosynctrash("f/f_0", "f")); + ASSERT_TRUE(clientA2.confirmModel_mainthread(model.findnode("f"), 2)); + ASSERT_TRUE(model.removesynctrash("f")); + ASSERT_TRUE(clientA1.confirmModel_mainthread(model.findnode("f"), 1)); +} + class MegaCLILogger : public ::mega::Logger { public: virtual void log(const char *time, int loglevel, const char *source, const char *message)