Jonas Platte
e246735866
test(sdk): Shorten some method names
2023-02-15 09:31:42 +01:00
Ivan Enderlin
6593f61556
doc(crypto-nodejs): Add safety comment for OlmMachine.close.
2023-02-15 09:15:31 +01:00
Jonas Platte
423d6ace83
fix(sdk): Attempt to EX-android crash with more hacks
2023-02-14 17:53:21 +01:00
Jonas Platte
ce315a5229
chore: Use fully-qualified Docker image names
...
This brings us closer to being able to use our Docker setup with podman too.
2023-02-14 10:19:06 +01:00
Jonas Platte
ca1163c9cc
test: Remove trailing spaces from docker-compose.yml
2023-02-14 10:19:06 +01:00
Jonas Platte
e576af8267
test: Fix docker-compose.yml error
...
Seems to be accepted by some older versions of docker-compose, but not
by current ones.
2023-02-14 10:19:06 +01:00
Jonas Platte
118497f9ec
test: Remove unused dependency
2023-02-13 16:59:45 +01:00
Jonas Platte
ac06172cf2
test(sdk): Add timeline items accessor
2023-02-13 16:21:30 +01:00
Damir Jelić
2654e909be
feat(store-encryption): Add support to export/import the cipher using a key
...
This is useful for platforms which might want to avoid the cost of
password based key-derivation and have the ability to securely store an
encryption key.
Co-authored-by: Denis Kasak <dkasak@termina.org.uk >
2023-02-13 14:08:45 +00:00
Damir Jelić
a1b1862479
docs(crypto): Explain a bit better what it means that a Device owns a room key
...
Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com >
2023-02-13 15:00:15 +01:00
Ivan Enderlin
5001cef372
Merge pull request #1375 from Hywan/feat-crypto-nodejs-requests-more-types
2023-02-13 14:46:47 +01:00
Kévin Commaille
a6f74fa22c
fix(sled): Use proper table name for encoding key when redacting
...
Contrary to other tables that use their own name to encode their keys,
the `ROOM_INFO` table uses the `ROOM` table name to encode its keys.
Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr >
2023-02-13 14:07:06 +01:00
Damir Jelić
56cfa8f4f9
fix(crypto): Always mark your own device as verified
2023-02-13 14:01:31 +01:00
Richard van der Hoff
8d642784bb
fix: remove dependency on broken wasm_timer crate
...
`wasm_timer` doesn't work outside the browser, which prevents it being used in
tests.
We can replace it with `gloo-timers` wich uses the standard Javascript
`setTimeout`.
2023-02-13 12:41:36 +01:00
enterprisey
e45bf9f9bd
docs(sdk): Improve read receipt/marker explanation
2023-02-13 12:05:35 +01:00
Jonas Platte
3a516a5fce
refactor(sqlite): Use internal Error in CryptoStore impl
2023-02-13 12:05:04 +01:00
Jonas Platte
9fc7d1c78b
refactor(indexeddb): Use IndexeddbCryptoStoreError in CryptoStore impl
2023-02-13 12:05:04 +01:00
Jonas Platte
c6f0e47077
refactor(crypto)!: Add an error type to the CryptoStore trait
...
This makes it easier to implement it. However, using a different error
type than CryptoStoreError is a non-trivial change, so left for the
coming commits for all stores except the memory store.
2023-02-13 12:05:04 +01:00
Kévin Commaille
96c796bb0e
ci: Silence clippy::extra_unused_type_parameters in affected crates
...
Triggers false positives.
See discussion in https://github.com/rust-lang/rust-clippy/issues/10319 .
Possibly fixed in https://github.com/rust-lang/rust-clippy/pull/10321 .
Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr >
2023-02-13 11:57:05 +01:00
Kévin Commaille
63fa645cea
fix(indexeddb): Fix implementation of SafeEncode for tuple of 5 elements
...
Regression introduced by merging commit 9707d73 after efdeba7
Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr >
2023-02-13 11:57:05 +01:00
Kévin Commaille
0d4fac5962
test(base): Test collision between threaded and unthreaded receipts in store
...
Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr >
2023-02-12 11:04:26 +01:00
Kévin Commaille
2e497198f8
fix(stores): Separate receipts by thread
...
The key encoding in key-value stores is backwards-compatible so
old receipts are counted as unthreaded receipts.
Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr >
2023-02-12 11:04:26 +01:00
Kévin Commaille
9707d73ead
fix(indexeddb): Fix broken raw redacted state events
...
A fix for (de)serialization of redacted state events in Ruma made
old events undeserializable.
Bump the DB version.
Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr >
2023-02-11 22:54:38 +01:00
Kévin Commaille
5ae84a9a80
fix(sled): Fix broken raw redacted state events
...
A fix for (de)serialization of redacted state events in Ruma made
old events undeserializable.
Bump the DB version.
Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr >
2023-02-11 22:54:38 +01:00
Jonas Platte
57c3224b6b
ci: Work around not being able to use matrix variables inside uses
2023-02-10 13:58:41 +01:00
Jonas Platte
4a5a0293a9
ci: Replace unmaintained actions-rs/cargo action
...
… we really didn't need it and can use run instead.
2023-02-10 13:58:41 +01:00
Jonas Platte
3f16b324d7
ci: Use taiki-e/install-action to install cargo-tarpaulin
2023-02-10 13:58:41 +01:00
Jonas Platte
a5bfab1d55
ci: Replace unmaintained actions-rs/toolchain action
...
… with dtolnay/rust-toolchain.
2023-02-10 13:58:41 +01:00
Jonas Platte
e430f65ce8
ci: Exclude Debug implementations from coverage reports
...
We don't really want to check for exact representations, and otherwise
they are really just invoked in tests that fail.
2023-02-10 13:46:00 +01:00
Jonas Platte
441626bf68
ci: Exclude uniffi-bindgen from coverage checks
2023-02-10 13:02:31 +01:00
Jonas Platte
02e51a9cb9
ci: Test sqlite crypto store in coverage check
2023-02-10 13:02:31 +01:00
Jonas Platte
4492df6fc6
test(sdk): Add a test for retrying edit decryption
2023-02-10 12:41:05 +01:00
Jonas Platte
573b672470
fix(sdk): Fix handling of UTD "insivible" events
...
(ones which don't produce a timeline item on their own)
2023-02-10 12:41:05 +01:00
Jonas Platte
fe3c73602f
refactor(sdk): Always add UTD events to the timeline
...
… as currently this is the only way decryption can be retried.
2023-02-10 12:41:05 +01:00
Jonas Platte
fd2dc18746
refactor(sdk): Retry event decryption in timeline item order
...
This works better for relations.
2023-02-10 12:41:05 +01:00
Jonas Platte
55549f61be
test(sdk): Split timeline tests into smaller modules
2023-02-10 12:41:05 +01:00
Jonas Platte
cf359dede5
chore: Upgrade rust-cache GitHub action
2023-02-10 12:16:06 +01:00
Ivan Enderlin
13f50fbf6c
fix(sdk): Remove Deref impl for SlidingSyncRoom
...
fix(sdk): Remove `Deref` impl for `SlidingSyncRoom`
2023-02-09 16:32:31 +01:00
Ivan Enderlin
0f7646ade1
chore: Make Clippy happy.
2023-02-09 16:16:31 +01:00
Ivan Enderlin
4e1fe3bec4
chore: Fix a function renaming.
2023-02-09 15:49:55 +01:00
Ivan Enderlin
c6d99305d5
fix(labs): Fix jack-in.
2023-02-09 15:46:08 +01:00
Ivan Enderlin
c86ebaddd2
Update crates/matrix-sdk/src/sliding_sync.rs
...
Co-authored-by: Jonas Platte <jplatte+git@posteo.de >
2023-02-09 15:36:13 +01:00
Benjamin Kampmann
048d6a774c
docs(sliding-sync): improved language
...
Co-authored-by: Ivan Enderlin <ivan@mnt.io >
2023-02-09 14:13:41 +01:00
Ivan Enderlin
43f2f60bfd
fix(sdk): Remove Deref impl for SlidingSyncRoom.
...
This implementation is wrong in the sense of its semantics is not about
dereferencing a thin pointer to something, but just to give access to one
specific field of the entire structure. That's not how `Deref` is supposed to
be used.
Moreover, it creates conflict between the `SlidingSyncRoom.timeline` field,
and `SlidingSyncRoom.inner.timeline` field, which both exist, but not for the
same purposes. It creates confusion in the code.
Finally, it's better to expose proper getters to the outside world, so that we
control _and_ test _and_ know exactly what API we provide.
2023-02-09 13:09:22 +01:00
Gabriel Féron
12cbff2688
refactor(sdk): Use spawn_blocking when generating attachment thumbnails
2023-02-09 09:54:43 +01:00
Jonas Platte
bdab40a772
refactor: Fix clippy lint str_to_string in sliding sync tests
2023-02-08 17:52:31 +01:00
Jonas Platte
87de9c7453
refactor(sled): Remove unused re-export
2023-02-08 17:52:31 +01:00
Benjamin Kampmann
765959758b
docs(sliding-sync): Document cold-cache, reactive-api and bot-mode
2023-02-08 16:54:06 +01:00
Jonas Platte
efdeba79f9
chore: Upgrade workspace dependencies
2023-02-08 16:04:29 +01:00
Jonas Platte
e25061f8cb
refactor(crypto)!: Unwrap unused Result
2023-02-08 16:04:29 +01:00