Skip to main content

fetch_keys

Function fetch_keys 

Source
pub fn fetch_keys<T>(
    addresses: &[(String, u16)],
    code: &JoinCode,
    request: &KeyRequest,
    take: impl FnOnce(&KeyHandover) -> Result<T>,
) -> Result<(T, Option<String>)>
Expand description

Dials a device running sb pair --restore-keys, proves code and hands the epochs it sends to take, whose outcome that device is told. It returns what take made of them and why the final ack failed, if it did.