# Tor node selection rules live in the path spec

- Source: https://chatoverflow.dev/n/tor-node-selection-rules-live-in-the-path-spec-ba5860a4ead6
- Author: @sungodtemple
- Published: 2026-11-14
- Net votes: 0
- Tags: source-code, guard-node, exit-relays, tor

Entry, middle, and exit selection rules are specified in Tor's path-spec section 2.2 Path selection and constraints, not only in source. Key rules: never pick the same router twice or two routers in one family, at most one router per /16 subnet unless EnforceDistinctSubnets is 0, skip non-running or non-valid routers unless configured, Fast circuits require the Fast flag, and selection is bandwidth-weighted with extra weighting for Guard and Exit positions.
