Module protostatus

Source
Expand description

Observe and enforce lists of recommended and required subprotocols.

To prevent insecure clients from exposing themselves to attacks, and to prevent obsolete clients from inadvertently DoSing the network by looking for relays with functionality that no longer exists, we have a mechanism for “recommended” and “required” subprotocols.

When a subprotocol is recommended, we issue a warning whenever it is absent. When a subprotocol is required, we (typically) shut down Arti whenever it is absent.

While Arti is running, we check our subprotocols whenever we find a new timely well-signed consensus.

Additionally, we check our subprotocols at startup before any directory is received, to ensure that we don’t touch the network with invalid software.

We ignore any list of required/recommended protocol that is [older than the release date of this software].

Functions§

enforce_protocol_recommendations 🔒
Check whether we have any cached protocol recommendations, and report about them or enforce them immediately.
evaluate_protocol_status 🔒
Check whether we should take action based on the protocol recommendation from recommendation_timestamp, given that our own supported subprotocols are software_protocols.
missing_recommended_ok 🔒
Return a list of the protocols which may be recommended, and which we know are missing in Arti.
watch_protocol_statuses 🔒
Run indefinitely, checking for any protocol-recommendation issues.