scilla icon indicating copy to clipboard operation
scilla copied to clipboard

1-of-X or Y-of-X public key encryption [feature request]

Open bguiz opened this issue 7 years ago • 2 comments

Will it be possible to do 1-of-X or Y-of-X public key encryption within zilliqa's smart contracts? (i.e. will these functions be exposed as a Scilla builtin?)

I'm thinking of doing something similar to this within a smart contract: https://stackoverflow.com/q/53284796/194982

I see some EC Schnorr functions already exposed here:

      ("schnorr_gen_key_pair", Hashing.schnorr_gen_key_pair_arity, Hashing.schnorr_gen_key_pair_type, elab_id, Hashing.schnorr_gen_key_pair);
      ("schnorr_sign", Hashing.schnorr_sign_arity, Hashing.schnorr_sign_type, elab_id, Hashing.schnorr_sign);
      ("schnorr_verify", Hashing.schnorr_verify_arity, Hashing.schnorr_verify_type, elab_id, Hashing.schnorr_verify);

... but not the ones that would be needed for encryption or decryption. In addition to these could we also have the following:

builtin schnorr_encrypt clear_data public_keys_list min_keys
builtin schnorr_decrypt encrypted_data private_keys

I understand that core zilliqa already has implementations for these, so these would just need to be exposed here.

bguiz avatar Nov 15 '18 08:11 bguiz

Thanks for this feature request @bguiz. We will keep this feature in mind when we start adding advanced cryptographic primitives.

AmritKumar avatar Dec 03 '18 11:12 AmritKumar

Thanks - looking forward to this feature!

bguiz avatar Dec 04 '18 02:12 bguiz