[bisq-network/bisq] Sign account usage (#2768)
Manfred Karrer
notifications at github.com
Sat Apr 27 20:49:50 UTC 2019
ManfredKarrer commented on this pull request.
> + public Set<SignedWitness> getTrustedPeerSignedWitnessSet(AccountAgeWitness accountAgeWitness) {
+ return signedWitnessMap.values().stream()
+ .filter(e -> !e.isSignedByArbitrator())
+ .filter(e -> Arrays.equals(e.getWitnessHash(), accountAgeWitness.getHash()))
+ .collect(Collectors.toSet());
+ }
+
+ // We go one level up by using the signer Key to lookup for SignedWitness objects which contain the signerKey as
+ // witnessOwnerPubKey
+ public Set<SignedWitness> getSignedWitnessSetBySignerPubKey(byte[] signerPubKey) {
+ return signedWitnessMap.values().stream()
+ .filter(e -> Arrays.equals(e.getWitnessOwnerPubKey(), signerPubKey))
+ .collect(Collectors.toSet());
+ }
+
+ public boolean isValidAccountAgeWitness(AccountAgeWitness accountAgeWitness) {
I think we need to pass through the list and remove items once processed.
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/bisq-network/bisq/pull/2768#discussion_r279168005
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.bisq.network/pipermail/bisq-github/attachments/20190427/637773fc/attachment-0001.html>
More information about the bisq-github
mailing list