From 4596740b52a1e0d0fa2e48e6454a58eddb8d4c14 Mon Sep 17 00:00:00 2001 From: vorujack Date: Sat, 21 Jan 2023 23:50:30 +0330 Subject: [PATCH 1/6] add eip-0042 multi-signature wallet --- README.md | 3 +- eip-0042.md | 171 +++++++++++++++++++++++++++++++++++++++++++++ eip-0042/bytes.png | Bin 0 -> 9849 bytes 3 files changed, 173 insertions(+), 1 deletion(-) create mode 100644 eip-0042.md create mode 100644 eip-0042/bytes.png diff --git a/README.md b/README.md index b8907a9d..196c9f5e 100644 --- a/README.md +++ b/README.md @@ -21,4 +21,5 @@ Please check out existing EIPs, such as [EIP-1](eip-0001.md), to understand the | [EIP-0025](eip-0025.md) | Payment Request URI | | [EIP-0027](eip-0027.md) | Emission Retargeting Soft-Fork | | [EIP-0031](eip-0031.md) | Babel Fees | -| [EIP-0039](eip-0039.md) | Monotonic box creation height rule | \ No newline at end of file +| [EIP-0039](eip-0039.md) | Monotonic box creation height rule | +| [EIP-0042](eip-0042.md) | Multi-Signature Wallet | diff --git a/eip-0042.md b/eip-0042.md new file mode 100644 index 00000000..c10c55f4 --- /dev/null +++ b/eip-0042.md @@ -0,0 +1,171 @@ +# EIP-41: Multi-Signature Wallet + +- Author: lazypinkpatrick, vorujack, mhs_sam +- Status: Completed +- Created: 21-Jan-2023 +- License: MIT +- Forking: not needed + +This EIP defines a standard for multi-signature wallets based on EIP-11, which defines the multi-signature signing process. + +## Introduction + +On top of EIP-11, this EIP implements the following additional operations: + +* Wallet creation and address derivation. +* Transaction signing based on EIP-11. + +## Wallet Creation and Address Derivation + +These parameters define an `N-out-of-M` multi-signature wallet: + +* `M`: number of public keys. +* `N`: minimum signature required. + +Each signer stores the set of extended public keys of all signers and a local copy of their secret. + +An address is derived for each signer using their extended public key over a specified derivation path. The list of derived addresses for all signers is then used to compile a multi-sig contract that looks like this: + +``` +atLeast( + N, + Coll( + PK(Address1), + PK(Address2), + . + . + . + PK(AddressM) + ) +) +``` + +Please note, this contract results in different addresses when the order of signers differs. + +We must guarantee that all signers will have a unique and reproducible multi-signature wallet address. To do so, we use the same derivation path and sort the byte array of public keys in ascending order. + +Then we will manually create the ErgoTree; since using the compiler could cause the resulting address to vary. + +The address derivation algorithm is as follows: + +Sort the list of signers' public keys before being used in the contract. +Create the required ergoTree array as follows: + +- The first byte in the array is `10`. +- The number of constant values in the contract is encoded as a variable-length quantity (VLQ). + This number equals `M+1` (Constant `N` and `M` public keys) +- A byte with value `04` denotes the integer type,followed by the value of `N` encoded as VLQ. +- For each public key 35 bytes are used: 2 bytes with value `08cd`, followed by 33 bytes representing the public key. +- A byte with the value `98` indicates **"atLeast"**. +- Two bytes, with values `73` and `00`, respectively. + The value `00` indicates the VLQ-encoded index of value `N` in the list of constants. +- A constant byte with value `83`, the VLQ-encoded value of `M`, and a constant byte with value `08` +- For each public key (`M` times), a byte with value `73`,followed by the VLQ-encoded value of the index of the public key in the list of constants + +Therefore, for each derivation path, all wallets are able to generate a unique and similar byte array as an ErgoTree. + +![Ergo Tree Bytes](./eip-0042/bytes.png) + +## Transaction Signing + +An unsigned transaction is generated on one wallet. This transaction may have been generated through ErgoPay or the dApp connector, or it could be an outgoing transaction to another address through the wallet itself. + +After an unsigned transaction is generated, the wallet + +Generates a commitment. +Stores its private part locally. +Shares a commitment as below + +``` +{ + tx:, + boxes:[encoded boxes as base64], + commitment: commitments encoded +} +``` + +The input `boxes:` are only used to display transactions on wallets. + +The general commitment format is as follows. However, this general-purpose commitment can be used for any contract. +``` +{ + "hint": "cmtReal", + "position": "0-0", + "type": "dlog", + "pubkey": { + "op": "205", + "h": "03a73c66970f14fc6450c6ab1a167cb4ba3baa64b20f731e22ec6840c70d27ef1c", + } + "a": "0253db866791af521ba4ab009509b6db89d272d9461636ee65eaa3e316884b21a4" +} +``` + +In a multi-signature wallet, a simplified version of commitment is used. + +``` +commitments: [, ...] +``` + +In the multi-signature wallet, a commitment is represented as a list of base64 strings to reduce the commitment size. Also, an empty string is used wherever a commitment is unavailable. + +[//]: # (and we can transform these commitments to standard format:) +This reduced format can be transformed into the standard format: + +``` +{ + "hint": "cmtReal", + "position": "0-", + "type": "dlog", + "pubkey": { + "op": "205", + "h": "" + }, + "a": "" +} +``` + +[//]: # (Because wallets want to pass this code via QRCode, each wallet can split it into chunks) + +To transfer these commitments using QRCode, we can split the data into several chunks: + +``` +{ + MSR: "{\"tx\": ...}", + n: + p: +} +``` + +This data is transferred between multi-signature wallets until one wallet has at least `N` commitments (including its own). + +This wallet creates a partially signed transaction with this encoding: + +``` +{ + partialTx: "", + commitments: + signed: [], + simulated: [], +} +``` + +It can also be transferred using QRCode in several chunks: + +``` +{ + MTX: "{\"partialTx\": ... }", + n: + p: +} +``` + +The first signer creates a list of simulated signers, and other signers use this list. + +Each signer: +Signs the partially signed transaction (if they still need to). +Adds their public key to the list. +Shares the data with the next signer. + +The transaction will be broadcasted whenever the signer determines that the transaction has enough signatures. + + diff --git a/eip-0042/bytes.png b/eip-0042/bytes.png new file mode 100644 index 0000000000000000000000000000000000000000..60a86c69dafc2727cfd12919e95b9bfab8a87099 GIT binary patch literal 9849 zcmd6NcT`kMv+qU}6$z3ggJcIpBn&~4{&ogx$Nl>Q~iW-Br~UrmQH1jY)g-_O6!gX!rQ9B*P)XB#i#i`K$>jODP-8P8#6+to zE}1^<`P1{>+nSRZ?~)qfAx~ubKxFd~1Oz3I$3+DIMyXl*;KTUssJj4=%xEP50PS2N zNHhS*yHAD-0M8XhJOJR0_1i9Va0tQwXo&98*47pZRZoat*!+4^b2l5izPUMpr=`Eu zWp!wM{nI87(o7LTpHLF4hKa7dd>8ofB5Ob7Z4E1lh{~kKh(VMg{RKH^W!L6f>;>^D z8c>g8b&(xgqtMfu*IZ)8LdJ%BpoTeTWEMr;Ln{mbQ)p4bgv?RHIkXw$H1Wc>)8X(Y z)p}LwM%jtx02UWHE!kz+)Af+BdB#n{PpLdbTn3~cOnnt$SCtIYg~bU_%gyW+&$S5; z%0ZP^pDa#ugEs^RX6S{mS!unje0GxKofV9PIn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7fOG!zA8>NSD z2d}~!jsc|i$<5jY3qO(ti|VpuXBm!hsRZ_T`lBTg`|i7o3+L}{zqx+{LVlLBF=X)^ zKD@4(DZGUKhfj46AE+DfCIK9NiF;)-NSzjQEq65WeFy@dt8+Z`J_4q|YLhpXZN?{i zOJc&M!jvZ`3x&Jwd_qDW+Rvu|G$T`RtViB{qxYoXZ`5@>2H=JUriH88GR8B0pPqVN zyzni!O8!FN?c4K218~Cr!$~Ril=DDu|J~_6)FAsvrPKOeYcbW2Gf->K#ZLBf2qmT5 z_wZ36xYQerS3?>6jWKP$=e2Fx!~i!22!=}XstGF7)b_iJ42}&jA8tVmCPqDmFAX z|1LZ4jh%+4r%P}7-usKmjIeE4tCK}FzXvc)3C>7$&)2VC!Qo&P0rxEs1S7Ao@QEXk z93LN#M4FQBGo1tF&%l0L@cw=||J|rN2B0)kcfp>Q1Z`T>uC{;?c(Ddd3u|dKkjT&@lmz>q^=?ndR8E`EN`0)&NxGA|h~52erl z#p5`}zqd50s;X-29x(a;vNj5=zzX*{Tfe>wF}Qs0H1iA!7GnW25{lxbqDF831LCDL A!T Date: Fri, 24 Feb 2023 13:25:27 +0330 Subject: [PATCH 2/6] update commitment format --- eip-0042.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/eip-0042.md b/eip-0042.md index c10c55f4..19e18e32 100644 --- a/eip-0042.md +++ b/eip-0042.md @@ -103,7 +103,10 @@ The general commitment format is as follows. However, this general-purpose commi In a multi-signature wallet, a simplified version of commitment is used. ``` -commitments: [, ...] +commitments: [ + [, ...] + [, ...] +] ``` In the multi-signature wallet, a commitment is represented as a list of base64 strings to reduce the commitment size. Also, an empty string is used wherever a commitment is unavailable. From d89ff5656abec7d99e232b64fb630e22239a6a95 Mon Sep 17 00:00:00 2001 From: vorujack Date: Sat, 21 Jan 2023 23:50:30 +0330 Subject: [PATCH 3/6] add eip-0042 multi-signature wallet --- README.md | 3 +- eip-0042.md | 171 +++++++++++++++++++++++++++++++++++++++++++++ eip-0042/bytes.png | Bin 0 -> 9849 bytes 3 files changed, 173 insertions(+), 1 deletion(-) create mode 100644 eip-0042.md create mode 100644 eip-0042/bytes.png diff --git a/README.md b/README.md index b331248b..42009d13 100644 --- a/README.md +++ b/README.md @@ -23,4 +23,5 @@ Please check out existing EIPs, such as [EIP-1](eip-0001.md), to understand the | [EIP-0031](eip-0031.md) | Babel Fees | | [EIP-0034](eip-0034.md) | NFT Collection Standard | | [EIP-0039](eip-0039.md) | Monotonic box creation height rule | -| [EIP-0043](eip-0043.md) | Reduced Transaction | \ No newline at end of file +| [EIP-0042](eip-0042.md) | Multi-Signature Wallet | +| [EIP-0043](eip-0043.md) | Reduced Transaction | diff --git a/eip-0042.md b/eip-0042.md new file mode 100644 index 00000000..c10c55f4 --- /dev/null +++ b/eip-0042.md @@ -0,0 +1,171 @@ +# EIP-41: Multi-Signature Wallet + +- Author: lazypinkpatrick, vorujack, mhs_sam +- Status: Completed +- Created: 21-Jan-2023 +- License: MIT +- Forking: not needed + +This EIP defines a standard for multi-signature wallets based on EIP-11, which defines the multi-signature signing process. + +## Introduction + +On top of EIP-11, this EIP implements the following additional operations: + +* Wallet creation and address derivation. +* Transaction signing based on EIP-11. + +## Wallet Creation and Address Derivation + +These parameters define an `N-out-of-M` multi-signature wallet: + +* `M`: number of public keys. +* `N`: minimum signature required. + +Each signer stores the set of extended public keys of all signers and a local copy of their secret. + +An address is derived for each signer using their extended public key over a specified derivation path. The list of derived addresses for all signers is then used to compile a multi-sig contract that looks like this: + +``` +atLeast( + N, + Coll( + PK(Address1), + PK(Address2), + . + . + . + PK(AddressM) + ) +) +``` + +Please note, this contract results in different addresses when the order of signers differs. + +We must guarantee that all signers will have a unique and reproducible multi-signature wallet address. To do so, we use the same derivation path and sort the byte array of public keys in ascending order. + +Then we will manually create the ErgoTree; since using the compiler could cause the resulting address to vary. + +The address derivation algorithm is as follows: + +Sort the list of signers' public keys before being used in the contract. +Create the required ergoTree array as follows: + +- The first byte in the array is `10`. +- The number of constant values in the contract is encoded as a variable-length quantity (VLQ). + This number equals `M+1` (Constant `N` and `M` public keys) +- A byte with value `04` denotes the integer type,followed by the value of `N` encoded as VLQ. +- For each public key 35 bytes are used: 2 bytes with value `08cd`, followed by 33 bytes representing the public key. +- A byte with the value `98` indicates **"atLeast"**. +- Two bytes, with values `73` and `00`, respectively. + The value `00` indicates the VLQ-encoded index of value `N` in the list of constants. +- A constant byte with value `83`, the VLQ-encoded value of `M`, and a constant byte with value `08` +- For each public key (`M` times), a byte with value `73`,followed by the VLQ-encoded value of the index of the public key in the list of constants + +Therefore, for each derivation path, all wallets are able to generate a unique and similar byte array as an ErgoTree. + +![Ergo Tree Bytes](./eip-0042/bytes.png) + +## Transaction Signing + +An unsigned transaction is generated on one wallet. This transaction may have been generated through ErgoPay or the dApp connector, or it could be an outgoing transaction to another address through the wallet itself. + +After an unsigned transaction is generated, the wallet + +Generates a commitment. +Stores its private part locally. +Shares a commitment as below + +``` +{ + tx:, + boxes:[encoded boxes as base64], + commitment: commitments encoded +} +``` + +The input `boxes:` are only used to display transactions on wallets. + +The general commitment format is as follows. However, this general-purpose commitment can be used for any contract. +``` +{ + "hint": "cmtReal", + "position": "0-0", + "type": "dlog", + "pubkey": { + "op": "205", + "h": "03a73c66970f14fc6450c6ab1a167cb4ba3baa64b20f731e22ec6840c70d27ef1c", + } + "a": "0253db866791af521ba4ab009509b6db89d272d9461636ee65eaa3e316884b21a4" +} +``` + +In a multi-signature wallet, a simplified version of commitment is used. + +``` +commitments: [, ...] +``` + +In the multi-signature wallet, a commitment is represented as a list of base64 strings to reduce the commitment size. Also, an empty string is used wherever a commitment is unavailable. + +[//]: # (and we can transform these commitments to standard format:) +This reduced format can be transformed into the standard format: + +``` +{ + "hint": "cmtReal", + "position": "0-", + "type": "dlog", + "pubkey": { + "op": "205", + "h": "" + }, + "a": "" +} +``` + +[//]: # (Because wallets want to pass this code via QRCode, each wallet can split it into chunks) + +To transfer these commitments using QRCode, we can split the data into several chunks: + +``` +{ + MSR: "{\"tx\": ...}", + n: + p: +} +``` + +This data is transferred between multi-signature wallets until one wallet has at least `N` commitments (including its own). + +This wallet creates a partially signed transaction with this encoding: + +``` +{ + partialTx: "", + commitments: + signed: [], + simulated: [], +} +``` + +It can also be transferred using QRCode in several chunks: + +``` +{ + MTX: "{\"partialTx\": ... }", + n: + p: +} +``` + +The first signer creates a list of simulated signers, and other signers use this list. + +Each signer: +Signs the partially signed transaction (if they still need to). +Adds their public key to the list. +Shares the data with the next signer. + +The transaction will be broadcasted whenever the signer determines that the transaction has enough signatures. + + diff --git a/eip-0042/bytes.png b/eip-0042/bytes.png new file mode 100644 index 0000000000000000000000000000000000000000..60a86c69dafc2727cfd12919e95b9bfab8a87099 GIT binary patch literal 9849 zcmd6NcT`kMv+qU}6$z3ggJcIpBn&~4{&ogx$Nl>Q~iW-Br~UrmQH1jY)g-_O6!gX!rQ9B*P)XB#i#i`K$>jODP-8P8#6+to zE}1^<`P1{>+nSRZ?~)qfAx~ubKxFd~1Oz3I$3+DIMyXl*;KTUssJj4=%xEP50PS2N zNHhS*yHAD-0M8XhJOJR0_1i9Va0tQwXo&98*47pZRZoat*!+4^b2l5izPUMpr=`Eu zWp!wM{nI87(o7LTpHLF4hKa7dd>8ofB5Ob7Z4E1lh{~kKh(VMg{RKH^W!L6f>;>^D z8c>g8b&(xgqtMfu*IZ)8LdJ%BpoTeTWEMr;Ln{mbQ)p4bgv?RHIkXw$H1Wc>)8X(Y z)p}LwM%jtx02UWHE!kz+)Af+BdB#n{PpLdbTn3~cOnnt$SCtIYg~bU_%gyW+&$S5; z%0ZP^pDa#ugEs^RX6S{mS!unje0GxKofV9PInpz$D(zpXA@Evg1AGVp0AyKNJ5zg4 z$K#hmW>b77q-)#@67se4rzKOZc>zfay{K_fM4}9D&g;?IjDjc)*@DV3k2sA%ylwFw zoR#?PC9`iFXUyT-%wA?BYX#*c7(0pM4{d&MEpyuqe-w0wF7}=m;Al8o>I%Z|)`SJ9 z*9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_qDW+Rvu|G$T`RtViB{qxYoXZ`5@>2H=JUriH88GR8B0pPqVN zyzni!O8!FN?c4K218~Cr!$~Ril=DDu|J~_6)FAsvrPKOeYcbW2Gf->K#ZLBf2qmT5 z_wZ36xYQerS3?>6jWKP$=e2Fx!~i!22!=}XstGF7)b_iJ42}&jA8tVmCPqDmFAX z|1LZ4jh%+4r%P}7-usKmjIeE4tCK}FzXvc)3C>7$&)2VC!Qo&P0rxEs1S7Ao@QEXk z93LN#M4FQBGo1tF&%l0L@cw=||J|rN2B0)kcfp>Q1Z`T>uC{;?c(Ddd3u|dKkjT&@lmz>q^=?ndR8E`EN`0)&NxGA|h~52erl z#p5`}zqd50s;X-29x(a;vNj5=zzX*{Tfe>wF}Qs0H1iA!7GnW25{lxbqDF831LCDL A!T Date: Fri, 24 Feb 2023 13:25:27 +0330 Subject: [PATCH 4/6] update commitment format --- eip-0042.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/eip-0042.md b/eip-0042.md index c10c55f4..19e18e32 100644 --- a/eip-0042.md +++ b/eip-0042.md @@ -103,7 +103,10 @@ The general commitment format is as follows. However, this general-purpose commi In a multi-signature wallet, a simplified version of commitment is used. ``` -commitments: [, ...] +commitments: [ + [, ...] + [, ...] +] ``` In the multi-signature wallet, a commitment is represented as a list of base64 strings to reduce the commitment size. Also, an empty string is used wherever a commitment is unavailable. From 6304ebb56a5f5ca03c08ceb443cafa006973548b Mon Sep 17 00:00:00 2001 From: vorujack Date: Sat, 18 Mar 2023 17:46:39 +0330 Subject: [PATCH 5/6] update address generation. --- eip-0042.md | 32 +++++++++++++++++--------------- eip-0042/bytes.png | Bin 9849 -> 13784 bytes 2 files changed, 17 insertions(+), 15 deletions(-) diff --git a/eip-0042.md b/eip-0042.md index 19e18e32..d0c6ca12 100644 --- a/eip-0042.md +++ b/eip-0042.md @@ -17,10 +17,10 @@ On top of EIP-11, this EIP implements the following additional operations: ## Wallet Creation and Address Derivation -These parameters define an `N-out-of-M` multi-signature wallet: +These parameters define an `K-out-of-N` multi-signature wallet: -* `M`: number of public keys. -* `N`: minimum signature required. +* `N`: number of public keys. +* `K`: minimum signature required. Each signer stores the set of extended public keys of all signers and a local copy of their secret. @@ -28,7 +28,7 @@ An address is derived for each signer using their extended public key over a spe ``` atLeast( - N, + K, Coll( PK(Address1), PK(Address2), @@ -51,16 +51,18 @@ The address derivation algorithm is as follows: Sort the list of signers' public keys before being used in the contract. Create the required ergoTree array as follows: -- The first byte in the array is `10`. -- The number of constant values in the contract is encoded as a variable-length quantity (VLQ). - This number equals `M+1` (Constant `N` and `M` public keys) -- A byte with value `04` denotes the integer type,followed by the value of `N` encoded as VLQ. -- For each public key 35 bytes are used: 2 bytes with value `08cd`, followed by 33 bytes representing the public key. -- A byte with the value `98` indicates **"atLeast"**. -- Two bytes, with values `73` and `00`, respectively. - The value `00` indicates the VLQ-encoded index of value `N` in the list of constants. -- A constant byte with value `83`, the VLQ-encoded value of `M`, and a constant byte with value `08` -- For each public key (`M` times), a byte with value `73`,followed by the VLQ-encoded value of the index of the public key in the list of constants +- The first byte is header. `00` +- A byte with value `98` indicates **"atLeast"** +- Encoded `K` as: + - A byte with value `04` denotes the integer type, + - followed by the value of `K` encoded as VLQ. +- A constant byte with value `83` indicates **"ConcreteCollection"**, +- The VLQ-encoded value of `N`, +- Constant byte with value `08` indicates element types in collection as **"sigmaProp"** +- For each public key 35 bytes as: + - One byte with value `08` indicates **"sigmaProp"** + - One byte with value `CD` indicates **"proveDlog"** + - followed by 33 bytes representing the public key. Therefore, for each derivation path, all wallets are able to generate a unique and similar byte array as an ErgoTree. @@ -139,7 +141,7 @@ To transfer these commitments using QRCode, we can split the data into several c } ``` -This data is transferred between multi-signature wallets until one wallet has at least `N` commitments (including its own). +This data is transferred between multi-signature wallets until one wallet has at least `K` commitments (including its own). This wallet creates a partially signed transaction with this encoding: diff --git a/eip-0042/bytes.png b/eip-0042/bytes.png index 60a86c69dafc2727cfd12919e95b9bfab8a87099..a658531a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~!jsc|i$<5jY3qO(ti|VpuXBm!hsRZ_T`lBTg`|i7o3+L}{zqx+{LVlLBF=X)^ zKD@4(DZGUKhfj46AE+DfCIK9NiF;)-NSzjQEq65WeFy@dt8+Z`J_4q|YLhpXZN?{i zOJc&M!jvZ`3x&Jwd_qDW+Rvu|G$T`RtViB{qxYoXZ`5@>2H=JUriH88GR8B0pPqVN zyzni!O8!FN?c4K218~Cr!$~Ril=DDu|J~_6)FAsvrPKOeYcbW2Gf->K#ZLBf2qmT5 z_wZ36xYQerS3?>6jWKP$=e2Fx!~i!22!=}XstGF7)b_iJ42}&jA8tVmCPqDmFAX z|1LZ4jh%+4r%P}7-usKmjIeE4tCK}FzXvc)3C>7$&)2VC!Qo&P0rxEs1S7Ao@QEXk z93LN#M4FQBGo1tF&%l0L@cw=||J|rN2B0)kcfp>Q1Z`T>uC{;?c(Ddd3u|dKkjT&@lmz>q^=?ndR8E`EN`0)&NxGA|h~52erl z#p5`}zqd50s;X-29x(a;vNj5=zzX*{Tfe>wF}Qs0H1iA!7GnW25{lxbqDF831LCDL A!T Date: Sat, 18 Mar 2023 17:47:34 +0330 Subject: [PATCH 6/6] fix two typo errors --- eip-0042.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/eip-0042.md b/eip-0042.md index d0c6ca12..e7be46b4 100644 --- a/eip-0042.md +++ b/eip-0042.md @@ -148,8 +148,8 @@ This wallet creates a partially signed transaction with this encoding: ``` { partialTx: "", - commitments: - signed: [], + commitments: + signed: [], simulated: [], } ```