hyperledger / iroha-java

https://wiki.hyperledger.org/display/iroha
28 stars 38 forks source link

Iroha 2 multisignature example #308

Closed 6r1d closed 10 months ago

6r1d commented 1 year ago

Yesterday, @baziorek requested an example code for Iroha2-Java with multi-signature transactions.

Some time ago, I remember that somebody told me during a community meeting that there is some problem with MST for now, and there were changes in them (if I understood correctly)

Could we talk about the capabilities needed to show the current Iroha functionality and add a detailed one? Thanks in advance!

6r1d commented 1 year ago

As Roman Shanin suggested, we may be able to re-use our integration test redone in Java.

baziorek commented 1 year ago

I was asked by @6r1d To describe scenario of example. IMO it would be great to have something like that: https://github.com/hyperledger/iroha-python/blob/develop/examples/batch-example.py#L172 - here Alice is signing with all her keys (she has 2).

To be more specific - I would like to see possibility of signing transaction with multiple keys. Sample scenario (it is inspired by what can be done in Iroha 1, so some commands can not exist):

  1. Admin creates account
    1. with two keys
    2. with quorum=2 (each transaction made by the account must be signed by at least 2 keys)
  2. The account is creating any transaction (e.g. setting account details)
    1. The transaction must be signed by both keys
  3. The account checks results (some kind of query)
baziorek commented 1 year ago

Some additional explanation why I need this: one of core functionality of our system is to sign contracts in blockchain between multiple users. That is why MST is that important for us.

baziorek commented 1 year ago

Today somebody asked about the same in public chat:
image