Commit Graph

2787 Commits

Author SHA1 Message Date
Julian Sparber
07066e1c1f store: Make sure that event position in store is contiguous
This fixes the breaking gap in the timeline when reading the events from
store.
2022-03-28 15:50:48 +02:00
Damir Jelić
4b58017951 chore(crypto): Add umlauts to a copyright holder
Co-authored-by: Jonas Platte <jplatte@element.io>
2022-03-28 14:24:38 +02:00
Damir Jelić
5db5341974 chore(crypto): Use a specialized CrossSigning type 2022-03-28 13:53:01 +02:00
Damir Jelić
9a3d097331 chore(crypto): Use a specialized DeviceKeys type 2022-03-28 13:53:01 +02:00
Damir Jelić
c50b369d72 fix(crypto): Remove some unwraps when creating inbound sessions 2022-03-28 13:48:18 +02:00
Julian Sparber
28893ec388 fix(store): Fix sync message order 2022-03-25 14:47:55 +01:00
Damir Jelić
6968edd704 feat(crypto): Start uploading fallback keys to the server 2022-03-25 13:11:53 +01:00
Damir Jelić
f4010b597f feat(crypto): Use a specialized SignedKey type instead of the Ruma type 2022-03-25 13:11:53 +01:00
Damir Jelić
2bacbf1b53 feat(crypto): Add a store error variant for breaking database format changes 2022-03-25 11:15:29 +01:00
Damir Jelić
0ce74b956c fix(sled): Throw an error if we can't upgrade our database 2022-03-25 11:15:29 +01:00
Damir Jelić
e2725483e4 refactor(crypto): Make it clear that olm decryption failures are normal 2022-03-25 11:15:29 +01:00
Damir Jelić
03990ab19e test(crypto): Improve the device saving test
The test didn't check if we can actually save/restore multiple devices,
this patch fixes this.
2022-03-25 11:15:29 +01:00
Damir Jelić
8b89023aff feat(indxeddb): Use the new store-cipher to encrypt our values 2022-03-25 11:15:29 +01:00
Damir Jelić
75de41bb2e feat(sled): Use the new store cipher to encrypt our keys and values 2022-03-25 11:15:29 +01:00
Damir Jelić
54e555f295 refactor(crypto): Don't use getrandom directly, we already use the rand crate 2022-03-25 11:15:29 +01:00
Damir Jelić
dbb500c4b8 feat(crypto): Switch to vodozemac for the olm/megolm support 2022-03-25 11:15:29 +01:00
Damir Jelić
61ca5c7aab fix(base): Make room invitations for previously-left rooms work 2022-03-24 12:35:08 +01:00
Jonas Platte
ae3b4f6640 Add a failing test for room invitations putting a left room back into invited 2022-03-24 12:21:21 +01:00
Jonas Platte
9ff6c1bc16 chore(base): Simplify BaseRoomInfo::handle_state_event 2022-03-23 14:25:14 +01:00
Jonas Platte
68a6655cb4 chore(base): Get rid of confusing double-as_ref 2022-03-23 14:25:14 +01:00
Alexandra
ec97c354e2 feat(sdk): Detect invalid .well-known endpoint response 2022-03-23 11:57:13 +01:00
Jonas Platte
db079065e4 refactor(sdk): Some cleanup of the HTTP code 2022-03-23 11:29:12 +01:00
Jonas Platte
cbebf8c4fe Don't import reqwest::Client
… to avoid confusion with the SDKs Client type.
2022-03-23 11:04:28 +01:00
Jonas Platte
92a532a4ba Inline single-use method HttpClient::send_request 2022-03-23 10:50:15 +01:00
Jonas Platte
4601b43651 Remove unnecessary specialized send-request method from HttpClient 2022-03-23 10:43:14 +01:00
Benjamin Kampmann
9ebabf818d Chore: Add tracing span to request sending 2022-03-21 20:45:22 +01:00
Jonas Platte
68385f0ff7 Add tracing span to request sending 2022-03-18 14:40:26 +01:00
Jonas Platte
3b1400b6f8 Merge pull request #539 from matrix-org/jplatte/cleanup 2022-03-17 14:44:30 +01:00
Jonas Platte
5b5e13fe2c Remove request field from Client::keys_upload tracing span
It results in a lot of log noise for initial syncs.
2022-03-17 14:26:28 +01:00
Jonas Platte
7b8568f5c8 Simplify get_or_upload_filter example 2022-03-17 14:24:50 +01:00
Jonas Platte
ea3ca1a8ca Remove unnecessary semicolons after if-let expressions 2022-03-17 14:23:55 +01:00
Jonas Platte
baa869552f Implement Default for SyncSettings in terms of SyncSettings::new
… rather than the other way around.
2022-03-17 14:23:11 +01:00
Jonas Platte
c9c31fa1c2 Simplify SyncSettings::default() 2022-03-17 14:22:40 +01:00
Jonas Platte
5ff38eff00 Activate tracing-subscriber's env-filter feature
This allows the log level of examples to be controlled using the
RUST_LOG environment variable.
2022-03-17 14:22:12 +01:00
Jonas Platte
f9420acdfd Remove unhelpful Client self fields from tracing spans
Client's Debug implementation just returns "Client".
2022-03-17 14:21:41 +01:00
Jonas Platte
c83f8f2a45 feat(sdk): Add convenience methods for getting state events of statically-known type 2022-03-16 14:26:18 +01:00
Damir Jelić
4741df627d feat(sdk): Add a method to check if the other side has scanned a qr verification 2022-03-16 14:23:35 +01:00
Julian Sparber
04e5434c9a QrVerification: Use consistent name for re-exported method 2022-03-16 14:06:26 +01:00
Julian Sparber
adf463a4be QrVerification: expose whether the QrCode was scanned by the other device 2022-03-16 13:05:15 +01:00
Damir Jelić
a455f23520 docs(store-cipher): Make the docs about the way the StoreCipher works clearer
Co-authored-by: Denis Kasak <dkasak@termina.org.uk>
2022-03-16 12:48:16 +01:00
Damir Jelić
3af08059da fix(store-cipher): Use the MacKeySeed type alias in more places
Co-authored-by: Denis Kasak <dkasak@termina.org.uk>
2022-03-16 12:48:16 +01:00
Damir Jelić
bf3d2ebea3 chore(store-cipher): Rename the store-key crate and it's main type 2022-03-16 12:48:16 +01:00
Damir Jelić
8ab7bfd5fa fix(store-key): Zeroize the derived MacKeys
Co-authored-by: Denis Kasak <dkasak@termina.org.uk>
2022-03-16 12:48:16 +01:00
Damir Jelić
d03eefc49a docs(store-key): Improve the docs a bit
Co-authored-by: Denis Kasak <dkasak@termina.org.uk>
2022-03-16 12:48:16 +01:00
Damir Jelić
5766b65eeb feat(store-key): Add a feature flag to enable WASM support 2022-03-16 12:48:16 +01:00
Damir Jelić
11d27007fc fix(store-key): Add some missing zeroize calls 2022-03-16 12:48:16 +01:00
Damir Jelić
4ed06be10d chore(store-key): Add more crate metadata
Co-authored-by: Benjamin Kampmann <ben.kampmann@gmail.com>
2022-03-16 12:48:16 +01:00
Damir Jelić
6a0bda47ae chore(store-key): Rename the crate
Co-authored-by: Benjamin Kampmann <ben.kampmann@gmail.com>
2022-03-16 12:48:16 +01:00
Damir Jelić
41466eae66 feat(store-key): Add a dedicated store key crate
This crate can be used to add at-rest encryption support for a
matrix-sdk state store or crypto store.
2022-03-16 12:48:16 +01:00
Damir Jelić
440b49ce5c feat(sdk): Add store specific errors to the ClientBuildError
This makes it easier to handle store specific errors while building a
Client as long as the user is using one of our main stores.
2022-03-16 12:29:10 +01:00