Skip to content

Add ignore_missing_asset_packets field to SubmitTx #942

@Kukks

Description

@Kukks

Description

Add an ignore_missing_asset_packets field to SubmitTx (either in the proto message or the PSBT) as an alternative solution to the asset weight attack vector discussed in #938.

Motivation

An attacker can craft a VTXO with a large number of assets to inflate transaction weight. The current approach caps len(assets) per output. An alternative (or complementary) mitigation is to let the caller signal that missing asset packets should be silently ignored rather than treated as an error — removing the incentive to bloat asset lists in the first place.

Design

Add an optional field to SubmitTx:

// In SubmitOffchainTxRequest or as a PSBT field
bool ignore_missing_asset_packets = X;

When set, any asset referenced in a VTXO that has no corresponding packet is silently skipped rather than causing a validation failure.

Tasks

  • Add ignore_missing_asset_packets to proto or PSBT
  • Wire up validation logic in SubmitTx to respect the flag
  • Tests
  • Docs

Related

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