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

Possible DoS attack: adding duplicate transaction via forward after it has committed #85

Open
electricmonk opened this issue Sep 12, 2018 · 1 comment
Assignees

Comments

@electricmonk
Copy link
Contributor

  1. Send a transaction
  2. Wait for it to be committed
  3. Send it again via forward. It will enter the pending pool, and stay there until the cleanup process removes it.
@talkol
Copy link
Member

talkol commented Sep 13, 2018

It's by design. Every system is vulnerable to spamming since it accepts transactions via forward. There are two main aspects to plan:

  1. How early do we identify the issue - in our case we could verify every transaction immediately on forward received and throw it, but instead we optimize with an optimistic approach. We don't verify on entry because we must verify during consensus, so we only do this once and not twice. The price is a bit of memory held until we throw the transaction which we feel is the better tradeoff. We believe that CPU will be the narrow resource here, not memory.

  2. Accountability for spammers - this is the real solution.. and most blockchains don't have it. In our case, the transaction pool must sign every batch of forwarded transactions so this node is now accountable for them. Eventually, we will implement our reputation system and nodes that spam forwards will be penalized and their forwards ignored. This mechanism will be developed as spamming becomes an issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants