Commit Graph

91 Commits (f5e48cec0139deb18c3f66f6da8588215abed52f)

Author SHA1 Message Date
Morgan Pretty 1edd500dab Updated to the latest blinding behaviour
Added a couple more dependencies for unit testing injection
Updated the MessageSender to set the sender of the message to the appropriate blinded/unblinded key
Updated the OpenGroup Message to handle verification of both blinded and unblinded messages
Updated the MessageSender to use dependency injection for it's sendToOpenGroupDestination method
Updated the JSONDecoder to support getting dependencies (for signature verification)
Fixed tests broken by updating the signing logic
3 years ago
Morgan Pretty ef09d4d5aa Additional encryption work on id blinding
Got the updated blinding logic working (at least when authenticating a request - still need to deal with message signing and verification)
Storing the server capabilities in the database now so we can correctly blind requests based on them
Renamed the remaining 'v2' functions and classes to just be 'OpenGroup' since there isn't a 'V2' anymore
Cleaned up a few TODOs and functions
3 years ago
Morgan Pretty b655882cbd Started resolving TODOs
Added some new properties to the OpenGroupV2
Moved a number of methods and variables from OpenGroupAPI to OpenGroupManager (anything doing actual logic)
Moved the message signing into the OpenGroupAPI (since that's the only place it happens)
Renamed remaining old model classes to start with 'Legacy' to make clean up easier
Updated the OpenGroupAPI poll method to use the same logic as it previously did to determine if it should retrieve recent messages or messages since the last one
3 years ago
Morgan Pretty 8cc9caa0fd Renamed the OpenGroupPollerV2 and OpenGroupManagerV2 3 years ago
Morgan Pretty 63e6cdd9ec Renamed OpenGroupAPIV2 to OpenGroupAPI
Added the inbox endpoints
3 years ago
Morgan Pretty 4963a84ddd Added more unit tests for the OpenGroupAPI (fixed a couple bugs as well) 3 years ago
Morgan Pretty eb927c36a9 Started cleaning up some of the SOGS and Onion Requests structure
Cleaned up the OnionRequestAPI so we don't need the LegacyOnionRequestAPI
Added requests for the user endpoints
Added deprecated flags to the legacy endpoints and functions
Added some logic to start handling the new poll (batch) response
Started adding unit tests for the OpenGroupAPI functions
3 years ago
Morgan Pretty c90f346d6a Further SOGS V4 integration work
Added in the v4 onion requests logic
Added in the new pin/unpin APIs
Split up additional legacy methods to try and simplify the refactoring
Added a number of TODOs around usage of legacy request methods
3 years ago
Morgan Pretty 4f3900771e More work on getting SOGS V4 integrated
Updated the MessageSendJob to support V4 messages (V2 messages will be upgraded to V4 if they get re-encoded)
Renamed the Message+Destination from 'openGroup' & 'openGroupV2' to 'legacyOpenGroup' and 'openGroup'
Started plugging in more of the V4 APIs
Renamed a number of the V2 APIs to start with 'legacy'
3 years ago
Morgan Pretty 2284375fc0 Started work on updated SOGS support
Split the OpenGroupAPIV2 into separate files
Started working on the new auth and blinded-id approaches (new auth working with un-blinded id suggesting blinded-id code is incorrect)
Updated the SOGS request/response types to use Codable
Updated the SOGS Request type to use enums instead of strings for keys (to reduce likelihood of typos breaking things)
Updated SessionMessagingKit to use Codable and JSONEncoder/JSONDecoder instead of the legacy JSONSerialization
Cleaned up some naming conventions in the SessionMessagingKit (calling a URLRequest body 'parameters' is very confusing...)
Removed the custom TSRequest class (just using standard URLRequest everywhere instead)
Added a number of extension functions to enable some more functional-coding styles
Added extensions to Sodium methods to allow scalar multiplication and the ability to hash providing a salt and a personalisation value (both needed for new SOGS auth)
Fixed an issue where the legacy auth for SOGS could crash due to threading issues (multiple threads accessing the same variable)
Fixed an issue where if you were in two rooms in a single SOGS and deleted one of them, the other room would stop getting updates as the server public key was getting removed
3 years ago
Morgan Pretty 394b0646a3 Updated the code to support additional session id prefixes 3 years ago
Niels Andriesse e84fc1aa04 Include destination info in error messages 4 years ago
Niels Andriesse ba60879343 Add support for new ban and delete all endpoint 4 years ago
nielsandriesse 0d9f5388da Prepare for OGS timestamp handling changes 4 years ago
Niels Andriesse 601062c9ef Fix timeSinceLastOpen usage 4 years ago
Brice-W 51ba97827d open group polling limit implementation 4 years ago
Niels Andriesse 3fda8daec9 Merge branch 'dev' into cleanup 4 years ago
Niels Andriesse e2715d1ee9 Implement sending logic 4 years ago
Niels Andriesse 7e60d3c218 Merge branch 'dev' into cleanup 4 years ago
Niels Andriesse ad801d4f33 Fix threading 4 years ago
nielsandriesse 06f795169b Merge branch 'dev' into cleanup 4 years ago
nielsandriesse 964cb8b326 Fix new deletion method 4 years ago
nielsandriesse 21acdfc835 Clean up thread model 4 years ago
Niels Andriesse d742fc1548 Delete V1 OGS & file server 4 years ago
Niels Andriesse 3daa6e8de1 Fix deletion handling 4 years ago
Niels Andriesse 4eb7d19b3e Fix initial rooms fetch 4 years ago
Niels Andriesse c747acfc04 Fix compact poll deletion handling 4 years ago
nielsandriesse deb301e5b7 Update for OGS API changes 4 years ago
Niels Andriesse e9df213bfe Put feature flags in one place 4 years ago
Niels Andriesse b516647125 Switch to production 4 years ago
Niels Andriesse cfb1d78d35 Fix compact polling auth token handling 4 years ago
Niels Andriesse f865bd8125 Enable V2 open groups 4 years ago
Niels Andriesse b85edbe900 Fix potentially duplicated requests 4 years ago
Niels Andriesse 5a242ce4e8 Debug 4 years ago
Niels Andriesse fac376bf55 Use HTTP for default session open group server 4 years ago
Niels Andriesse 4774123ad4 Update V2 open group poller for compact polling 4 years ago
Niels Andriesse 2eab06cec9 Add compact poll endpoint 4 years ago
Niels Andriesse b30d6f9add Store V2 open group auth token promises per room 4 years ago
nielsandriesse 330e4ce8ad Fix unnecessary V2 open group requests 4 years ago
Niels Andriesse b334ad3446 Update for back-end changes 4 years ago
Niels Andriesse d4b745a322 Cache open group preview images 4 years ago
Niels Andriesse 2dab160599 Actually set open group images 4 years ago
Niels Andriesse c42a694ef6 Show group images 4 years ago
Niels Andriesse 50ab253576 Add group image endpoint 4 years ago
Niels Andriesse 1e9b1520e1 Fix auth token handling 4 years ago
Niels Andriesse e5b5f2cf07 Put V2 open groups behind a feature flag 4 years ago
Niels Andriesse 44783ddfef Update ConfigurationMessage for V2 open groups 4 years ago
Niels Andriesse 7558e0b32a Re-enable joining V1 open groups 4 years ago
Niels Andriesse 5504f74659 Show V2 open group member count 4 years ago
Niels Andriesse e50f4da63e Update AttachmentDownloadJob & AttachmentUploadJob for V2 open groups 4 years ago