feat: gate first contact on a pinned server, confirm key changes
This commit is contained in:
parent
743c388cfb
commit
4c5665a6ff
5 changed files with 981 additions and 44 deletions
|
|
@ -39,6 +39,11 @@ fn plant(dir: &Path) -> Result<(), String> {
|
|||
let me = Account::new(master, 0).map_err(|e| e.to_string())?;
|
||||
let addr = Address::parse("demo@carrier.local").map_err(|e| e.to_string())?;
|
||||
store.set_account(&addr).map_err(|e| e.to_string())?;
|
||||
// Our own server is pinned, the contacts' server is not: the two
|
||||
// states the trust lines and the pin prompts distinguish.
|
||||
store
|
||||
.pin_server(&addr.host, addr.port, &identity(42).pk())
|
||||
.map_err(|e| e.to_string())?;
|
||||
|
||||
let pk = me.me().pk();
|
||||
let mut read_ids: Vec<String> = Vec::new();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue