chiark / gitweb /
Merge branches 'mdw/knock' and 'mdw/ipv6' into bleeding
[tripe] / svc / conntrack.8.in
index a1e94916b7ff12f0aa3e4dc45d83e0fa52efa106..b38f6681dacc96291a7b7d320a9ebabab5f190a4 100644 (file)
@@ -55,7 +55,9 @@ conntrack \- tripe service to start/stop peers depending on external connectivit
 The
 .B conntrack
 service watches D-Bus network management services like
-.BR NetworkManager (8)
+.BR NetworkManager (8),
+.BR ConnMan
+.RB ( connmand (8)),
 and Nokia's
 .BR ICd ,
 bringing peers up and down automatically.  It's designed to be useful on
@@ -83,22 +85,24 @@ followed by peer definitions, each of which looks like this:
 .B =
 .RI [ remote-addr ]
 .IB network / mask
+\&...
 .PP
 This means that the peer
 .I tag
-should be selected if the host's current IP address is within the
-network indicated by
+should be selected if the host's current IP address is within one of the
+networks indicated by
 .IB network / mask \fR.  
-Here,
+Here, a
 .I network
-is an IP address in dotted-quad form, and
+is an IPv4 or IPv6 address in dotted-quad form, and
 .I mask
-is a netmask, either in dotted-quad form, or as a number of 1-bits.
-Only one peer in each group may be connected at any given time; if a
-change is needed, any existing peer in the group is killed before
-connecting the new one.  If no match is found in a particular group,
-then no peers in the group are connected.  Strange and unhelpful things
-will happen if you put the same peer in several different groups.
+is a netmask, either in dotted-quad form (for IPv4), or as a prefix
+length (i.e., the number of initial 1-bits).  Only one peer in each
+group may be connected at any given time; if a change is needed, any
+existing peer in the group is killed before connecting the new one.  If
+no match is found in a particular group, then no peers in the group are
+connected.  Strange and unhelpful things will happen if you put the same
+peer in several different groups.
 .PP
 The tags
 .B down
@@ -111,36 +115,29 @@ is useful for detecting a `home' network, where a VPN is unnecessary
 The notion of `current IP address' is somewhat vague.  The
 .B conntrack
 service calculates it as the source address that the host would put on
-an IP packet sent to an arbitrarily chosen remote address.  The default
-remote address is 1.2.3.4 (which is unlikely ever to be assigned); this
-should determine an IP address on the network interface closest to the
-default gateway.  You can influence this process in two ways.  Firstly,
-you can change the default remote address used by adding a line
+an IP packet sent to a particular remote address; note that this is
+entirely hypothetical, and no actual packets are transmitted.  The
+default remote addresses are 1.2.3.4 (for IPv4, which is unlikely ever
+to be assigned), and 2001::1 (for IPv6); this should determine an IP
+address on the network interface closest to the default gateway.  You
+can influence this process in two ways.  Firstly, you can change the
+default remote address used by adding one or more lines
 .IP
 .B "test-addr ="
 .I remote-addr
+\&...
 .PP
 before the first peer group section.  Secondly, you can specify a
 particular
 .I remote-addr
 to use when checking whether a particular peer is applicable.
 .PP
-The peer definitions can be in any order.  They are checked
-most-specific first, and searching stops as soon as a match is found.
-Therefore a default definition can be added as
-.IP
-.I tag
-.B =
-.B 0/0
-.PP
-without fear of overriding any more specific definitions.  For avoidance
-of doubt, one peer definition is
-.I more specific
-than another if either the former has a specified
-.I remote-addr
-and the latter has not, or the former is wholly contained within the
-latter.  (Overlapping definitions are not recommended, and will be
-processed in an arbitrary order.)
+The peer definitions in each group are checked in the order given, and
+searching stops as soon as a match is found.  (In older versions of
+.BR conntrack ,
+definitions were processed according to a most-specific-first order, but
+that doesn't provide an ordering between IPv4 and IPv6 networks, which
+is important; so this has been changed.)
 .PP
 Peers are connected using the
 .BR connect (8)
@@ -217,6 +214,24 @@ is to be brought down, or no matching peer was found.  The
 is one of the following.
 .RS
 .TP
+.BI "connman initially-" state
+ConnMan was detected on startup, and is in the given
+.I state
+\(en see below.
+.TP
+.BI "connman " state
+ConnMan has transitioned to
+.IR state .
+The possible states are:
+.B offline
+(the network is turned off by user request);
+.B idle
+(no network interfaces are active);
+.B ready
+(an interface is up but not fully configured); and
+.B online
+(an interface is up and configured).
+.TP
 .BI "icd connected " iap
 Maemo ICd has acquired an active network connection, identified by
 .IR iap .