3 .\" Manual for the malicious proxy
5 .\" (c) 2008 Straylight/Edgeware
8 .\"----- Licensing notice ---------------------------------------------------
10 .\" This file is part of Trivial IP Encryption (TrIPE).
12 .\" TrIPE is free software: you can redistribute it and/or modify it under
13 .\" the terms of the GNU General Public License as published by the Free
14 .\" Software Foundation; either version 3 of the License, or (at your
15 .\" option) any later version.
17 .\" TrIPE is distributed in the hope that it will be useful, but WITHOUT
18 .\" ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
19 .\" FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22 .\" You should have received a copy of the GNU General Public License
23 .\" along with TrIPE. If not, see <https://www.gnu.org/licenses/>.
25 .\"--------------------------------------------------------------------------
26 .so ../common/defs.man \" @@@PRE@@@
28 .\"--------------------------------------------------------------------------
29 .TH tripe-mitm 8tripe "14 October 2003" "Straylight/Edgeware" "TrIPE: Trivial IP Encryption"
31 .\"--------------------------------------------------------------------------
34 tripe-mitm \- malicious proxy for TrIPE
36 .\"--------------------------------------------------------------------------
44 .\"--------------------------------------------------------------------------
53 Its purpose is to test the robustness of the TrIPE implementation, by
54 deliberately introducing communication problems such as dropped,
55 repeated or corrupted packets.
57 The command line contains a sequence of directives, each of which has
61 A list of directives can be stored in a file, one per line, and included
65 .SS "Command line options"
66 The following options are recognized.
69 Write a very brief help message to standard output, and exit
73 Write the program's version number to standard output, and exit
77 Write a usage message to standard output, and exit successfully.
79 .BI "\-k, \-\-keyring=" file
82 The default keyring file is
84 in the current directory.
86 A directive is ignored if it is empty, or if its first character is a
88 The following directives are recognized.
90 .BI peer: name : local-port : remote-addr : remote-port
91 Register a peer. We listen for packets on
99 identifies the public key which that peer uses to authenticate itself.
106 may be a hostname or an IP address in dotted-quad format. Exactly two
108 directives must be present. The one first registered is the
110 peer; the second is the
112 peer. The two peers must use
117 Read more directives from
119 Directives should appear one per line. Empty lines and comments are
120 permitted. An included file may include other files. It may even
121 include itself, though this is just a good way to tie the program in
122 knots until it runs out of file handles.
124 .BI filt: filter : args : \fR...
125 Apply a given filter to packets received from either peer. See the
126 description of filters below for more details.
128 .BI lfilt: filter : args : \fR...
129 Apply a given filter to packets received from the left peer.
131 .BI rfilt: filter : args :\fR...
132 Apply a given filter to packets received from the right peer.
134 .BI next: tag :\fR...
135 Begin the next branch of the first fork filter node named
137 in each filter chain. See below for more about filter chains.
139 .BI flood\fR[\fP: type : millis : size\fR]
140 Flood both peers with random packets. If
142 is given, it is interpreted as a TrIPE message type code in hexadecimal,
143 and the messages sent will have this type; otherwise the messages have
144 random type. Messages are sent approximately once every
146 milliseconds; the default interval is 10 milliseconds. The messages
149 bytes long each; the default size is 128 bytes.
151 .BI lflood\fR[\fP: type : millis : size\fR]
154 above, but only flood the left peer.
156 .BI rflood\fR[\fP: type : millis : size\fR]
159 above, but only flood the right peer.
161 Each peer has a filter chain associated with it. Messages received from
162 that peer get processed by the filter chain. Only if the filter chain
163 decides to send the message is it actually sent. (See the
165 filter, described below.)
166 Messages generated by a
168 directive (above) are also processed by a filter chain, just like normal
169 messages. The filters in a chain are processed in the order they were
172 The filters currently supported are as follows.
175 Send the message to the destination peer. This is the
177 way messages are sent. If your filter chains don't end in a
179 filter then nothing will get through!
182 Introduce a fork in a filter chain. A fork may have multiple branches
183 leading off it. The end of a branch is indicated by a
185 directive which names the fork
187 further filters added to the chain form a new parallel branch of that
188 fork. (If there are two forks with the same tag on a peer's chain, then
189 only the earliest is matched. This isn't helpful behaviour.)
191 .BI delay: qlen \fR[\fP: millis : p-replay\fR]
192 Delay, replay and reorder messages. A queue of
194 messages is maintained. If the queue fills up, or every
196 milliseconds (default 100), a message from the queue is chosen at random
197 and transmitted (i.e., processed by the rest of the filter chain). If
198 the message was transmitted due to a timer (rather than lack of space in
199 the queue) then it has a 1 in
201 probability (default 1 in 20) of being left in the queue.
203 .BI drop\fR[\fP: p-drop\fR]
204 Randomly drop messages. Each message has a 1 in
206 probability (default 1 in 5) of being discarded.
208 .BI corrupt\fR[\fP: p-corrupt\fR]
209 Randomly corrupt messages. Each message has a 1 in
211 probability (default 1 in 5) of being corrupted by having a
212 randomly chosen byte mangled. The message might be further corrupted,
217 .\"--------------------------------------------------------------------------
220 The parser is currently very primitive, and error handling is rather
221 poor. There are lots of pointless restrictions which wouldn't take very
222 long to fix. The program generally lacks polish. The program doesn't
223 understand the TrIPE protocol to a sufficient extent to really attack it
226 .\"--------------------------------------------------------------------------
231 .\"--------------------------------------------------------------------------
234 Mark Wooding, <mdw@distorted.org.uk>
236 .\"----- That's all, folks --------------------------------------------------