Skip to content

Support compressed public keys #104

@bap2pecs

Description

@bap2pecs
stakercli transaction check-phase1-staking-transaction \
  --staking-transaction <redacted> \
  --tag "62626e31" \
  --covenant-committee-pks d45c70d28f169e1f0c7f4a78e2bc73497afe585b70aa897955989068f3350aaa \
  --covenant-committee-pks 4b15848e495a3a62283daaadb3f458a00859fe48e321f0121ebabbdd6698f9fa \
  --covenant-committee-pks 23b29f89b45f4af41588dcaf0ca572ada32872a88224f311373917f1b37d08d1 \
  --covenant-committee-pks d3c79b99ac4d265c2f97ac11e3232c07a598b020cf56c6f055472c893c0967ae \
  --covenant-committee-pks 8242640732773249312c47ca7bdb50ca79f15f2ecc32b9c83ceebba44fb74df7 \
  --covenant-committee-pks e36200aaa8dce9453567bba108bdc51f7f1174b97a65e4dc4402fc5de779d41c \
  --covenant-committee-pks cbdd028cfe32c1c1f2d84bfec71e19f92df509bba7b8ad31ca6c1a134fe09204 \
  --covenant-committee-pks f178fcce82f95c524b53b077e6180bd2d779a9057fdff4255a0af95af918cee0 \
  --covenant-committee-pks de13fc96ea6899acbdc5db3afaa683f62fe35b60ff6eb723dad28a11d2b12f8c \
  --covenant-quorum 6 \
  --network mainnet \
  --staker-pk <redacted> \
  --finality-provider-pk <redacted> \
  --min-staking-amount 50000 \
  --max-staking-amount 500000000

neither --staker-pk and --covenant-committee-pks supports 33-bytes pub keys. so I have to remove those "02" "03" prefix

else I will get

1) [btc-staker] bad pubkey byte string size (want 32, have 33)

2) [btc-staker] staker pk in tx <redacted> do not match with flag <redacted>

the second error caused us some time to figure out the cause. so it will be easier if we can just support both pk formats

or at least we should show a better error to indicate it's the format issue rather than the key doesn't match

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions