From d94aaf4b202e1ca9351ae06204a3b664f2c7ea1e Mon Sep 17 00:00:00 2001 From: Doug Date: Tue, 28 Nov 2023 10:11:05 +0000 Subject: [PATCH 1/5] Prepare for new sprint From f666b8f297edbbc431bee6d590bfae090da3f4c8 Mon Sep 17 00:00:00 2001 From: Doug <6060466+pixlwave@users.noreply.github.com> Date: Tue, 28 Nov 2023 13:04:36 +0000 Subject: [PATCH 2/5] Update CocoaPods and other gems. (#1835) --- Gemfile | 2 +- Gemfile.lock | 81 +++++++++++++++++++++------------------ changelog.d/pr-1835.build | 1 + 3 files changed, 46 insertions(+), 38 deletions(-) create mode 100644 changelog.d/pr-1835.build diff --git a/Gemfile b/Gemfile index f6e2a0038d..2aa841dabd 100644 --- a/Gemfile +++ b/Gemfile @@ -1,6 +1,6 @@ source "https://rubygems.org" gem "fastlane" -gem "cocoapods", '~>1.13.0' +gem "cocoapods", '~>1.14.3' gem "xcode-install" gem "slather" diff --git a/Gemfile.lock b/Gemfile.lock index e66916b798..317baa44e3 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -3,10 +3,15 @@ GEM specs: CFPropertyList (3.0.6) rexml - activesupport (7.0.8) + activesupport (7.1.2) + base64 + bigdecimal concurrent-ruby (~> 1.0, >= 1.0.2) + connection_pool (>= 2.2.5) + drb i18n (>= 1.6, < 2) minitest (>= 5.1) + mutex_m tzinfo (~> 2.0) addressable (2.8.5) public_suffix (>= 2.0.2, < 6.0) @@ -15,31 +20,33 @@ GEM json (>= 1.5.1) artifactory (3.0.15) atomos (0.1.3) - aws-eventstream (1.2.0) - aws-partitions (1.828.0) - aws-sdk-core (3.183.1) + aws-eventstream (1.3.0) + aws-partitions (1.859.0) + aws-sdk-core (3.188.0) aws-eventstream (~> 1, >= 1.0.2) aws-partitions (~> 1, >= 1.651.0) aws-sigv4 (~> 1.5) jmespath (~> 1, >= 1.6.1) - aws-sdk-kms (1.71.0) - aws-sdk-core (~> 3, >= 3.177.0) + aws-sdk-kms (1.73.0) + aws-sdk-core (~> 3, >= 3.188.0) aws-sigv4 (~> 1.1) - aws-sdk-s3 (1.136.0) - aws-sdk-core (~> 3, >= 3.181.0) + aws-sdk-s3 (1.140.0) + aws-sdk-core (~> 3, >= 3.188.0) aws-sdk-kms (~> 1) aws-sigv4 (~> 1.6) - aws-sigv4 (1.6.0) + aws-sigv4 (1.7.0) aws-eventstream (~> 1, >= 1.0.2) babosa (1.0.4) + base64 (0.2.0) + bigdecimal (3.1.4) claide (1.1.0) clamp (1.3.2) - cocoapods (1.13.0) + cocoapods (1.14.3) addressable (~> 2.8) claide (>= 1.0.2, < 2.0) - cocoapods-core (= 1.13.0) + cocoapods-core (= 1.14.3) cocoapods-deintegrate (>= 1.0.3, < 2.0) - cocoapods-downloader (>= 1.6.0, < 2.0) + cocoapods-downloader (>= 2.1, < 3.0) cocoapods-plugins (>= 1.0.0, < 2.0) cocoapods-search (>= 1.0.0, < 2.0) cocoapods-trunk (>= 1.6.0, < 2.0) @@ -52,7 +59,7 @@ GEM nap (~> 1.0) ruby-macho (>= 2.3.0, < 3.0) xcodeproj (>= 1.23.0, < 2.0) - cocoapods-core (1.13.0) + cocoapods-core (1.14.3) activesupport (>= 5.0, < 8) addressable (~> 2.8) algoliasearch (~> 1.0) @@ -63,7 +70,7 @@ GEM public_suffix (~> 4.0) typhoeus (~> 1.0) cocoapods-deintegrate (1.0.5) - cocoapods-downloader (1.6.3) + cocoapods-downloader (2.1) cocoapods-plugins (1.0.0) nap cocoapods-search (1.0.1) @@ -76,17 +83,19 @@ GEM commander (4.6.0) highline (~> 2.0.0) concurrent-ruby (1.2.2) + connection_pool (2.4.1) declarative (0.0.20) digest-crc (0.6.5) rake (>= 12.0.0, < 14.0.0) - domain_name (0.5.20190701) - unf (>= 0.0.5, < 1.0.0) + domain_name (0.6.20231109) dotenv (2.8.1) + drb (2.2.0) + ruby2_keywords emoji_regex (3.2.3) escape (0.0.4) ethon (0.16.0) ffi (>= 1.15.0) - excon (0.103.0) + excon (0.104.0) faraday (1.10.3) faraday-em_http (~> 1.0) faraday-em_synchrony (~> 1.0) @@ -116,7 +125,7 @@ GEM faraday_middleware (1.2.0) faraday (~> 1.0) fastimage (2.2.7) - fastlane (2.216.0) + fastlane (2.217.0) CFPropertyList (>= 2.3, < 4.0.0) addressable (>= 2.8, < 3.0.0) artifactory (~> 3.0) @@ -156,13 +165,13 @@ GEM xcodeproj (>= 1.13.0, < 2.0.0) xcpretty (~> 0.3.0) xcpretty-travis-formatter (>= 0.0.3) - ffi (1.16.2) + ffi (1.16.3) fourflusher (2.3.1) fuzzy_match (2.0.4) gh_inspector (1.1.3) - google-apis-androidpublisher_v3 (0.50.0) + google-apis-androidpublisher_v3 (0.53.0) google-apis-core (>= 0.11.0, < 2.a) - google-apis-core (0.11.1) + google-apis-core (0.11.2) addressable (~> 2.5, >= 2.5.1) googleauth (>= 0.16.2, < 2.a) httpclient (>= 2.8.1, < 3.a) @@ -175,19 +184,19 @@ GEM 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-apis-storage_v1 (0.29.0) + google-apis-core (>= 0.11.0, < 2.a) google-cloud-core (1.6.0) google-cloud-env (~> 1.0) 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-storage (1.45.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.29.0) google-cloud-core (~> 1.6) googleauth (>= 0.16.2, < 2.a) mini_mime (~> 1.0) @@ -208,24 +217,25 @@ GEM jwt (2.7.1) mini_magick (4.12.0) mini_mime (1.1.5) - mini_portile2 (2.8.4) + mini_portile2 (2.8.5) minitest (5.20.0) molinillo (0.8.0) multi_json (1.15.0) multipart-post (2.3.0) + mutex_m (0.2.0) nanaimo (0.3.0) nap (1.1.0) naturally (2.2.1) netrc (0.11.0) - nokogiri (1.15.4) + nokogiri (1.15.5) mini_portile2 (~> 2.8.2) racc (~> 1.4) optparse (0.1.1) os (1.1.4) plist (3.7.0) public_suffix (4.0.7) - racc (1.7.1) - rake (13.0.6) + racc (1.7.3) + rake (13.1.0) representable (3.2.0) declarative (< 0.1.0) trailblazer-option (>= 0.1.1, < 0.2.0) @@ -245,11 +255,11 @@ GEM simctl (1.6.10) CFPropertyList naturally - slather (2.7.4) + slather (2.8.0) CFPropertyList (>= 2.2, < 4) activesupport clamp (~> 1.3) - nokogiri (>= 1.13.9) + nokogiri (>= 1.14.3) xcodeproj (~> 1.21) terminal-notifier (2.0.0) terminal-table (3.0.2) @@ -259,15 +269,12 @@ GEM tty-screen (0.8.1) 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 (2.4.2) + unicode-display_width (2.5.0) webrick (1.8.1) word_wrap (1.0.0) xcode-install (2.8.1) @@ -289,7 +296,7 @@ PLATFORMS ruby DEPENDENCIES - cocoapods (~> 1.13.0) + cocoapods (~> 1.14.3) fastlane slather xcode-install diff --git a/changelog.d/pr-1835.build b/changelog.d/pr-1835.build new file mode 100644 index 0000000000..bbde692d8d --- /dev/null +++ b/changelog.d/pr-1835.build @@ -0,0 +1 @@ +Update CocoaPods and other gems. \ No newline at end of file From 19f5acd0af2cd72565f341729837892b29b3d053 Mon Sep 17 00:00:00 2001 From: Yoan Pintas Date: Wed, 6 Dec 2023 09:48:17 +0000 Subject: [PATCH 3/5] Update regex for email address (#1826) * Update regex for email address * Add changelog Signed-off-by: yostyle * Add unit test * rename changelog --------- Signed-off-by: yostyle --- MatrixSDK/Utils/MXTools.m | 2 +- MatrixSDKTests/MXToolsUnitTests.m | 52 +++++++++++++++++++++++++++++++ changelog.d/pr-1826.bugfix | 1 + 3 files changed, 54 insertions(+), 1 deletion(-) create mode 100644 changelog.d/pr-1826.bugfix diff --git a/MatrixSDK/Utils/MXTools.m b/MatrixSDK/Utils/MXTools.m index e17e7134cb..22435cd7dc 100644 --- a/MatrixSDK/Utils/MXTools.m +++ b/MatrixSDK/Utils/MXTools.m @@ -30,7 +30,7 @@ #warning File has not been annotated with nullability, see MX_ASSUME_MISSING_NULLABILITY_BEGIN #pragma mark - Constant definition -NSString *const kMXToolsRegexStringForEmailAddress = @"[A-Z0-9._%+-]+@[A-Z0-9.-]+\\.[A-Z]{2,}"; +NSString *const kMXToolsRegexStringForEmailAddress = @"^[a-zA-Z0-9_!#$%&'*+/=?`{|}~^-]+(?:\\.[a-zA-Z0-9_!#$%&'*+/=?`{|}~^-]+)*@[a-zA-Z0-9-]+(?:\\.[a-zA-Z0-9-]+)*$"; // The HS domain part in Matrix identifiers #define MATRIX_HOMESERVER_DOMAIN_REGEX @"[A-Z0-9]+((\\.|\\-)[A-Z0-9]+){0,}(:[0-9]{2,5})?" diff --git a/MatrixSDKTests/MXToolsUnitTests.m b/MatrixSDKTests/MXToolsUnitTests.m index 4e15a4e109..efcf636df4 100644 --- a/MatrixSDKTests/MXToolsUnitTests.m +++ b/MatrixSDKTests/MXToolsUnitTests.m @@ -68,6 +68,58 @@ - (void)testMatrixIdentifiers XCTAssertTrue([MXTools isMatrixGroupIdentifier:@"+matrix:matrix.org"]); } +- (void)testEmailAddresses +{ + XCTAssertTrue([MXTools isEmailAddress:@"alice@matrix.org"]); + XCTAssertTrue([MXTools isEmailAddress:@"alice@matrix"]); + XCTAssertTrue([MXTools isEmailAddress:@"al-i_ce@matrix"]); + XCTAssertTrue([MXTools isEmailAddress:@"al+ice@matrix.org"]); + XCTAssertTrue([MXTools isEmailAddress:@"al=ice@matrix.org"]); + XCTAssertTrue([MXTools isEmailAddress:@"*@example.net"]); + XCTAssertTrue([MXTools isEmailAddress:@"fred&barny@example.com"]); + XCTAssertTrue([MXTools isEmailAddress:@"---@example.com"]); + XCTAssertTrue([MXTools isEmailAddress:@"foo-bar@example.net"]); + XCTAssertTrue([MXTools isEmailAddress:@"mailbox.sub1.sub2@this-domain"]); + XCTAssertTrue([MXTools isEmailAddress:@"prettyandsimple@example.com"]); + XCTAssertTrue([MXTools isEmailAddress:@"very.common@example.com"]); + XCTAssertTrue([MXTools isEmailAddress:@"disposable.style.email.with+symbol@example.com"]); + XCTAssertTrue([MXTools isEmailAddress:@"other.email-with-dash@example.com"]); + XCTAssertTrue([MXTools isEmailAddress:@"x@example.com"]); + XCTAssertTrue([MXTools isEmailAddress:@"example-indeed@strange-example.com"]); + XCTAssertTrue([MXTools isEmailAddress:@"admin@mailserver1"]); + XCTAssertTrue([MXTools isEmailAddress:@"#!$%&'*+-/=?^_`{}|~@example.org"]); + XCTAssertTrue([MXTools isEmailAddress:@"example@localhost"]); + XCTAssertTrue([MXTools isEmailAddress:@"example@s.solutions"]); + XCTAssertTrue([MXTools isEmailAddress:@"user@localserver"]); + XCTAssertTrue([MXTools isEmailAddress:@"user@tt"]); + XCTAssertTrue([MXTools isEmailAddress:@"xn--80ahgue5b@xn--p-8sbkgc5ag7bhce.xn--ba-lmcq"]); + XCTAssertTrue([MXTools isEmailAddress:@"nothing@xn--fken-gra.no"]); + + XCTAssertFalse([MXTools isEmailAddress:@"alice.matrix.org"]); + XCTAssertFalse([MXTools isEmailAddress:@"al ice@matrix.org"]); + XCTAssertFalse([MXTools isEmailAddress:@"al(ice@matrix.org"]); + XCTAssertFalse([MXTools isEmailAddress:@"alice@"]); + XCTAssertFalse([MXTools isEmailAddress:@"al\nice@matrix.org"]); + XCTAssertFalse([MXTools isEmailAddress:@"al@ice@matrix.org"]); + XCTAssertFalse([MXTools isEmailAddress:@"al@ice@.matrix.org"]); + XCTAssertFalse([MXTools isEmailAddress:@"Just a string"]); + XCTAssertFalse([MXTools isEmailAddress:@"string"]); + XCTAssertFalse([MXTools isEmailAddress:@"me@"]); + XCTAssertFalse([MXTools isEmailAddress:@"@example.com"]); + XCTAssertFalse([MXTools isEmailAddress:@"me.@example.com"]); + XCTAssertFalse([MXTools isEmailAddress:@".me@example.com"]); + XCTAssertFalse([MXTools isEmailAddress:@"me@example..com"]); + XCTAssertFalse([MXTools isEmailAddress:@"me\\@example.com"]); + XCTAssertFalse([MXTools isEmailAddress:@"Abc.example.com"]); + XCTAssertFalse([MXTools isEmailAddress:@"A@b@c@example.com"]); + XCTAssertFalse([MXTools isEmailAddress:@"a\"b(c)d,e:f;gi[j\\k]l@example.com"]); + XCTAssertFalse([MXTools isEmailAddress:@"just\"not\"right@example.com"]); + XCTAssertFalse([MXTools isEmailAddress:@"this is\"not\\allowed@example.com"]); + XCTAssertFalse([MXTools isEmailAddress:@"this\\ still\\\"not\\\\allowed@example.com"]); + XCTAssertFalse([MXTools isEmailAddress:@"john..doe@example.com"]); + XCTAssertFalse([MXTools isEmailAddress:@"john.doe@example..com"]); +} + #pragma mark - Strings encoding diff --git a/changelog.d/pr-1826.bugfix b/changelog.d/pr-1826.bugfix new file mode 100644 index 0000000000..f73b7d941b --- /dev/null +++ b/changelog.d/pr-1826.bugfix @@ -0,0 +1 @@ +Update regex for email address to be aligned email format in RFC 5322 \ No newline at end of file From d2bbd1affa112e06c9d9cdd3985015fde6b5e418 Mon Sep 17 00:00:00 2001 From: Mauro Romito Date: Tue, 9 Jan 2024 11:59:51 +0100 Subject: [PATCH 4/5] version++ --- CHANGES.md | 11 +++++++++++ MatrixSDK.podspec | 2 +- MatrixSDK/MatrixSDKVersion.m | 2 +- changelog.d/pr-1826.bugfix | 1 - changelog.d/pr-1835.build | 1 - 5 files changed, 13 insertions(+), 4 deletions(-) delete mode 100644 changelog.d/pr-1826.bugfix delete mode 100644 changelog.d/pr-1835.build diff --git a/CHANGES.md b/CHANGES.md index 6a9aa8313f..a9e708f354 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,3 +1,14 @@ +## Changes in 0.27.5 (2024-01-09) + +🐛 Bugfixes + +- Update regex for email address to be aligned email format in RFC 5322 ([#1826](https://github.com/matrix-org/matrix-ios-sdk/pull/1826)) + +🧱 Build + +- Update CocoaPods and other gems. ([#1835](https://github.com/matrix-org/matrix-ios-sdk/pull/1835)) + + ## Changes in 0.27.4 (2023-11-28) 🐛 Bugfixes diff --git a/MatrixSDK.podspec b/MatrixSDK.podspec index a86e1a6fbc..c0ccd57631 100644 --- a/MatrixSDK.podspec +++ b/MatrixSDK.podspec @@ -1,7 +1,7 @@ Pod::Spec.new do |s| s.name = "MatrixSDK" - s.version = "0.27.4" + s.version = "0.27.5" s.summary = "The iOS SDK to build apps compatible with Matrix (https://www.matrix.org)" s.description = <<-DESC diff --git a/MatrixSDK/MatrixSDKVersion.m b/MatrixSDK/MatrixSDKVersion.m index bb04b8853d..79f6a20957 100644 --- a/MatrixSDK/MatrixSDKVersion.m +++ b/MatrixSDK/MatrixSDKVersion.m @@ -16,4 +16,4 @@ #import -NSString *const MatrixSDKVersion = @"0.27.4"; +NSString *const MatrixSDKVersion = @"0.27.5"; diff --git a/changelog.d/pr-1826.bugfix b/changelog.d/pr-1826.bugfix deleted file mode 100644 index f73b7d941b..0000000000 --- a/changelog.d/pr-1826.bugfix +++ /dev/null @@ -1 +0,0 @@ -Update regex for email address to be aligned email format in RFC 5322 \ No newline at end of file diff --git a/changelog.d/pr-1835.build b/changelog.d/pr-1835.build deleted file mode 100644 index bbde692d8d..0000000000 --- a/changelog.d/pr-1835.build +++ /dev/null @@ -1 +0,0 @@ -Update CocoaPods and other gems. \ No newline at end of file From 5e2325022202f1dc1689b2d8f00571bd6f51e457 Mon Sep 17 00:00:00 2001 From: Mauro Romito Date: Tue, 9 Jan 2024 12:32:39 +0100 Subject: [PATCH 5/5] finish version++ --- Podfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Podfile.lock b/Podfile.lock index b816768da1..4c47966393 100644 --- a/Podfile.lock +++ b/Podfile.lock @@ -73,4 +73,4 @@ SPEC CHECKSUMS: PODFILE CHECKSUM: 1bf28f5a19566c567d265232f60ee19a3ae86ed3 -COCOAPODS: 1.13.0 +COCOAPODS: 1.14.3