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
Kévin Commaille
7b8c52b043
indexeddb: Move attribute below docs
2022-03-16 10:30:56 +01:00
Kévin Commaille
3a94c2115f
sdk: Add store opening errors to ClientBuildError
2022-03-15 14:43:02 +01:00
Kévin Commaille
6785c07793
indexeddb: Make store opening error more specific
2022-03-15 14:43:02 +01:00
Kévin Commaille
e23b22857f
sled: Make store opening error more specific
2022-03-15 14:42:54 +01:00
Jonas Platte
3bf5388da0
feat(sdk): Fetch supported matrix versions from server in initialization
2022-03-14 15:23:13 +01:00
Jonas Platte
15df8fef95
Fix broken tests
2022-03-14 15:08:54 +01:00
Jonas Platte
8df7e1cc8b
Fix hanging tests
2022-03-14 15:08:48 +01:00
Jonas Platte
7b2dfa39cf
Remove Client::get_supported_versions
...
This is now always done as part of constructing the Client, unless the
user actively opted out.
2022-03-14 12:57:58 +01:00
Jonas Platte
fdc8f79728
Merge branch 'main' into jplatte/server-versions
2022-03-14 12:56:57 +01:00
Benjamin Kampmann
f76bcda64f
feat(client): Replacing ClientConfig with a ClientBuilder to configure how the client will be set up
...
Merge pull request #533 from matrix-org/jplatte/client-builder
2022-03-14 12:43:38 +01:00
Jonas Platte
718fa18e7f
Merge branch 'main' into jplatte/client-builder
2022-03-14 11:26:45 +01:00
Damir Jelić
b8b61ce214
refactor(sdk): Scope the encryption specific Client methods behind a struct
2022-03-14 10:16:19 +01:00
Jonas Platte
a2ad774112
Add ClientBuilder::server_name
2022-03-14 10:02:31 +01:00
Jonas Platte
d94ba8c64f
Remove Client::for_user_id
2022-03-14 10:02:31 +01:00
Jonas Platte
81d07d886c
Rename Client::{new_from_user_id => for_user_id}
2022-03-13 19:56:26 +01:00
Jonas Platte
147e948fe6
Replace ClientConfig with ClientBuilder
...
This includes a few not-strictly-related changes that made sense to do at the
same time:
* Check for a functioning homeserver via get_supported_versions regardless of
whether a homeserver URL or user ID was supplied
* Rename use_discovery_response to respect_login_well_known
* Small appservice documentation improvement because those docs had to be
touched anyways
* Some test refactorings in tests that had to be touched anyways
2022-03-13 19:56:26 +01:00
Kévin Commaille
d8c7fbd9dc
sdk: Create Encryption struct
...
Lower the API surface of Client
2022-03-12 13:30:55 +01:00
Jonas Platte
bd7fbea155
Fix intra-doc link
2022-03-11 18:04:32 +01:00
Jonas Platte
628e2fb716
Allow configuring assert_identity on the client level only
...
Completely removing it from RequestConfig is left up to a future refactoring.
2022-03-11 15:31:11 +01:00
Jonas Platte
503f4d73a0
Merge pull request #532 from matrix-org/jplatte/ctors
2022-03-11 13:05:20 +01:00
Jonas Platte
8a927df2b3
Rename PrivateCrossSigningIdentity::{new_with_account => with_account}
2022-03-11 12:48:30 +01:00
Jonas Platte
14ddcfb06e
Remove new_ prefix from ToDeviceRequest ctors
2022-03-11 12:48:30 +01:00
Jonas Platte
932ef6270b
Remove new_ prefix from OlmMachine ctors
2022-03-11 12:48:30 +01:00
Jonas Platte
1be68f57a5
Merge BaseClient impl blocks
2022-03-11 12:36:08 +01:00
Jonas Platte
cfdf4a032e
Rename BaseClient::{new_with_store_config => with_store_config}
2022-03-11 12:36:08 +01:00
Jonas Platte
f5a7a1bcf0
Rename AppService::{new_with_config => with_config}
2022-03-11 12:36:08 +01:00
Jonas Platte
e60b07336d
Rename Client::{new_with_config => with_config}
2022-03-11 12:36:08 +01:00
Jonas Platte
48660c482f
Use regular builder pattern for ClientConfig::store_config
2022-03-11 12:36:00 +01:00
Jonas Platte
27ee7c32ca
Remove new_with_* constructors for StoreConfig
...
The regular builder pattern works just fine for the stores.
2022-03-11 11:49:01 +01:00
Benjamin Kampmann
88f1552a70
feat(stores): Improve Store initialisation to allow for reusing the same instance
...
Merge pull request #523 from zecakeh/stores
2022-03-11 11:40:12 +01:00
Kévin Commaille
faa5cf54eb
indexeddb: Make make_store_config public
2022-03-10 17:42:37 +01:00
Kévin Commaille
2bdc754140
ci: Lint matrix-sdk-crypto with a separate command
2022-03-10 17:29:20 +01:00
Kévin Commaille
597999acba
sdk-base: Add constructors with stores for StoreConfig
2022-03-10 17:29:19 +01:00
Kévin Commaille
81605b731d
sdk-base: Fix wording on StoreConfig docs
2022-03-10 17:29:19 +01:00
Kévin Commaille
d7673257b4
stores: Rename make_config to make_store_config
2022-03-10 17:29:19 +01:00
Kévin Commaille
54c8b4f8bb
sdk-base: Remove BaseClientConfig
2022-03-10 17:29:15 +01:00
Kévin Commaille
ad31540b10
sdk: Don't enable store encryption by default
2022-03-10 17:28:34 +01:00
Kévin Commaille
8c7bbb0e07
sdk: Update store setup instructions for encryption.
2022-03-10 17:22:36 +01:00
Kévin Commaille
0f60dfcfc5
sdk: Re-export stores and store config
2022-03-10 17:15:18 +01:00
Kévin Commaille
0327b4f8fc
indexeddb: Add methods to create a StoreConfig
2022-03-10 17:15:18 +01:00
Kévin Commaille
4b7f05e913
sled: Add a method to create a StoreConfig
2022-03-10 17:15:18 +01:00
Kévin Commaille
0ea12b3b4a
base: Separate store config from the client config
2022-03-10 17:15:18 +01:00
Kévin Commaille
28a83da421
sdk: Remove default store constructors
2022-03-10 17:15:14 +01:00