Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Commander transaction:sign does not produce signatures in correct order #5002

Closed
shuse2 opened this issue Mar 17, 2020 · 1 comment · Fixed by #5014
Closed

Commander transaction:sign does not produce signatures in correct order #5002

shuse2 opened this issue Mar 17, 2020 · 1 comment · Fixed by #5014

Comments

@shuse2
Copy link
Member

shuse2 commented Mar 17, 2020

Expected behavior

transaction:sign should produce correct signature order for multi signature registration transaction

Actual behavior

Signature itself were correct, but the order was wrong

Steps to reproduce

./bin/run transaction:sign '{"id":"12124384765103620622","type":12,"senderPublicKey":"d9f0569230016a22206dd123900f245a71b479b5463c7ad235e4f4e933e181e2","senderId":"8363255854011484280L","nonce":"2","fee":"10000000","signatures":["b9045848a0919bdd9cbf89f7809dc56ac829494936c493372bfa9f8ada01676079dc57702102d7aeff77f895902c8b31a2e0ccc030ae20b3ee34c1e80491e40e","","",""],"asset":{"mandatoryKeys":[],"optionalKeys":["2675782a6b2c90d9d555343d7a0ac6c6a558ba0484f0ca2f6db0c0dd10a72624","c39ff325a5329cfe0f1b122302e9e7df9cb0d9d513770fddc79edaf9106abcff","e072e3987e9aad9ed7e5735b89af817d16835dbc646d2463928912f42ca18176"],"numberOfSignatures":2}}' --optional-key="e072e3987e9aad9ed7e5735b89af817d16835dbc646d2463928912f42ca18176" --optional-key="c39ff325a5329cfe0f1b122302e9e7df9cb0d9d513770fddc79edaf9106abcff" --optional-key="2675782a6b2c90d9d555343d7a0ac6c6a558ba0484f0ca2f6db0c0dd10a72624" --number-of-passphrases 3

with members

{
    passphrase: 'raw chunk control wheat bird stuff mix domain tuna friend puzzle husband',
    privateKey: '3422829a28cb4d4252f14aacdad1fb3b60d10dacd971cb80b770d2a00a874b26d9f0569230016a22206dd123900f245a71b479b5463c7ad235e4f4e933e181e2',
    publicKey: 'd9f0569230016a22206dd123900f245a71b479b5463c7ad235e4f4e933e181e2',
    address: '8363255854011484280L'
  },
  {
    passphrase: 'table grocery kiss hip retreat chief fringe trash egg valve remind cigar',
    privateKey: '2e21df73809acf3a2ce01e12fa063f981732504fb4c17e341fc2760706b6f2f2e072e3987e9aad9ed7e5735b89af817d16835dbc646d2463928912f42ca18176',
    publicKey: 'e072e3987e9aad9ed7e5735b89af817d16835dbc646d2463928912f42ca18176',
    address: '12455274277049355212L'
  },
  {
    passphrase: 'rally deposit crop embark bronze mom mechanic power walnut melt mention april',
    privateKey: '5773ad9d5d4efc83536e8994b97c0e50f89e90d31777f3d41ba0003961f69dc9c39ff325a5329cfe0f1b122302e9e7df9cb0d9d513770fddc79edaf9106abcff',
    publicKey: 'c39ff325a5329cfe0f1b122302e9e7df9cb0d9d513770fddc79edaf9106abcff',
    address: '8525811506575967317L'
  },
  {
    passphrase: 'position slogan mass reflect stumble pluck liar mushroom electric mistake repair add',
    privateKey: '86a04a78648b88d5216318ad6824b42fa5d7c098bf49c74dabfc3500d68f42492675782a6b2c90d9d555343d7a0ac6c6a558ba0484f0ca2f6db0c0dd10a72624',
    publicKey: '2675782a6b2c90d9d555343d7a0ac6c6a558ba0484f0ca2f6db0c0dd10a72624',
    address: '3262801414249632511L'
  },

Which version(s) does this affect? (Environment, OS, etc...)

4.0-

@pablitovicente
Copy link
Contributor

Will add keys sorting in elements/lisk-transactions/src/sign_multi_signature_transaction.ts

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment