Encrypt content sent to the server
This implements client-side encryption, so that users' task information is not availble to the server (or to anyone who does not have the `encryption_secret`).
This commit is contained in:
@@ -16,8 +16,10 @@ pub use types::*;
|
||||
pub fn from_config(config: ServerConfig) -> Fallible<Box<dyn Server>> {
|
||||
Ok(match config {
|
||||
ServerConfig::Local { server_dir } => Box::new(LocalServer::new(server_dir)?),
|
||||
ServerConfig::Remote { origin, client_id } => {
|
||||
Box::new(RemoteServer::new(origin, client_id))
|
||||
}
|
||||
ServerConfig::Remote {
|
||||
origin,
|
||||
client_id,
|
||||
encryption_secret,
|
||||
} => Box::new(RemoteServer::new(origin, client_id, encryption_secret)),
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user