diff --git a/.circleci/config.yml b/.circleci/config.yml index 8f975897..7b3738d1 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -3,8 +3,8 @@ version: 2.1 executors: macos_executor: macos: - xcode: "14.2.0" - resource_class: macos.x86.medium.gen2 + xcode: "15.3.0" + resource_class: macos.m1.medium.gen1 commands: setup: @@ -60,12 +60,14 @@ commands: steps: - checkout - setup + - setup-certificates - run: name: Unit Tests command: bundle exec fastlane unit_tests test_plan:<< parameters.test_plan >> - store_scan_artifacts - store_test_output - store_scan_results + - cleanup-signing integration_tests: parameters: @@ -133,17 +135,35 @@ commands: root: ~/Desktop paths: - SizeImpact.md + + setup-certificates: + steps: + - run: + name: Install Apple Certificate and Provisioning Profile + command: | + chmod +x ./scripts/certificate_setup.sh + ./scripts/certificate_setup.sh setup "$CIRCLE_JOB" + + cleanup-signing: + steps: + - run: + name: Clean Up Keychain and Provisioning Profile + command: | + chmod +x ./scripts/certificate_setup.sh + ./scripts/certificate_setup.sh cleanup "$CIRCLE_JOB" release: steps: - checkout - setup + - setup-certificates - attach_workspace: at: ~/Desktop - configure_gcloud_app_distribution_service - run: name: "Release SDK" command: bundle exec fastlane release + - cleanup-signing distribute_debug_sample_app: parameters: @@ -163,6 +183,7 @@ jobs: steps: - checkout - setup + - setup-certificates - configure_gcloud_app_distribution_service - distribute_debug_sample_app: env: "DEV" @@ -173,6 +194,7 @@ jobs: - distribute_debug_sample_app: env: "PROD" base_url: $PROD_URL + - cleanup-signing Unit Tests and Lint: executor: macos_executor @@ -183,15 +205,23 @@ jobs: Integration Tests Single Device: executor: macos_executor steps: + - checkout + - setup + - setup-certificates - integration_tests: test_plan: IntegrationSuite + - cleanup-signing Integration Tests All Devices: executor: macos_executor steps: + - checkout + - setup + - setup-certificates - integration_tests: test_plan: IntegrationSuite ftl_devices: all + - cleanup-signing TwilioVerifyDemo Unit Tests: executor: macos_executor @@ -209,7 +239,11 @@ jobs: Size report: executor: macos_executor steps: + - checkout + - setup + - setup-certificates - build_app_sizer + - cleanup-signing Release SDK: executor: macos_executor steps: @@ -218,31 +252,45 @@ jobs: workflows: build_and_test: jobs: - - Unit Tests and Lint + - Unit Tests and Lint: + context: + - verify-push-ios - Integration Tests Single Device: + context: + - verify-push-ios requires: - Unit Tests and Lint - Integration Tests All Devices: + context: + - verify-push-ios requires: - Integration Tests Single Device - Build TwilioVerify: + context: + - verify-push-ios requires: - Integration Tests Single Device - Unit Tests and Lint - Size report: + context: + - verify-push-ios requires: - Build TwilioVerify - Distribute debug sample app: + context: + - verify-push-ios requires: - - Build TwilioVerify + - Build TwilioVerify filters: branches: only: - /feature.*/ - /release.*/ - /hotfix.*/ - - dev + - dev - Release SDK: + context: + - verify-push-ios requires: - Size report filters: diff --git a/AppSizer/AppSizer.xcodeproj/project.pbxproj b/AppSizer/AppSizer.xcodeproj/project.pbxproj index 9cec9f2c..4fec9b91 100644 --- a/AppSizer/AppSizer.xcodeproj/project.pbxproj +++ b/AppSizer/AppSizer.xcodeproj/project.pbxproj @@ -3,7 +3,7 @@ archiveVersion = 1; classes = { }; - objectVersion = 52; + objectVersion = 54; objects = { /* Begin PBXBuildFile section */ @@ -263,7 +263,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 11.0; + IPHONEOS_DEPLOYMENT_TARGET = 12.0; MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; MTL_FAST_MATH = YES; ONLY_ACTIVE_ARCH = YES; @@ -318,7 +318,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 11.0; + IPHONEOS_DEPLOYMENT_TARGET = 12.0; MTL_ENABLE_DEBUG_INFO = NO; MTL_FAST_MATH = YES; SDKROOT = iphoneos; diff --git a/CHANGELOG.md b/CHANGELOG.md index b5bfce44..f7b533cd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,28 @@ +# 3.0.0 (2025-04-30) + +### Features +- Allow factors migration by providing the flag allowIphoneMigration, for enabling users to migrate their factors to another iPhone or restore them during backup processes. (#218) ([1dda013](https://github.com/twilio/twilio-verify-ios/commit/1dda0132c3047603bd85765ae5adbb5f28bbd552)) +- Support new Xcode and iOS versions (#226) ([9abf25e](https://github.com/twilio/twilio-verify-ios/commit/9abf25e5157160bd52245e71280dbd1ae15ab3e2)) + +### Building system +- Update CI config (#211) ([2e19a0c](https://github.com/twilio/twilio-verify-ios/commit/2e19a0c2642195c673a9a3333e6d5f631a19e9b1)) +- Xcode 14 support ([ae1a210](https://github.com/twilio/twilio-verify-ios/commit/ae1a210ea45f3696272af37ef15197f4eb2e7d68)) +- Fix vulnerabilities (#220) ([7bd8715](https://github.com/twilio/twilio-verify-ios/commit/7bd8715d886b5302b307bc92ec4b21b567e2e7d1)) +- Xcode 15 support (#221) ([9ef308c](https://github.com/twilio/twilio-verify-ios/commit/9ef308c80687ca7c090b335231edc1db614914e4)) +- Add Privacy Manifest (#223) ([0f0c2f8](https://github.com/twilio/twilio-verify-ios/commit/0f0c2f8b5980e9f91afd3a957104823c9c3c4689)) +- Fix release process ([9b9ea30](https://github.com/twilio/twilio-verify-ios/commit/9b9ea306f1f8d81a9d6336598d0d6ac3af075398)) +- Fix Github author for CI ([86d43dc](https://github.com/twilio/twilio-verify-ios/commit/86d43dcf61d392147f1316ec9e76291846e4382a)) +- fix release process. ([643c340](https://github.com/twilio/twilio-verify-ios/commit/643c340feb5ff5f66e94298ac08896cff2ff8529)) + +### BREAKING CHANGES +- Dropped support for iOS 10 ([ae1a210](https://github.com/twilio/twilio-verify-ios/commit/ae1a210ea45f3696272af37ef15197f4eb2e7d68)) +- Dropped support for iOS 11 ([9ef308c](https://github.com/twilio/twilio-verify-ios/commit/9ef308c80687ca7c090b335231edc1db614914e4)) + +Architecture | Compressed Size | Uncompressed Size +------------ | --------------- | ----------------- +arm64 | 0.2 MB | 0.5 MB + + # 2.2.2 (2022-07-13) ### Bug fixes diff --git a/Gemfile b/Gemfile index 85d47f26..5cdc2787 100644 --- a/Gemfile +++ b/Gemfile @@ -2,12 +2,13 @@ source 'https://rubygems.org' gem 'cocoapods', '= 1.11.3' gem 'xcpretty' -gem 'fastlane', '>= 2.178.0' +gem 'rb-readline' +gem 'fastlane', '>= 2.216.0' gem 'filesize' gem 'plist' gem 'jazzy', '>= 0.14.2' gem 'danger', '>= 8.2.3' gem 'danger-slather', '>= 0.0.6' -gem 'danger-swiftlint', '>= 0.24.4' +gem 'danger-swiftlint', '>= 0.36.0' plugins_path = File.join(File.dirname(__FILE__), 'fastlane', 'Pluginfile') eval_gemfile(plugins_path) if File.exist?(plugins_path) diff --git a/Gemfile.lock b/Gemfile.lock index e15661df..74c60e81 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -13,38 +13,41 @@ GIT GEM remote: https://rubygems.org/ specs: - CFPropertyList (3.0.6) + CFPropertyList (3.0.7) + base64 + nkf rexml - activesupport (6.1.7.3) + activesupport (6.1.7.7) concurrent-ruby (~> 1.0, >= 1.0.2) i18n (>= 1.6, < 2) minitest (>= 5.1) tzinfo (~> 2.0) zeitwerk (~> 2.3) - addressable (2.8.4) - public_suffix (>= 2.0.2, < 6.0) + addressable (2.8.7) + public_suffix (>= 2.0.2, < 7.0) algoliasearch (1.27.5) httpclient (~> 2.8, >= 2.8.3) json (>= 1.5.1) - artifactory (3.0.15) + artifactory (3.0.17) atomos (0.1.3) - aws-eventstream (1.2.0) - aws-partitions (1.761.0) - aws-sdk-core (3.172.0) - aws-eventstream (~> 1, >= 1.0.2) + aws-eventstream (1.3.0) + aws-partitions (1.924.0) + aws-sdk-core (3.194.1) + aws-eventstream (~> 1, >= 1.3.0) aws-partitions (~> 1, >= 1.651.0) - aws-sigv4 (~> 1.5) + aws-sigv4 (~> 1.8) jmespath (~> 1, >= 1.6.1) - aws-sdk-kms (1.64.0) - aws-sdk-core (~> 3, >= 3.165.0) + aws-sdk-kms (1.80.0) + aws-sdk-core (~> 3, >= 3.193.0) aws-sigv4 (~> 1.1) - aws-sdk-s3 (1.122.0) - aws-sdk-core (~> 3, >= 3.165.0) + aws-sdk-s3 (1.149.0) + aws-sdk-core (~> 3, >= 3.194.0) aws-sdk-kms (~> 1) - aws-sigv4 (~> 1.4) - aws-sigv4 (1.5.2) + aws-sigv4 (~> 1.8) + aws-sigv4 (1.8.0) aws-eventstream (~> 1, >= 1.0.2) babosa (1.0.4) + base64 (0.2.0) claide (1.1.0) claide-plugins (0.9.2) cork @@ -92,43 +95,42 @@ GEM colored2 (3.1.2) commander (4.6.0) highline (~> 2.0.0) - concurrent-ruby (1.2.2) + concurrent-ruby (1.2.3) cork (0.3.0) colored2 (~> 3.1) - danger (9.3.0) + danger (9.4.3) claide (~> 1.0) claide-plugins (>= 0.9.2) colored2 (~> 3.1) cork (~> 0.1) faraday (>= 0.9.0, < 3.0) faraday-http-cache (~> 2.0) - git (~> 1.13.0) + git (~> 1.13) kramdown (~> 2.3) kramdown-parser-gfm (~> 1.0) no_proxy_fix - octokit (~> 5.0) + octokit (>= 4.0) terminal-table (>= 1, < 4) danger-plugin-api (1.0.0) danger (> 2.0) danger-slather (0.0.6) danger-plugin-api (~> 1.0) slather (~> 2.3) - danger-swiftlint (0.30.2) + danger-swiftlint (0.37.0) danger rake (> 10) - thor (~> 0.19) + thor (~> 1.0.0) declarative (0.0.20) - digest-crc (0.6.4) + digest-crc (0.7.0) rake (>= 12.0.0, < 14.0.0) - domain_name (0.5.20190701) - unf (>= 0.0.5, < 1.0.0) + domain_name (0.6.20240107) dotenv (2.8.1) emoji_regex (3.2.3) escape (0.0.4) - ethon (0.15.0) + ethon (0.16.0) ffi (>= 1.15.0) - excon (0.99.0) - faraday (1.10.3) + excon (0.110.0) + faraday (1.10.4) faraday-em_http (~> 1.0) faraday-em_synchrony (~> 1.0) faraday-excon (~> 1.1) @@ -146,27 +148,27 @@ GEM faraday-em_http (1.0.0) faraday-em_synchrony (1.0.0) faraday-excon (1.1.0) - faraday-http-cache (2.5.0) + faraday-http-cache (2.5.1) faraday (>= 0.8) faraday-httpclient (1.0.1) - faraday-multipart (1.0.4) - multipart-post (~> 2) - faraday-net_http (1.0.1) + faraday-multipart (1.1.0) + multipart-post (~> 2.0) + faraday-net_http (1.0.2) faraday-net_http_persistent (1.2.0) faraday-patron (1.0.0) faraday-rack (1.0.0) faraday-retry (1.0.3) faraday_middleware (1.2.0) faraday (~> 1.0) - fastimage (2.2.6) - fastlane (2.212.2) + fastimage (2.3.1) + fastlane (2.220.0) CFPropertyList (>= 2.3, < 4.0.0) addressable (>= 2.8, < 3.0.0) artifactory (~> 3.0) aws-sdk-s3 (~> 1.0) babosa (>= 1.0.3, < 2.0.0) bundler (>= 1.12.0, < 3.0.0) - colored + colored (~> 1.2) commander (~> 4.6) dotenv (>= 2.1.1, < 3.0.0) emoji_regex (>= 0.1, < 4.0) @@ -178,40 +180,44 @@ GEM gh_inspector (>= 1.1.2, < 2.0.0) google-apis-androidpublisher_v3 (~> 0.3) google-apis-playcustomapp_v1 (~> 0.1) + google-cloud-env (>= 1.6.0, < 2.0.0) google-cloud-storage (~> 1.31) highline (~> 2.0) + http-cookie (~> 1.0.5) json (< 3.0.0) jwt (>= 2.1.0, < 3) mini_magick (>= 4.9.4, < 5.0.0) - multipart-post (~> 2.0.0) + multipart-post (>= 2.0.0, < 3.0.0) naturally (~> 2.2) - optparse (~> 0.1.1) + optparse (>= 0.1.1, < 1.0.0) plist (>= 3.1.0, < 4.0.0) rubyzip (>= 2.0.0, < 3.0.0) - security (= 0.1.3) + security (= 0.1.5) simctl (~> 1.6.3) terminal-notifier (>= 2.0.0, < 3.0.0) - terminal-table (>= 1.4.5, < 2.0.0) + terminal-table (~> 3) tty-screen (>= 0.6.3, < 1.0.0) tty-spinner (>= 0.8.0, < 1.0.0) word_wrap (~> 1.0.0) xcodeproj (>= 1.13.0, < 2.0.0) xcpretty (~> 0.3.0) - xcpretty-travis-formatter (>= 0.0.3) + xcpretty-travis-formatter (>= 0.0.3, < 2.0.0) fastlane-plugin-create_xcframework (1.1.2) - fastlane-plugin-firebase_app_distribution (0.3.4) + fastlane-plugin-firebase_app_distribution (0.10.1) + google-apis-firebaseappdistribution_v1 (~> 0.3.0) + google-apis-firebaseappdistribution_v1alpha (~> 0.2.0) fastlane-plugin-semantic_convention_release (1.0.6) - ffi (1.15.5) + ffi (1.16.3) filesize (0.2.0) fourflusher (2.3.1) fuzzy_match (2.0.4) gh_inspector (1.1.3) - git (1.13.2) + git (1.19.1) addressable (~> 2.8) rchardet (~> 1.8) - google-apis-androidpublisher_v3 (0.41.0) + google-apis-androidpublisher_v3 (0.54.0) google-apis-core (>= 0.11.0, < 2.a) - google-apis-core (0.11.0) + google-apis-core (0.11.3) addressable (~> 2.5, >= 2.5.1) googleauth (>= 0.16.2, < 2.a) httpclient (>= 2.8.1, < 3.a) @@ -219,104 +225,110 @@ GEM representable (~> 3.0) retriable (>= 2.0, < 4.a) rexml - webrick + google-apis-firebaseappdistribution_v1 (0.3.0) + google-apis-core (>= 0.11.0, < 2.a) + google-apis-firebaseappdistribution_v1alpha (0.2.0) + google-apis-core (>= 0.11.0, < 2.a) google-apis-iamcredentials_v1 (0.17.0) google-apis-core (>= 0.11.0, < 2.a) google-apis-playcustomapp_v1 (0.13.0) google-apis-core (>= 0.11.0, < 2.a) - google-apis-storage_v1 (0.19.0) - google-apis-core (>= 0.9.0, < 2.a) - google-cloud-core (1.6.0) - google-cloud-env (~> 1.0) + google-apis-storage_v1 (0.31.0) + google-apis-core (>= 0.11.0, < 2.a) + google-cloud-core (1.8.0) + google-cloud-env (>= 1.0, < 3.a) google-cloud-errors (~> 1.0) google-cloud-env (1.6.0) faraday (>= 0.17.3, < 3.0) - google-cloud-errors (1.3.1) - google-cloud-storage (1.44.0) + google-cloud-errors (1.5.0) + google-cloud-storage (1.47.0) addressable (~> 2.8) digest-crc (~> 0.4) google-apis-iamcredentials_v1 (~> 0.1) - google-apis-storage_v1 (~> 0.19.0) + google-apis-storage_v1 (~> 0.31.0) google-cloud-core (~> 1.6) googleauth (>= 0.16.2, < 2.a) mini_mime (~> 1.0) - googleauth (1.5.2) + googleauth (1.8.1) faraday (>= 0.17.3, < 3.a) jwt (>= 1.4, < 3.0) - memoist (~> 0.16) multi_json (~> 1.11) os (>= 0.9, < 2.0) signet (>= 0.16, < 2.a) highline (2.0.3) http-cookie (1.0.5) domain_name (~> 0.5) - httpclient (2.8.3) - i18n (1.13.0) + httpclient (2.9.0) + mutex_m + i18n (1.14.4) concurrent-ruby (~> 1.0) - jazzy (0.14.2) + jazzy (0.14.4) cocoapods (~> 1.5) mustache (~> 1.1) open4 (~> 1.3) redcarpet (~> 3.4) rexml (~> 3.2) - rouge (>= 2.0.6, < 4.0) + rouge (>= 2.0.6, < 5.0) sassc (~> 2.1) sqlite3 (~> 1.3) xcinvoke (~> 0.3.0) jmespath (1.6.2) - json (2.6.3) - jwt (2.7.0) + json (2.7.2) + jwt (2.10.1) + base64 kramdown (2.4.0) rexml kramdown-parser-gfm (1.1.0) kramdown (~> 2.0) liferaft (0.0.6) - memoist (0.16.2) mini_magick (4.12.0) - mini_mime (1.1.2) - mini_portile2 (2.8.1) - minitest (5.18.0) + mini_mime (1.1.5) + minitest (5.22.3) molinillo (0.8.0) multi_json (1.15.0) - multipart-post (2.0.0) + multipart-post (2.4.1) mustache (1.1.1) + mutex_m (0.3.0) nanaimo (0.3.0) nap (1.1.0) naturally (2.2.1) netrc (0.11.0) + nkf (0.2.0) no_proxy_fix (0.1.2) - nokogiri (1.13.10) - mini_portile2 (~> 2.8.0) + nokogiri (1.16.4-arm64-darwin) racc (~> 1.4) - octokit (5.6.1) + octokit (8.1.0) + base64 faraday (>= 1, < 3) sawyer (~> 0.9) open4 (1.3.4) - optparse (0.1.1) + optparse (0.5.0) os (1.1.4) - plist (3.7.0) + plist (3.7.2) public_suffix (4.0.7) - racc (1.6.2) - rake (13.0.6) + racc (1.7.3) + rake (13.2.1) + rb-readline (0.5.5) rchardet (1.8.0) - redcarpet (3.5.1) + redcarpet (3.6.0) representable (3.2.0) declarative (< 0.1.0) trailblazer-option (>= 0.1.1, < 0.2.0) uber (< 0.2.0) retriable (3.1.2) - rexml (3.2.5) + rexml (3.2.9) + strscan rouge (2.0.7) ruby-macho (2.5.1) ruby2_keywords (0.0.5) - rubyzip (2.3.2) + rubyzip (2.4.1) sassc (2.4.0) ffi (~> 1.9) sawyer (0.9.2) addressable (>= 2.3.5) faraday (>= 0.17.3, < 3) - security (0.1.3) - signet (0.17.0) + security (0.1.5) + signet (0.19.0) addressable (~> 2.8) faraday (>= 0.17.5, < 3.a) jwt (>= 1.5, < 3.0) @@ -324,36 +336,33 @@ GEM simctl (1.6.10) CFPropertyList naturally - slather (2.7.2) + slather (2.8.0) CFPropertyList (>= 2.2, < 4) activesupport clamp (~> 1.3) - nokogiri (~> 1.12) + nokogiri (>= 1.14.3) xcodeproj (~> 1.21) - sqlite3 (1.4.4) + sqlite3 (1.7.3-arm64-darwin) + strscan (3.1.3) terminal-notifier (2.0.0) - terminal-table (1.8.0) - unicode-display_width (~> 1.1, >= 1.1.1) - thor (0.20.3) + terminal-table (3.0.2) + unicode-display_width (>= 1.1.1, < 3) + thor (1.0.1) trailblazer-option (0.1.2) tty-cursor (0.7.1) - tty-screen (0.8.1) + tty-screen (0.8.2) tty-spinner (0.9.3) tty-cursor (~> 0.7) - typhoeus (1.4.0) + typhoeus (1.4.1) ethon (>= 0.9.0) tzinfo (2.0.6) concurrent-ruby (~> 1.0) uber (0.1.0) - unf (0.1.4) - unf_ext - unf_ext (0.0.8.2) - unicode-display_width (1.8.0) - webrick (1.8.1) + unicode-display_width (2.5.0) word_wrap (1.0.0) xcinvoke (0.3.0) liferaft (~> 0.0.6) - xcodeproj (1.22.0) + xcodeproj (1.24.0) CFPropertyList (>= 2.3.3, < 4.0) atomos (~> 0.1.3) claide (>= 1.0.2, < 2.0) @@ -364,17 +373,17 @@ GEM rouge (~> 2.0.7) xcpretty-travis-formatter (1.0.1) xcpretty (~> 0.2, >= 0.0.7) - zeitwerk (2.6.8) + zeitwerk (2.6.13) PLATFORMS - ruby + arm64-darwin-23 DEPENDENCIES cocoapods (= 1.11.3) danger (>= 8.2.3) danger-slather (>= 0.0.6) - danger-swiftlint (>= 0.24.4) - fastlane (>= 2.178.0) + danger-swiftlint (>= 0.36.0) + fastlane (>= 2.216.0) fastlane-plugin-create_xcframework fastlane-plugin-firebase_app_distribution fastlane-plugin-firebase_test_lab! @@ -382,7 +391,8 @@ DEPENDENCIES filesize jazzy (>= 0.14.2) plist + rb-readline xcpretty BUNDLED WITH - 2.2.14 + 2.4.10 diff --git a/Package.swift b/Package.swift index c4856912..3ca02301 100644 --- a/Package.swift +++ b/Package.swift @@ -4,7 +4,7 @@ import PackageDescription let package = Package( name: "TwilioVerifySDK", platforms: [ - .iOS(.v11) + .iOS(.v12) ], products: [ .library( diff --git a/README.md b/README.md index 7e6578af..48456ae0 100644 --- a/README.md +++ b/README.md @@ -46,9 +46,9 @@ None ## Requirements -* iOS 11+ +* iOS 12+ * Swift 5.2 -* Xcode 14.x +* Xcode 16.3+ @@ -64,7 +64,7 @@ None [CocoaPods](https://cocoapods.org) is a dependency manager for Cocoa projects. For usage and installation instructions, visit their website. To integrate TwilioVerify into your Xcode project using CocoaPods, specify it in your `Podfile`: ```ruby -pod 'TwilioVerify', '~> 2.2.2' +pod 'TwilioVerify', '~> 3.0.0' ``` ### Carthage @@ -72,10 +72,10 @@ pod 'TwilioVerify', '~> 2.2.2' [Carthage](https://github.com/Carthage/Carthage) is a decentralized dependency manager that builds your dependencies and provides you with binary frameworks. To integrate TwilioVerify into your Xcode project using Carthage, specify it in your `Cartfile`: ```ogdl -github "twilio/twilio-verify-ios" -> 2.2.2 +github "twilio/twilio-verify-ios" -> 3.0.0 ``` -Since version `2.2.2` of `TwilioVerifySDK` the prebuilt asset fat version `.framework` is been deprecated, to give space for the universal framework `.xcframework`. Make sure to use the new version of Carthage [0.38.0](https://github.com/Carthage/Carthage/releases/tag/0.38.0) that was release in order to support the `xcframework` assets, by using this version or a superior one, Carthage will download and unzip the `TwilioVerifySDK.framework.zip` attached in the release version, resulting in a `TwilioVerifySDK.xcframework` that can be found in the build folder of Carthage. +Since version `3.0.0` of `TwilioVerifySDK` the prebuilt asset fat version `.framework` is been deprecated, to give space for the universal framework `.xcframework`. Make sure to use the new version of Carthage [0.38.0](https://github.com/Carthage/Carthage/releases/tag/0.38.0) that was release in order to support the `xcframework` assets, by using this version or a superior one, Carthage will download and unzip the `TwilioVerifySDK.framework.zip` attached in the release version, resulting in a `TwilioVerifySDK.xcframework` that can be found in the build folder of Carthage. ### Swift Package Manager @@ -85,7 +85,7 @@ Once you have your Swift package set up, adding TwilioVerify as a dependency is ```swift dependencies: [ - .package(url: "https://github.com/twilio/twilio-verify-ios.git", .upToNextMajor(from: "2.2.2")) + .package(url: "https://github.com/twilio/twilio-verify-ios.git", .upToNextMajor(from: "3.0.0")) ] ``` @@ -103,7 +103,7 @@ If you want to receive challenges as push notifications, you should register You The SDK should be used from a Swift class. See an example in the [TwilioVerifyAdapter class](https://github.com/twilio/twilio-verify-ios/blob/main/TwilioVerifyDemo/TwilioVerifyDemo/TwilioVerify/TwilioVerifyAdapter.swift) -Since version `2.2.2`, the target was changed from `TwilioVerify` to `TwilioVerifySDK`. Migrating from older versions will imply to update all the imports in your files, see an example in the [TwilioVerifyAdapter class](https://github.com/twilio/twilio-verify-ios/blob/main/TwilioVerifyDemo/TwilioVerifyDemo/TwilioVerify/TwilioVerifyAdapter.swift#L19) +Since version `3.0.0`, the target was changed from `TwilioVerify` to `TwilioVerifySDK`. Migrating from older versions will imply to update all the imports in your files, see an example in the [TwilioVerifyAdapter class](https://github.com/twilio/twilio-verify-ios/blob/main/TwilioVerifyDemo/TwilioVerifyDemo/TwilioVerify/TwilioVerifyAdapter.swift#L19) --- @@ -346,6 +346,57 @@ To stop sharing existing factors created with **App Groups**, uncheck the **App > This will restrict access to the factors and will not affect the main application in which the data was initially created. +## Privacy Manifest + +This document serves as the Privacy Manifest for the Twilio Verify SDK. It outlines the privacy practices implemented in this SDK, providing a comprehensive understanding of how we handle data and respect user privacy. + +### Purpose + +The primary purpose of this Privacy Manifest is to facilitate developers and organizations in providing Apple with detailed information about the privacy practices employed within this SDK. + +### Usage + +To use this Privacy Manifest, simply refer to the relevant sections when you need to provide information to Apple or any other interested parties about the privacy practices used in this SDK. + +### [Privacy Manifest](TwilioVerifySDK/PrivacyInfo.xcprivacy) + +--- + +## Allow Factors migration + +By default, all factors are securely stored within the device's [Secure Enclave](https://support.apple.com/guide/security/secure-enclave-sec59b0b31ff/web), which provides a high level of protection against unauthorized access and ensures sensitive data remains encrypted. This default setting restricts the migration of these factors from one iPhone to another, enhancing the overall security of the authentication process. + +However, in certain cases, users may want to allow data migration from one iPhone to another or perform backup restoration while retaining their Verify Factors. For this purpose, you can use the **allowIphoneMigration** property within the **PushFactorPayload**. + +### Usage of allowIphoneMigration Property: + +When using the push-based factor for verifying a user, you can include the **allowIphoneMigration** property in the **PushFactorPayload**. By setting this property to `true`, you enable users to migrate their factors to another iPhone or restore them during backup processes. It's essential to carefully consider the security implications before enabling this option, as it may expose the factors to potential risks during data migration or backup restoration. + +### Important Security Considerations: + +Remember to use this option judiciously, as limiting factors to a single device enhances security. Advise users to perform migrations and backups on trusted devices and networks and use additional security measures like passcodes, Touch ID, or Face ID. + +--- + +To enable [Data migration from iPhone to iPhone](https://support.apple.com/en-us/HT210216) or [Backup restoration](https://support.apple.com/en-us/HT204184) for factors, utilize the **allowIphoneMigration** property in the **PushFactorPayload**, IE: + +```swift +let payload = PushFactorPayload( + friendlyName: friendlyName, + serviceSid: serviceSid, + identity: identity, + allowIphoneMigration: true, + pushToken: pushToken, + accessToken: accessToken, + metadata: metadata +) + +twilioVerify.createFactor(withPayload: payload, success: success, failure: failure) +``` + +**Note:** Factors created before implementing this change will not be eligible for migration. Only new factors with the **allowIphoneMigration** property set to `true` will have the capability to migrate from one iPhone to another. + +> For more information about the accessibility attribute, please refer to the [Restricting Keychain Item Accessibility](https://developer.apple.com/documentation/security/keychain_services/keychain_items/restricting_keychain_item_accessibility) documentation --- diff --git a/Scripts/certificate_setup.sh b/Scripts/certificate_setup.sh new file mode 100755 index 00000000..953cffd0 --- /dev/null +++ b/Scripts/certificate_setup.sh @@ -0,0 +1,64 @@ +#!/bin/bash + +set -e + +COMMAND=$1 +RAW_JOB_NAME=$2 + +if [[ -z "$RAW_JOB_NAME" ]]; then + echo "Error: JOB_NAME argument is required." + echo "Usage: $0 {setup|cleanup} " + exit 1 +fi + +# Sanitize job name: replace spaces and slashes with dashes +SANITIZED_JOB_NAME=$(echo "$RAW_JOB_NAME" | tr ' /' '--') + +CERTIFICATE_PATH=$HOME/build_certificate_$SANITIZED_JOB_NAME.p12 +PP_PATH=$HOME/profiles_$SANITIZED_JOB_NAME +mkdir -p $PP_PATH +KEYCHAIN_PATH=$HOME/app-signing-$SANITIZED_JOB_NAME.keychain-db + +setup_certificates() { + echo "Setting up Apple certificates and provisioning profiles for job: $JOB_NAME..." + + # Import certificate and provisioning profiles from CircleCI context + echo -n "$VERIFY_DEMO_CERT" | base64 --decode -o $CERTIFICATE_PATH + echo -n "$VERIFY_DEMO_PROFILE" | base64 --decode -o $PP_PATH/verify_demo.mobileprovision + echo -n "$HOST_APP_PROFILE" | base64 --decode -o $PP_PATH/host_app.mobileprovision + echo -n "$APP_SIZER_PROFILE" | base64 --decode -o $PP_PATH/app_sizer.mobileprovision + + # Create temporary keychain + security create-keychain -p "$KEYCHAIN_PASS" $KEYCHAIN_PATH + security set-keychain-settings -lut 21600 $KEYCHAIN_PATH + security unlock-keychain -p "$KEYCHAIN_PASS" $KEYCHAIN_PATH + + # Import certificate + security import $CERTIFICATE_PATH -P "$VERIFY_DEMO_CERT_PASS" -A -t cert -f pkcs12 -k $KEYCHAIN_PATH + security set-key-partition-list -S apple-tool:,apple: -k "$KEYCHAIN_PASS" $KEYCHAIN_PATH + security list-keychain -d user -s $KEYCHAIN_PATH + + # Apply provisioning profiles + mkdir -p ~/Library/MobileDevice/Provisioning\ Profiles + cp -a $PP_PATH/* ~/Library/MobileDevice/Provisioning\ Profiles +} + +cleanup_signing() { + echo "Cleaning up keychain and provisioning profile for job: $JOB_NAME..." + security delete-keychain $KEYCHAIN_PATH || true + rm -f $CERTIFICATE_PATH || true + rm -rf $PP_PATH || true +} + +case "$COMMAND" in + setup) + setup_certificates + ;; + cleanup) + cleanup_signing + ;; + *) + echo "Usage: $0 {setup|cleanup} " + exit 1 + ;; +esac \ No newline at end of file diff --git a/TwilioVerify.podspec b/TwilioVerify.podspec index af43ae84..9c75e8ae 100644 --- a/TwilioVerify.podspec +++ b/TwilioVerify.podspec @@ -1,14 +1,14 @@ Pod::Spec.new do |s| s.name = 'TwilioVerify' s.module_name = 'TwilioVerifySDK' - s.version = '2.2.2' + s.version = '3.0.0' s.license = { :type => 'Apache-2.0', :file => 'LICENSE' } s.summary = 'TwilioVerify' s.homepage = 'https://github.com/twilio/twilio-verify-ios' s.authors = { 'Twilio' => 'help@twilio.com' } s.source = { :git => 'https://github.com/twilio/twilio-verify-ios.git', :tag => s.version } s.documentation_url = 'https://twilio.github.io/twilio-verify-ios/latest/' - s.ios.deployment_target = '11.0' + s.ios.deployment_target = '12.0' s.swift_version = '5.2' s.source_files = 'TwilioVerifySDK/TwilioVerify/**/*.swift', 'TwilioVerifySDK/TwilioSecurity/**/*.swift' end diff --git a/TwilioVerifyDemo/TwilioVerifyDemo.xcodeproj/project.pbxproj b/TwilioVerifyDemo/TwilioVerifyDemo.xcodeproj/project.pbxproj index 712edc83..77f6e71a 100644 --- a/TwilioVerifyDemo/TwilioVerifyDemo.xcodeproj/project.pbxproj +++ b/TwilioVerifyDemo/TwilioVerifyDemo.xcodeproj/project.pbxproj @@ -3,7 +3,7 @@ archiveVersion = 1; classes = { }; - objectVersion = 52; + objectVersion = 54; objects = { /* Begin PBXBuildFile section */ @@ -533,7 +533,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 11.0; + IPHONEOS_DEPLOYMENT_TARGET = 12.0; MARKETING_VERSION = "$(DEMO_VERSION)"; MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; MTL_FAST_MATH = YES; @@ -590,7 +590,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 11.0; + IPHONEOS_DEPLOYMENT_TARGET = 12.0; MARKETING_VERSION = "$(DEMO_VERSION)"; MTL_ENABLE_DEBUG_INFO = NO; MTL_FAST_MATH = YES; @@ -611,7 +611,7 @@ CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_TEAM = ""; INFOPLIST_FILE = TwilioVerifyDemo/Common/Info.plist; - IPHONEOS_DEPLOYMENT_TARGET = 11.0; + IPHONEOS_DEPLOYMENT_TARGET = 12.0; LD_RUNPATH_SEARCH_PATHS = ( "$(inherited)", "@executable_path/Frameworks", @@ -630,12 +630,12 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CODE_SIGN_ENTITLEMENTS = TwilioVerifyDemo/TwilioVerifyDemo.entitlements; - CODE_SIGN_IDENTITY = "iPhone Distribution"; + CODE_SIGN_IDENTITY = "iPhone Developer"; CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_TEAM = ""; INFOPLIST_FILE = TwilioVerifyDemo/Common/Info.plist; - IPHONEOS_DEPLOYMENT_TARGET = 11.0; + IPHONEOS_DEPLOYMENT_TARGET = 12.0; LD_RUNPATH_SEARCH_PATHS = ( "$(inherited)", "@executable_path/Frameworks", @@ -654,9 +654,11 @@ buildSettings = { ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; BUNDLE_LOADER = "$(TEST_HOST)"; - CODE_SIGN_STYLE = Automatic; - DEVELOPMENT_TEAM = 9EVH78F4V4; + CODE_SIGN_IDENTITY = ""; + CODE_SIGN_STYLE = Manual; + DEVELOPMENT_TEAM = ""; INFOPLIST_FILE = TwilioVerifyDemoTests/Info.plist; + IPHONEOS_DEPLOYMENT_TARGET = 12.0; LD_RUNPATH_SEARCH_PATHS = ( "$(inherited)", "@executable_path/Frameworks", @@ -664,6 +666,7 @@ ); PRODUCT_BUNDLE_IDENTIFIER = com.twilio.TwilioVerifyDemoTests; PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE_SPECIFIER = ""; SWIFT_VERSION = 5.0; TARGETED_DEVICE_FAMILY = "1,2"; TEST_HOST = "$(BUILT_PRODUCTS_DIR)/TwilioVerifyDemo.app/TwilioVerifyDemo"; @@ -675,9 +678,11 @@ buildSettings = { ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; BUNDLE_LOADER = "$(TEST_HOST)"; - CODE_SIGN_STYLE = Automatic; - DEVELOPMENT_TEAM = 9EVH78F4V4; + CODE_SIGN_IDENTITY = ""; + CODE_SIGN_STYLE = Manual; + DEVELOPMENT_TEAM = ""; INFOPLIST_FILE = TwilioVerifyDemoTests/Info.plist; + IPHONEOS_DEPLOYMENT_TARGET = 12.0; LD_RUNPATH_SEARCH_PATHS = ( "$(inherited)", "@executable_path/Frameworks", @@ -685,6 +690,7 @@ ); PRODUCT_BUNDLE_IDENTIFIER = com.twilio.TwilioVerifyDemoTests; PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE_SPECIFIER = ""; SWIFT_VERSION = 5.0; TARGETED_DEVICE_FAMILY = "1,2"; TEST_HOST = "$(BUILT_PRODUCTS_DIR)/TwilioVerifyDemo.app/TwilioVerifyDemo"; diff --git a/TwilioVerifyDemo/TwilioVerifyDemo/ChallengeDetail/Presenter/ChallengeDetailPresenter.swift b/TwilioVerifyDemo/TwilioVerifyDemo/ChallengeDetail/Presenter/ChallengeDetailPresenter.swift index 20ec9a8a..6471c926 100644 --- a/TwilioVerifyDemo/TwilioVerifyDemo/ChallengeDetail/Presenter/ChallengeDetailPresenter.swift +++ b/TwilioVerifyDemo/TwilioVerifyDemo/ChallengeDetail/Presenter/ChallengeDetailPresenter.swift @@ -76,7 +76,7 @@ extension ChallengeDetailPresenter: ChallengeDetailPresentable { factorSid: factorSid, challengeSid: challengeSid, status: status - ) + ) twilioVerify.updateChallenge(withPayload: payload, success: { [weak self] in guard let strongSelf = self else { return } strongSelf.fetchChallengeDetails() diff --git a/TwilioVerifyDemo/TwilioVerifyDemo/Common/View/Base.lproj/Main.storyboard b/TwilioVerifyDemo/TwilioVerifyDemo/Common/View/Base.lproj/Main.storyboard index dcf161e3..21250fb5 100644 --- a/TwilioVerifyDemo/TwilioVerifyDemo/Common/View/Base.lproj/Main.storyboard +++ b/TwilioVerifyDemo/TwilioVerifyDemo/Common/View/Base.lproj/Main.storyboard @@ -1,9 +1,9 @@ - + - + @@ -21,7 +21,7 @@ - + @@ -30,7 +30,7 @@ - + @@ -39,7 +39,7 @@ - - - - + + + + + + + + + + + + + + + + + + + + + + + - + - - + + - - @@ -91,9 +113,10 @@ + - + @@ -108,7 +131,7 @@ - + @@ -141,7 +164,7 @@ - + @@ -183,7 +206,7 @@ - + @@ -335,11 +358,11 @@ - +