ckb-cell / rgbpp-sdk

Utilities for Bitcoin and RGB++ asset integration
ISC License
53 stars 16 forks source link

Check the max input and output length of rgbpp-lock related transaction #108

Closed Flouse closed 4 months ago

Flouse commented 4 months ago

Reason

struct ExtraCommitmentData {
 input_len: byte,
 output_len: byte,
}

An upper limit check of rgbppVirtualTx.inputs.length and rgbppVirtualTx.outputs.length is required

https://github.com/ckb-cell/rgbpp-sdk/blob/da489e554918ca9a576e0319fc369db9ba4a616e/packages/ckb/src/utils/rgbpp.ts#L59

duanyytop commented 4 months ago

https://github.com/ckb-cell/rgbpp-sdk/pull/109