Lior Yaffe: Introduction to Transaction Vouchers

wallet voucher exchange blockchain ardor

One of the most annoying and error prone aspects of crypto trading is the process of deposits and withdrawals from exchanges.

Take a look at this Bittrex deposit dialog for Ardor

Let’s think together about all the things which can go wrong when you send your precious Ardor tokens from your account to Bittrex.

  • You can mistype the account address — not a real risk since the account address has internal error correction.
  • You can forget to include the message or mistype it. Your funds will still go to Bittrex, but Bittrex won’t be able to credit your account, so expect a looooong discussion with their customer support team.
  • You may mistakenly deposit Ardor into an Ignis address or vice versa. Again, expect a looooong recovery process for your funds.
  • A deposit from another exchange to Bittrex or from Bittrex to another exchange may not specify a message, so it will get lost as well.
  • Even if your deposit does specify a message, some exchanges expect plain text messages while you may send it encrypted or vice versa.
  • But things can get much worse …

    6. What if instead of connecting to Bittrex.com, you were tricked into connecting to, say, Bitrex.com? Let’s assume for a moment it’s a phishing site aimed to steal your funds, if you don’t notice the difference you will happily deposit into the address they provide you, losing all your tokens.

    Exchange withdrawal process suffers from similar problems as well. For example, what if you withdraw your funds to a newly created account and then forget the passphrase? Say bye bye to your precious tokens.

    But even just sending crypto between friends or businesses is risky. When you email your account address and amount without any authentication, what if someone intercepts this email and changes the address or amount? Can we do better? Yes we can!

    Our Solution — Transaction Vouchers

    Think about transaction vouchers like an invoice. A request to pay a certain amount to a certain address signed by the private key of the recipient. The idea is based on the Bitcoin Payment Request proposal but using the rich functionality of Ardor/Ignis, we can do so much more.

    The voucher itself is a JSON format, composed of the transaction json, transaction bytes and a digital signature of the transaction bytes.

    Say, Alice wants Bob to pay her 100 IGNIS. She logs into the Ardor wallet using Bob’s account and sends payment as if she were Bob. Of course, she does not have Bob’s passphrase, so she cannot submit the transaction. Instead, she signs Bob’s payment using her passphrase and generates a voucher.

    Notice the Voucher checkbox

    Alice then downloads the voucher and emails it to Bob.

    The Voucher Generated by Alice

    Bob receives the voucher and loads it into the Ardor wallet. The Ardor wallet automatically verifies that the voucher signature is valid and that the voucher bytes are a correct representation of the voucher transaction JSON. After validation succeeds, the wallet presents Bob with the request, it shows Alice’s address as the recipient, the amount she wants him to pay, any attached messages and any other transaction parameters.

    Bob loads the voucher into his wallet

    All Bob needs to do is validate the data, sign, and submit the transaction using his passphrase.

    Bob is sure that the voucher is authentic, since any changes an attacker might have done to it, will prevent it from being validated by the wallet. Bob is also sure that Alice knows her account passphrase since otherwise she couldn’t have generated the voucher in the first place. Finally, both Alice and Bob now have a document for their bookkeeping, proving to each other and anyone else that the payment was requested.

    You can watch me demo the concept in this video from a workshop I ran recently in Norway.

    Now think about the Bittrex exchange deposit process. Instead of asking you to send tokens to an address with an attached message, Bittrex could generate a voucher file that you can import into the wallet which contains their deposit address and the message they want you to send them. Perhaps they will also let you scan a QR code with this data. All you’ll need to do, is load this voucher into your wallet, double check the recipient address with the well known Bittrex account, sign, and submit the transaction.

    But vouchers are not limited to payments. They can be used for any transaction type supported by Ignis. For example Bob wants to delegate a poll vote to Alice. Alice logs in as Bob and generates a voting voucher, then sends it to Bob by email and asks him to sign and submit it.

    Or, as another example, Charlie, a forging pool operator, wants Bob to lease his balance to his pool. Again he performs the leasing request on behalf of Bob, then sends a voucher that Bob needs to sign and submit.

    However, it’s important to note that vouchers do not depend on the wallet. Alice and Dave can generate the voucher using an API and Bob can validate and sign them using an API as well. All the processing can even be off loaded to lightweight contracts since vouchers can be used to trigger lightweight contracts and lightweight contracts can generate vouchers. More on this in my next article.

    Original article was created by: Lior Yaffe at medium.com

    Disclaimer: This article should not be taken as, and is not intended to provide, investment advice. Please conduct your own thorough research before investing in any cryptocurrency or ICO.

    Interested in Cryptocurrencies and ICO's?

    Follow our telegram channel for daily cryptomarket reports!

    Join @cointrends

    Stay on top of Altcoins and ICO trends.

    Subscribe to our free Weekly Cryptomarket report

    Delivered once a week, strongly to your inbox.

    Subscribe to our mailing list
    January 16, 2019

    Contracts in Action - Rewarding the Forgers

    After the hard fork last week at block 543,000 that enabled Ignis lightweight contracts on mainnet, Ardor 2.2.2 was released yesterday, 15 January 2019, with yet more features and optimizations. It’s time to put this amazing feature to work!For the foreseeable future, Jelurida will now use...

    From: IGNIS
    January 14, 2019

    Next Step - Advanced Cryptography

    Next Step - Advanced CryptographyScaling and Securing Blockchain TechnologyLior YaffeJan 14Over the past 12 Sunday mornings, I attended a Cryptography and Complexity course at the Technion, the Israeli MIT equivalence, delivered by cryptography professor Yuval Ishai, an old friend and one of the...

    From: IGNIS
    January 07, 2019

    Ignis is the first Ardor Child Chain

    Ignis is the first Ardor Child ChainIt has nothing to do with Ethereum/Plasma/SnarksLior YaffeJan 7Ignis — the first child chain of ArdorIgnis is the first child chain of Ardor and has been in production since 1/1/2018. It has already implemented most of the promises of...

    From: IGNIS
    December 17, 2018

    My Used Car Sale Experience

    My Used Car Sale ExperienceReflecting on Blockchain’s PotentialLior YaffeDec 17, 2018Used Car — Photo by Court Prather on UnsplashI finally decided to sell my used car. Selling a used car is never a simple task: I found a buyer who liked the car, he took it for...

    From: IGNIS
    December 10, 2018

    Investigating Long Range Attack

    Long Range — Photo by William Daigneault onUnsplashFor my dedicated readers, I guess you already know what I’m about to say about long-range attacks… but if you need more convincing, read on.Long-range attacks are a popular reason to discredit proof of stake algorithms together with...

    From: IGNIS
    December 02, 2018

    I like your idea but we still need to use the nonce counter otherwise we cannot generate more than…

    Lior YaffeDec 2, 2018I like your idea but we still need to use the nonce counter otherwise we cannot generate more than one secret per account per block height. To fix the problem of forks we can require that the block id is at least 720 blocks in the past. It is not really important which block...

    From: IGNIS
    Upcoming ICO's
    This week overview
    Token Name Starts
    Cryptocurrency rates
    *Last hour average price&change
    Coin Name Price Hour
    Bitcoin logo BTC $3563.65848033 0.07%
    Ripple logo XRP $0.3171080467 0.04%
    Ethereum logo ETH $116.957698769 -0.15%
    Bitcoin Cash logo BCH $122.339514784 0.63%
    EOS logo EOS $2.3488357632 0.18%
    Tether logo USDT $1.0131672655 0.14%
    Stellar logo XLM $0.1029606043 0.18%
    Litecoin logo LTC $31.0387314331 0.15%
    Tronix logo TRX $0.0258098587 0.54%
    Cardano logo ADA $0.0424387944 -0.15%
    Binance Coin logo BNB $6.473119591 0.34%
    IOTA logo IOT $0.2969679188 0.38%