Security context

What an agent needs to avoid regressing past fixes and find the next vuln in this repo.

latent-to/bittensor
master @ 5cceeb8
30
Fixes
0
CVEs
CRITICAL
Peak severity
Highlights
Denial of Service: 18 prior fixes. Scrutinize any change in this area.
neurons/text/prompting/validators/core/neuron.py: most-fixed (4 issues). Treat as high-risk during review.
13 high-severity fixes in this history; regressions here are high-impact.
Recurring patterns

The bug types that recur here, drawn from past fixes, not open vulnerabilities.

Arbitrary Code Execution: The use of unsafe deserialization via pickle when processing remote tensors and synapse messages allowed remote attackers to execute arbitrary code. Transitioning to JSON and MSGPACK resolved this, but any introduction of raw pickle.loads remains a critical hazard.
Auth Bypass: Weaknesses in gRPC message validation, such as unpack failures on split auth metadata, weak nonce checks allowing replay attacks, and missing self-query blacklists, compromised the validator network's integrity. Ensuring strict, unified AuthInterceptor logic is paramount.
Denial of Service: The validator node processes are highly susceptible to thread/resource exhaustion or stalling when communicating with slow or malicious miners. Enforcing explicit read deadlines, connect timeouts, and non-blocking worker pools is necessary to maintain network consensus.