forked from SmartTokenLabs/TokenScript
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAttestedTransaction.html
More file actions
80 lines (78 loc) · 6.96 KB
/
AttestedTransaction.html
File metadata and controls
80 lines (78 loc) · 6.96 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
<!DOCTYPE html
SYSTEM "about:legacy-compat">
<html lang="en"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"><meta name="copyright" content="(C) Copyright 2020"><meta name="DC.rights.owner" content="(C) Copyright 2020"><meta name="DC.type" content="concept"><meta name="description" content="With an attestation, a user can send an attested transaction"><meta name="DC.format" content="HTML5"><meta name="DC.identifier" content="concept_qhc_wrn_qmb"><link rel="stylesheet" type="text/css" href="css/commonltr.css"><link rel="stylesheet" type="text/css" href="css/custom.css"><title>Attested Transaction</title>
<link href="https://fonts.googleapis.com/css?family=Roboto+Slab|Lato">
<script type="text/javascript" src="https://alphawallet.com/wp-content/themes/alphawallet/discourse/widget.js"></script>
</head><body id="concept_qhc_wrn_qmb"><header role="banner"><nav class="navbar navbar-expand-lg navbar-dark bg-dark mb-4">
<div class="container">
<a class="navbar-brand" href="/">🆃okenScript</a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarSupportedContent">
<ul class="navbar-nav mr-auto">
<li class="nav-item"><a class="nav-link" href="/TokenScript.html">Documents</a></li>
<li class="nav-item"><a class="nav-link" href="/guides/Intro.html">Guides</a></li>
<li class="nav-item"><a class="nav-link" href="/specs/Intro.html">Specs</a></li>
<li class="nav-item external"><a class="nav-link" href="">TokenScript community forum</a></li>
<li class="nav-item external"><a class="nav-link" href="/TokenScript.html">AlphaWallet (uses TokenScript)</a></li>
<li class="nav-item external"><a class="nav-link" href="/guides/Intro.html">Github TokenScript</a></li>
<li class="nav-item external"><a class="nav-link" href="/specs/Intro.html">Github TokenScript Examples</a></li>
</ul>
</div>
</div>
</nav></header><div class="container" id="content"><div class="row"><nav role="toc" class="col-lg-3"><ul></ul></nav><main role="main" class="col-lg-9"><article role="article" aria-labelledby="ariaid-title1">
<h1 class="title topictitle1" id="ariaid-title1">Attested Transaction</h1>
<div class="body conbody"><p class="shortdesc">With an attestation, a user can send an attested transaction</p>
<p class="p">An attested transaction is one that uses an attestation to prove something that the
receiving Smart Contract can validate.</p>
<p class="p">Examples are:</p>
<ul class="ul" id="concept_qhc_wrn_qmb__ul_zxz_zrn_qmb">
<li class="li">In an ICO purchase is limited to residents of certain countries. To participate, one
has to send an attested transaction that attests to his residency country. The Smart
Contract would revert the transaction if the residency country isn't allowed.</li>
<li class="li">Similarly, one can send an attested transaction that proves the sender is above the
legal age without giving away the actual age.</li>
<li class="li">If you have a Devcon ticket as an attestation, you can participate a smart contract
vote as a valid Devcon ticket holder, without first converting such a ticket to a
Non-Fungible Token.</li>
<li class="li">If you purchase prescription medicine from a Smart Contract, you can send an
attested transaction that you have a prescription for it, if the prescription was
issued to you as an attestation.</li>
<li class="li">If you are authorised to draw x amount of money from a line of credit or someone's
wallet, that authorisation is provided as an attestation, and you draw the money by
creating an attested transaction using it.</li>
</ul>
<p class="p">Since data on the blockchain is publically available, attested transactions often need to
use certain cryptographic proofs for privacy protection.</p>
<p class="p">For a person who proves his residency country, he should not reveal his national ID card
number to the blockchain, or risk all his transactions are associated by an observer of
the blockchain data.</p>
<p class="p">The TokenScript team produced one of such prove mechanism in a paper <a class="xref" href="https://github.com/AlphaWallet/blockchain-attestation/releases" target="_blank" rel="external noopener">on Ethereum attestation in 2018</a>.</p>
<section class="section"><h2 class="title sectiontitle">Alternative to attested transaction</h2><p class="p">If an 3rd party exists between the sender of the transaction and the smart contract which can
assume accountability and confidentiality, you may use a white-list approach instead
of attested transaction. Indeed, it was the model used by almost all 2017 ICO
projects with KYC requirements.</p>
<p class="p">The process would be like this:</p>
<ol class="ol" id="concept_qhc_wrn_qmb__ol_qmw_qvn_qmb">
<li class="li">The sender of the transaction visits the confidential 3rd party's website,
providing his Ethereum address and his identity, e.g. by taking a photo holding
his passport and upload it.</li>
<li class="li">The 3rd party verifies the identity and put the Ethereum address into a
whitelist by updating the Smart Contract.</li>
<li class="li">The sender now sends a purchase transaction to that Smart Contract and is
allowed to purchase.</li>
</ol>
<p class="p">Compared with Attested Transaction, this method requires confidentiality and accountability
from the 3rd party, meaning that they should do their best to protect the sender's
identity. The best way to protect the privacy is to discard the private data, yet,
for accountability reasons, they need to show that they have done KYC probably,
therefore can't discard the private data.</p>
<p class="p">With Attested Transaction, a smart contract would revert if the sender fails to meet
the criteria, therefore doing away the responsibility of the 3rd party
altogether.</p>
<p class="p">Also, third party whitelists are not as easily reusable as attestations. If you have
a country residence attestation or a legal age attestation, you can reuse it for as
many transactions as you like.</p></section>
</div>
</article></main></div></div></body></html>