inference-labs-inc / bittensor-miner-ddos-mitigation-guide

Basic protection tools and techniques
0 stars 0 forks source link

Guide shared by jondurbin #1

Open IvanAnishchuk opened 1 month ago

IvanAnishchuk commented 1 month ago

To be reviewed and integrated

https://discord.com/channels/799672011265015819/1191833510021955695/1237409837101482015

Try this:

Update your open file limit and experiment with client_body_timeout, client_header_timeout, and send_timeout to reduce the likelihood of a slowloris type of attack. Also optionally update the location directive to only allow the specific synapses for that miner. If you really want to get fancy you could also continuously query the metagraph for list of validator IPs and update the location directive with allow and deny directives, i.e. deny everything not coming from validator IP.

IvanAnishchuk commented 1 month ago

Sure, feel free to DM me. I'll share my setup with you. I've also developed a solution to deal with smaller attacks that had to do with volume of requests and time connected: https://github.com/sirouk/btt-miner-shield