What is Nostr?
Gavin Andresen [ARCHIVE] /
npub1s4l…44kw
2023-06-07 02:26:49
in reply to nevent1q…zsvc

Gavin Andresen [ARCHIVE] on Nostr: 📅 Original date posted:2011-09-15 🗒️ Summary of this message: Should DoS ...

📅 Original date posted:2011-09-15
🗒️ Summary of this message: Should DoS protection disable if node has few connections? Fail hard or soft? Sending messages with bad checksums bannable?
📝 Original message:> Should the DoS protection auto-disable if the node has less than a minimum
> number of connections? The idea being that if our node seems to be kicking
> everybody off the roster maybe there is something wrong with the
> protections.

Darn good question. If the protection fails, would it be better for it
to 'fail hard', leaving people complaining "bitcoin won't stay
connected!"

Or fail soft, so you at least have a couple of connections.

I think fail hard is better-- we'll immediately know about the
problem, and can fix it. Fail soft makes me nervous because I think
that would make it more likely a bug splits the network (and,
therefore, the blockchain).


> It would be nice if the node sent a message to the banned peer with a code
> indicating the reason for the ban

If I think you're trying to DoS me, why would I be nice to you? I
think response messages would just give an attacker another potential
attack vector, and it is clear from the debug.log what triggers a ban.

> Should sending lots of messages that don't pass the protocol-level checksum
> test be a bannable offense? Or generally sending garbage data?

Good question. Anybody see a reason not to? How much tolerance (if
any) should there be for sending garbage data (I assume the
lower-level network stack almost never garbles data, is that a good
assumption)?


--
--
Gavin Andresen
Author Public Key
npub1s4lj77xuzcu7wy04afcr487f0r3za0f8n2775xrpkld2sv639mjqsd44kw