Added some protocol command documentation.
[doldaconnect.git] / doc / protocol / cmd / cnct.tex
CommitLineData
43c0eb2d
FT
1\syntax{cnct FNET HOSTNAME [(KEY VALUE)...]}
2
3\begin{reqdesc}
4 Instructs the daemon to connect to a hub. The \param{FNET} parameter
5 is the name of the protocol that the hub will be running, and the
6 \param{HOSTNAME} parameter is the network name of the
7 hub. Currently, the only supported value for \param{FNET} is
8 \texttt{dc}, indicating the Direct Connect
9 protocol. \param{HOSTNAME} may be either an IPv4 address or a
10 symbolic hostname, followed by a colon and the port number to
11 connect to. Zero or more key-value pairs may be supplied as well,
12 setting certain parameters of the protocol operation. Currently
13 supported keys are:
14
15 \begin{itemize}
16 \item \texttt{nick}: The nickname to use when speaking to the hub,
17 instead of the daemon's default nickname.
18 \item \texttt{password}: The password to supply if the hub asks for
19 one.
20 \item \texttt{charset}: For Direct Connect hubs, the character
21 encoding to use instead of the default CP1252.
22 \end{itemize}
23\end{reqdesc}
24
25\revision{1}
26\perm{fnetctl}
27
28\begin{responses}
29 \response{200 ID}
30 The daemon has created a node for the hub and will be attempting to
31 connect to it. The \param{ID} parameter is the unique numeric ID for
32 the new node.
33 \response{504}
34 The \param{HOSTNAME} parameter could not be converted to the local
35 character set on the system running the daemon, so no connection
36 attempt could be made.
37 \response{509}
38 The \param{HOSTNAME} parameter was invalid and could not be parsed
39 by the daemon.
40 \response{511}
41 The daemon does not support the protocol named by the \param{FNET}
42 parameter.
43 \response{515}
44 The daemon administrator has set a quota restricting the maximum
45 number of connected hubs, and a new connection attempt would violate
46 that quota.
47\end{responses}