Update 2.2. Manage contacts

This commit is contained in:
Sébastien Blin 2018-11-24 11:47:31 -05:00
parent 441aee1ceb
commit 92656a1b65
1 changed files with 15 additions and 2 deletions

View File

@ -60,8 +60,21 @@ dht_.get<DeviceAnnouncement>(to, [shared,to,treatedDevices,op](DeviceAnnouncemen
And that's all.
# Send a pending request
# Pending request
# Receiving a pending request
## Send a request
**TODO craft request**
Finally, once the trust request is crafted, we can push the request to the following hash: `InfoHash("inbox:" + deviceId)`
The following code is used in the daemon:
```cpp
dht_.putEncrypted(dht::InfoHash::get("inbox:"+dev.toString()), dev, dht::TrustRequest(DHT_TYPE_NS, payload));
```
## Receiving a request
**TODO**
(Accept/Block/Discard)