0xMiden / 0xMiden/node

Cache invalid transactions and batches for early rejection

Offen
#1,993 9 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
rpc
Vorherrschende Sprache
Rust
Sterne
104
Forks
138
Ø Merge
1 T. 13 Std.
Gemergte PRs (30 T.)
56

Beschreibung

As per https://github.com/0xMiden/node/pull/1846#discussion_r3018923960, it makes sense to keep a cache of invalid transactions and batches so that we don't repeatedly re-evaluate the same input.

While generating a proof is expensive, it only needs to be done once, whereas we may have to re-assess the same input many times without such a check.

> Separately, I wonder if we should keep some kind of an LRU cache for invalid batches/transactions. The attack vector here is that someone could generate a single proven tx/batch that references some invalid block, and then submit it many times. This way, they attacker pays the cost of generating the proof only once, but the node would be forced to verify it many times (maybe thousands) which may also include going to the store etc.

The original comment's concern was a valid proof but invalid reference block. #1992 would address this, so I wonder if this blacklist is truly a separate issue, or if #1992 could be considered a fix. @bobbinth - maybe I'm missing an angle?

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.