Skip to content

Fix 4.4.0 GlitchTip crashes in session re-auth, cryptor, conversations, and data storage search - #17

Merged
alessioc42 merged 3 commits into
mainfrom
fix/glitchtip-4-4-0-crashes
Nov 23, 2026
Merged

alessioc42 merged 3 commits into
mainfrom
fix/glitchtip-4-4-0-crashes

Conversation

@alessioc42

Copy link
Copy Markdown
Member

Summary

Fixes the highest-impact actionable crashes reported in GlitchTip for 4.4.0+98:

  • Data storage search on iOS (#54): Remove the request body and application/x-www-form-urlencoded content type from DataStorageParser.searchFiles GET request (which NSURLSession rejects with NSURLErrorDomain code=-1103), map DioException to NetworkException and 302 to UnauthorizedException, and safely decode both List and JSON String responses.
  • Concurrent applet re-authentication (#1019, #1020, #1026, #1027, #1029, #56, #70, #842–#898): Track LanisSession.authGeneration and add reauthenticateIfStale(observedGeneration) so concurrent applet retries share an in-flight re-authentication or skip re-authenticating after a fresh login instead of calling jar.deleteAll() and rotating the encryption key while another applet's retry is in flight.
  • Session redirect & null-check hardening (#31, #93, #189, #419): Guard parseAccountType, parseUserData, getFastTravelMenu, and benutzerverwaltung.php?a=userData redirects so unexpected redirects/HTML throw UnauthorizedException, PasswordChangeRequiredException, or UnknownException instead of raw TypeError / FormatException.
  • Empty ciphertext RangeError (-16) (#185): Reject 16-byte Salted__ + salt payloads with zero ciphertext bytes in Cryptor.decryptWithKey.
  • Conversations parsing (#1022, #56, #70): Handle 302 redirects, pre-decoded Map vs String bodies, non-string rows (e.g. false), and decryption ArgumentError/FormatException in ConversationsParser.getHome.

Test plan

  • dart analyze lib test — no issues
  • dart test — all tests pass (including new tests in data_storage_parser_test.dart, conversations_get_home_test.dart, session_authentication_concurrency_test.dart, and cryptor_test.dart)
  • Verified DataStorageParser.searchFiles live on iOS 27.0 (iPhone 18 Pro simulator) against a real account

@alessioc42
alessioc42 merged commit 88580ba into main Nov 23, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant