mirror of
https://github.com/fluencelabs/examples
synced 2024-12-04 19:20:17 +00:00
init aqua
This commit is contained in:
parent
0c3c62e49a
commit
7cbe4a5ceb
@ -77,15 +77,17 @@ func verify(addr: ServiceAddress, pk: string, round_idx:u64, prev_signature: str
|
||||
<- res
|
||||
|
||||
--
|
||||
func roundtrip(addrs: []ServiceAddress, url:string, chain_hash: string) -> bool, string, string:
|
||||
func roundtrip(addrs: []ServiceAddress, url:string) -> bool, string, string:
|
||||
on addrs[0].peer_id:
|
||||
Drand addrs[0].service_id
|
||||
c_res <- Drand.chains(url)
|
||||
i_res <- Drand.info(url, c_res.chains[0])
|
||||
r_res <- Drand.latest(url, c_res.chains[0])
|
||||
|
||||
-- <- true, "yes", "no"
|
||||
on addrs[1].peer_id:
|
||||
Drand addrs[1].service_id
|
||||
v_res <- Drand.verify_bls(i_res.info.public_key, r_res.randomness.round, r_res.randomness.previous_signature, r_res.randomness.signature)
|
||||
|
||||
<- v_res.verified, v_res.randomness, r_res.randomness.randomness
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user