mirror of
https://github.com/haveno-dex/haveno.git
synced 2025-08-09 07:02:24 -04:00
minimum support for account witness verification & storage based on bisq
verify peer witness data and share with arbitrator for signing arbitrator can sign witness hash, owner pub key (see developer-guide.md) taker signs offer id nonce in SendOfferAvailabilityRequest maker signs deposit tx hash in SendSignContractRequest buyer verifies witness with payload on deposit confirmation seller verifies witness with payload on payment sent message add synchronization to User paymentAccountsAsObservable and elsewhere
This commit is contained in:
parent
963d92478d
commit
646380bc7a
28 changed files with 210 additions and 98 deletions
|
@ -523,7 +523,7 @@ public class PopOver extends PopupControl {
|
|||
skinNode);
|
||||
fadeOut.setFromValue(skinNode.getOpacity());
|
||||
fadeOut.setToValue(0);
|
||||
fadeOut.setOnFinished(evt -> super.hide());
|
||||
fadeOut.setOnFinished(evt -> { if (super.isShowing()) super.hide(); });
|
||||
fadeOut.play();
|
||||
} else {
|
||||
super.hide();
|
||||
|
|
|
@ -200,9 +200,7 @@ public class SignPaymentAccountsWindow extends Overlay<SignPaymentAccountsWindow
|
|||
++rowIndex, Res.get("popup.accountSigning.confirmSelectedAccounts.headline"));
|
||||
GridPane.setRowSpan(selectedPaymentAccountsTuple.third, 2);
|
||||
selectedPaymentAccountsList = selectedPaymentAccountsTuple.second;
|
||||
ObservableList<Dispute> disputesAsObservableList = useDevPrivilegeKeys ?
|
||||
mediationManager.getDisputesAsObservableList()
|
||||
: arbitrationManager.getDisputesAsObservableList();
|
||||
ObservableList<Dispute> disputesAsObservableList = arbitrationManager.getDisputesAsObservableList();
|
||||
long safeDate = datePicker.getValue().atStartOfDay().toEpochSecond(ZoneOffset.UTC) * 1000;
|
||||
List<TraderDataItem> traderDataItemList;
|
||||
StringBuilder sb = new StringBuilder("Summary for ").append(appName).append("\n");
|
||||
|
|
|
@ -43,6 +43,7 @@ import bisq.network.p2p.NodeAddress;
|
|||
|
||||
import bisq.common.UserThread;
|
||||
import bisq.common.util.Tuple3;
|
||||
import bisq.common.util.Utilities;
|
||||
|
||||
import javax.inject.Inject;
|
||||
import javax.inject.Named;
|
||||
|
@ -313,6 +314,11 @@ public class TradeDetailsWindow extends Overlay<TradeDetailsWindow> {
|
|||
HBox.setHgrow(spacer, Priority.ALWAYS);
|
||||
hBox.getChildren().add(0, spacer);
|
||||
|
||||
String buyerWitnessHash = trade.getBuyer().getAccountAgeWitness() == null ? "null" : Utilities.bytesAsHexString(trade.getBuyer().getAccountAgeWitness().getHash());
|
||||
String buyerPubKeyRingHash = Utilities.bytesAsHexString(trade.getBuyer().getPubKeyRing().getSignaturePubKeyBytes());
|
||||
String sellerWitnessHash = trade.getSeller().getAccountAgeWitness() == null ? "null" : Utilities.bytesAsHexString(trade.getSeller().getAccountAgeWitness().getHash());
|
||||
String sellerPubKeyRingHash = Utilities.bytesAsHexString(trade.getSeller().getPubKeyRing().getSignaturePubKeyBytes());
|
||||
|
||||
if (contract != null) {
|
||||
viewContractButton.setOnAction(e -> {
|
||||
TextArea textArea = new HavenoTextArea();
|
||||
|
@ -321,8 +327,10 @@ public class TradeDetailsWindow extends Overlay<TradeDetailsWindow> {
|
|||
data += trade.getContractAsJson();
|
||||
data += "\n\nOther detail data:";
|
||||
if (offer.isFiatOffer()) {
|
||||
data += "\n\nBuyersAccountAge: " + buyersAccountAge;
|
||||
data += "\nSellersAccountAge: " + sellersAccountAge;
|
||||
data += "\n\nBuyers witness hash,pub key ring hash: " + buyerWitnessHash + "," + buyerPubKeyRingHash;
|
||||
data += "\nBuyers account age: " + buyersAccountAge;
|
||||
data += "\nSellers witness hash,pub key ring hash: " + sellerWitnessHash + "," + sellerPubKeyRingHash;
|
||||
data += "\nSellers account age: " + sellersAccountAge;
|
||||
}
|
||||
|
||||
// TODO (woodser): include maker and taker deposit tx hex in contract?
|
||||
|
|
|
@ -448,7 +448,7 @@ public class SellerStep3View extends TradeStepView {
|
|||
}
|
||||
|
||||
if (model.dataModel.isSignWitnessTrade()) {
|
||||
message += Res.get("portfolio.pending.step3_seller.onPaymentReceived.signer");
|
||||
message += "\n\n" + Res.get("portfolio.pending.step3_seller.onPaymentReceived.signer");
|
||||
}
|
||||
}
|
||||
if (!DevEnv.isDevMode() && DontShowAgainLookup.showAgain(key)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue