chiark / gitweb /
cleanup: Whitespaces fixes, left right and centre.
authorMark Wooding <mdw@distorted.org.uk>
Sun, 28 Jan 2007 23:10:31 +0000 (23:10 +0000)
committerMark Wooding <mdw@distorted.org.uk>
Sun, 28 Jan 2007 23:10:31 +0000 (23:10 +0000)
53 files changed:
Makefile.am
client/Makefile.am
client/tripectl.c
common/Makefile.am
common/protocol.h
common/util.c
common/util.h
configure.in
debian/changelog
debian/control
debian/rules
debian/tripe.README
debian/tripe.postrm
debian/tripe.prerm
doc/Makefile.am
doc/pkstream.1
doc/protocol.ms
doc/tripe-admin.5.in
doc/tripe-keys.8
doc/tripe-keys.conf.5
doc/tripe-mitm.8
doc/tripe.8.in
doc/tripectl.1.in
doc/tripemon.1.in
doc/wrestlers.tex
init/Makefile.am
init/tripe-init.in
keys/Makefile.am
keys/tripe-keys.in
keys/tripe-keys.master
mon/Makefile.am
mon/tripemon.in
pkstream/Makefile.am
pkstream/pkstream.c
proxy/Makefile.am
proxy/tripe-mitm.c
server/Makefile.am
server/admin.c
server/chal.c
server/keyexch.c
server/keymgmt.c
server/keyset.c
server/peer.c
server/servutil.c
server/tripe.c
server/tripe.h
server/tun-bsd.c
server/tun-linux.c
server/tun-slip.c
server/tun-unet.c
wireshark/Makefile.am
wireshark/cap
wireshark/packet-tripe.c

index 11a35083fb5e456af9ad6faf979a2e09fc87c0e6..ef430751f9461ac69b0d96b497500e2ad649a2cc 100644 (file)
 ## it under the terms of the GNU General Public License as published by
 ## the Free Software Foundation; either version 2 of the License, or
 ## (at your option) any later version.
-## 
+##
 ## TrIPE is distributed in the hope that it will be useful,
 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 ## GNU General Public License for more details.
-## 
+##
 ## You should have received a copy of the GNU General Public License
 ## along with TrIPE; if not, write to the Free Software Foundation,
 ## Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index 199be93bb1fb6e14157603dcfbac14c95679d2cb..f466ba4817dcc0f6f460ee35956a60a94eca901c 100644 (file)
 ## it under the terms of the GNU General Public License as published by
 ## the Free Software Foundation; either version 2 of the License, or
 ## (at your option) any later version.
-## 
+##
 ## TrIPE is distributed in the hope that it will be useful,
 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 ## GNU General Public License for more details.
-## 
+##
 ## You should have received a copy of the GNU General Public License
 ## along with TrIPE; if not, write to the Free Software Foundation,
 ## Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index b27d3fdcbf331da023c15009b7ebabf35ff0786d..28961252685fdb6f2c4523604a82934d45efb027 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2001 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -184,7 +184,7 @@ static void cline(char *p, size_t len, void *b)
     checkbg(&p);
     die(EXIT_FAILURE, "%s", p);
   } else
-    die(EXIT_FAILURE, "unexpected output `%s %s'", q, p); 
+    die(EXIT_FAILURE, "unexpected output `%s %s'", q, p);
 }
 
 static void sline(char *p, size_t len, void *b)
@@ -319,7 +319,7 @@ Options in full:\n\
 -D, --daemon           Become a background task after connecting.\n\
 -d, --directory=DIR    Select current directory [default " CONFIGDIR "].\n\
 -a, --admin-socket=FILE        Select socket to connect to\n\
-                          [default " SOCKETDIR "/tripesock].\n\
+                         [default " SOCKETDIR "/tripesock].\n\
 -P, --pidfile=FILE     Write process-id to FILE.\n\
 \n\
 -s, --spawn            Start server rather than connecting.\n\
index 28c3db99bbd380521371ca079f5f7cd8cdc767f3..8b9454ab0a2647b844ef146de24ea18ed29eeec7 100644 (file)
 ## it under the terms of the GNU General Public License as published by
 ## the Free Software Foundation; either version 2 of the License, or
 ## (at your option) any later version.
-## 
+##
 ## TrIPE is distributed in the hope that it will be useful,
 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 ## GNU General Public License for more details.
-## 
+##
 ## You should have received a copy of the GNU General Public License
 ## along with TrIPE; if not, write to the Free Software Foundation,
 ## Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index 6ffaeb2dcc70106cd47db2ecd4cf7e95b6e6ef4d..1fc151184accd68059cd50a923e943fbfd087edc 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2003 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index 1745655104b5e8f6dc43d71a5adee6473fb47324..c6c2b22c3c51fbfc3641b8226fca69f4545001c1 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2001 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index 0c135480359c14499cef21c02cbda995d8f89aa4..a54910f29d952eae905861a07daedc6d5ff38208 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2001 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index 5c6693d88c69cd8e97ea29dd0e870468d996225d..b8dbbdeff10a0cb180b8edb8ed7e7588b90564ea 100644 (file)
@@ -15,12 +15,12 @@ dnl TrIPE is free software; you can redistribute it and/or modify
 dnl it under the terms of the GNU General Public License as published by
 dnl the Free Software Foundation; either version 2 of the License, or
 dnl (at your option) any later version.
-dnl 
+dnl
 dnl TrIPE is distributed in the hope that it will be useful,
 dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
 dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 dnl GNU General Public License for more details.
-dnl 
+dnl
 dnl You should have received a copy of the GNU General Public License
 dnl along with TrIPE; if not, write to the Free Software Foundation,
 dnl Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -36,7 +36,7 @@ AM_PROG_LIBTOOL
 DIRS="" AC_SUBST([DIRS])
 
 python=no
-mdw_PROG_PYTHON([2.3], 
+mdw_PROG_PYTHON([2.3],
   [python=yes
    pyscripts='${PYTHONSCRIPTS}'
    DIRS="$DIRS keys"
@@ -50,7 +50,7 @@ if test $python = yes; then
     python -c >&5 2>&5 '
 import pygtk
 pygtk.require("2.0")
-import gtk 
+import gtk
 ' && mdw_cv_pygtk=yes
   ])
   if test $mdw_cv_pygtk = yes; then
@@ -67,43 +67,43 @@ mdw_OPT_TRACE
 
 AC_ARG_WITH([linux-includes],
 [  --with-linux-includes=DIR
-                          search for Linux kernel includes in DIR],
+                         search for Linux kernel includes in DIR],
 [CFLAGS="$CFLAGS -I$withval"],
 [:])
 
 AC_ARG_WITH([configdir],
-[  --with-configdir=DIR    look for keys and other configuration in DIR
-                          [default=/var/lib/tripe]],
+[  --with-configdir=DIR           look for keys and other configuration in DIR
+                         [default=/var/lib/tripe]],
 [configdir=$withval],
 [configdir=/var/lib/tripe])
 
 AC_ARG_WITH([socketdir],
-[  --with-socketdir=DIR    put admin socket in DIR [default=.]],
+[  --with-socketdir=DIR           put admin socket in DIR [default=.]],
 [socketdir=$withval],
 [socketdir=.])
 
 AC_ARG_WITH([pidfile],
-[  --with-pidfile=FILE     make tripectl write its pid to FILE
-                          [default=./tripectl.pid]],
+[  --with-pidfile=FILE    make tripectl write its pid to FILE
+                         [default=./tripectl.pid]],
 [pidfile=$withval],
 [pidfile=tripectl.pid])
 
 AC_ARG_WITH([initconfig],
 [  --with-initconfig=FILE  read definitions from FILE in init script
-                          [default=/etc/tripe.conf]],
+                         [default=/etc/tripe.conf]],
 [initconfig=$withval],
 [initconfig=/etc/tripe.conf])
 
 AC_ARG_WITH([logfile],
-[  --with-logfile=DIR      make tripectl write its log to FILE 
-                          [default=./tripe.log]],
+[  --with-logfile=DIR     make tripectl write its log to FILE
+                         [default=./tripe.log]],
 [logfile=$withval],
 [logfile=tripe.log])
 
 WIRESHARK_CFLAGS=""
 WIRESHARK_PLUGIN_DIR="unknown"
 AC_ARG_WITH([wireshark],
-[  --with-wireshark        build and install Wireshark plugin],
+[  --with-wireshark       build and install Wireshark plugin],
 [case "$withval" in
    no) wireshark=false requirewireshark=false;;
    yes) wireshark=true; requirewireshark=true;;
@@ -113,8 +113,8 @@ esac],
 
 tun=auto
 AC_ARG_WITH([tunnel],
-[  --with-tunnel=KIND      kinds of tunnel device to use
-                            (linux, unet, bsd, slip)],
+[  --with-tunnel=KIND     kinds of tunnel device to use
+                           (linux, unet, bsd, slip)],
 [tun=$withval])
 
 if test "$tun" = auto; then
@@ -150,21 +150,21 @@ for i in $tun; do
     bsd) AC_DEFINE([TUN_BSD], [1],
                   [Install the BSD tunnel driver.]) ;;
     unet) AC_DEFINE([TUN_UNET], [1],
-                    [Install the obsolete Linux Usernet driver.]) ;;
+                   [Install the obsolete Linux Usernet driver.]) ;;
     slip) ;;
     *) AC_MSG_ERROR([Unknown tunnel type]) ;;
   esac
   tunnels="$tunnels&tun_$i, "
 done
 AC_SUBST(tun)
-AC_DEFINE_UNQUOTED([TUN_LIST], [$tunnels 0], 
+AC_DEFINE_UNQUOTED([TUN_LIST], [$tunnels 0],
   [List of tunnel drivers to install.])
 
 mdw_MLIB(2.0.0)
 mdw_CATACOMB(2.1.0, [CFLAGS="$CFLAGS $CATACOMB_CFLAGS"])
 
 if test "$wireshark" = true -a "$WIRESHARK_PLUGIN_DIR" = unknown; then
-  AC_CACHE_CHECK([where to put Wireshark plugins], 
+  AC_CACHE_CHECK([where to put Wireshark plugins],
     [mdw_cv_wireshark_plugin_dir], [
     changequote(,)
     mdw_cv_wireshark_plugin_dir="failed"
@@ -180,7 +180,7 @@ if test "$wireshark" = true -a "$WIRESHARK_PLUGIN_DIR" = unknown; then
       wsver=`$wsbin -v | sed 's/^[^ ]* \([0-9A-Za-z.]*\).*$/\1/;q'`
       dir=$wsprefix/lib/wireshark/plugins/$wsver
       if test -d "$dir"; then
-        mdw_cv_wireshark_plugin_dir=$dir
+       mdw_cv_wireshark_plugin_dir=$dir
       fi
     fi
     changequote([, ])
@@ -198,7 +198,7 @@ if test "$wireshark" = true; then
   bad=true
   mdw_CFLAGS=$CFLAGS
   wsprefix=`echo $WIRESHARK_PLUGIN_DIR | sed 's:/lib/.*$::'`
-  AC_CACHE_CHECK([how to find the Wireshark headers], 
+  AC_CACHE_CHECK([how to find the Wireshark headers],
     [mdw_cv_wireshark_includes], [
     mdw_cv_wireshark_includes=failed
     for i in \
@@ -228,7 +228,7 @@ if test "$wireshark" = true; then
   ])
   case $mdw_cv_wireshark_includes in
     failed) wireshark=false;;
-  esac  
+  esac
 fi
 
 if test "$wireshark" = true; then
@@ -243,9 +243,9 @@ if test "$wireshark" = false -a "$requirewireshark" = true; then
 fi
 
 AH_TEMPLATE([CONFIGDIR],
-            [Tripe should look here for keys and other configuration.])
+           [Tripe should look here for keys and other configuration.])
 AH_TEMPLATE([SOCKETDIR],
-            [Tripe should make its administration socket here.])
+           [Tripe should make its administration socket here.])
 mdw_DEFINE_PATHS([
   mdw_DEFINE_PATH([CONFIGDIR], [$configdir])
   mdw_DEFINE_PATH([SOCKETDIR], [$socketdir])
index a6c80e5ce2b1129752a5f02d087627d1a1e41b64..dc38e272d078531ab317f005699866dc812fa318 100644 (file)
@@ -2,7 +2,7 @@ tripe (1.0.0pre7) experimental; urgency=low
 
   * Support SLIP encapsulation.
 
- -- Mark Wooding <mdw@distorted.org.uk>  Sun,  4 Sep 2005 00:52:56 +0100
+ -- Mark Wooding <mdw@distorted.org.uk>         Sun,  4 Sep 2005 00:52:56 +0100
 
 tripe (1.0.0pre6) experimental; urgency=low
 
index f4679cc4c65ab0abe71535cb22ff738447c4cb2d..615e021a0837ff33987ac98f555344484fbe0361 100644 (file)
@@ -15,7 +15,7 @@ Description: Trivial IP Encryption: a simple virtual private network
  TrIPE is a simple VPN protocol.  It uses cryptography to ensure secrecy
  and authenticity of packets it sends and receives.
  .
- This package contains the main daemon, support programs, and documentation. 
+ This package contains the main daemon, support programs, and documentation.
  It ideally wants a 2.4 series kernel with the TUN/TAP driver enabled, but
  it will work with any kernel which speaks SLIP.
 
index 62d860f9a7a55baf3d42c7ddde6b5f2bb76aaa67..e1d863e320143a39d6dbdd00db0f767a238759e7 100755 (executable)
@@ -98,4 +98,4 @@ source:
        d=`pwd`; cd ..; dpkg-source -i -b $$d/deb-build/=deb=/*
        rm -rf deb-build/=deb=
 
-.PHONY: binary binary-arch binary-indep clean install source 
+.PHONY: binary binary-arch binary-indep clean install source
index 275768d7bcbe3a9265cf4c47332aa3f605e9d3cb..8f87cf6ebd2dabe0736a936f4eb3c1f68dbfc597 100644 (file)
@@ -1,6 +1,6 @@
 SETTING UP TRIPE FOR DEBIAN GNU/LINUX
 
-       Firstly, you need to set up public key parameters.  To generate 
+       Firstly, you need to set up public key parameters.  To generate
        a new set, run
 
          # cd /etc/tripe
index 285753729c63433f6356f0aa05a817ce5bfa04c0..7fff1530654d1faebb13a2dc831d08148f9206f7 100644 (file)
@@ -3,7 +3,7 @@
 set -e
 
 if [ "$1" = "purge" ] ; then
-        update-rc.d tripe remove >/dev/null
+       update-rc.d tripe remove >/dev/null
 fi
 
 #DEBHELPER#
index c613d4e63725c924f8d335d334f1a924097aefea..abeb5c857e602f178a27faf996fe27994bf3703f 100644 (file)
@@ -3,7 +3,7 @@
 set -e
 
 if [ -x "/etc/init.d/tripe" ]; then
-        invoke-rc.d tripe stop
+       invoke-rc.d tripe stop
 fi
 
 #DEBHELPER#
index d672771853c596bf2efceb8d001ab77b2259ca26..09073cc54035f4d116ac574d04909443c332c086 100644 (file)
 ## it under the terms of the GNU General Public License as published by
 ## the Free Software Foundation; either version 2 of the License, or
 ## (at your option) any later version.
-## 
+##
 ## TrIPE is distributed in the hope that it will be useful,
 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 ## GNU General Public License for more details.
-## 
+##
 ## You should have received a copy of the GNU General Public License
 ## along with TrIPE; if not, write to the Free Software Foundation,
 ## Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index f0f5bdb5e3f7c7a455a0b60c9b1b9529f1505d21..1de6d13f37dd9797748248ddba242abf490600c2 100644 (file)
@@ -45,7 +45,7 @@ pkstream \- forward UDP packets over streams
 .BR : \c
 .IR port ]
 .br
-       
+
 .IB addr : port
 .IB addr : port
 .SH "DESCRIPTION"
index 849a6622486cdffb72f7d3dbc5c0e330ceed6ebe..151ef91dbc45e17ac755634bececaf42425ca67a 100644 (file)
@@ -1,9 +1,9 @@
 .\" -*-nroff-*-
 .so tmac.rfc
 .
-.TL "Straylight/Edgeware"               "Mark Wooding"
-.TL "Request for Comments:  XXXX"       "Straylight/Edgeware"
-.TL ""                                  "11 April 2003"
+.TL "Straylight/Edgeware"              "Mark Wooding"
+.TL "Request for Comments:  XXXX"      "Straylight/Edgeware"
+.TL ""                                 "11 April 2003"
 .
 .TT XXXX Wooding "April 2003" \
   "TrIPE: The Trivial IP Encryption Protocol"
@@ -52,7 +52,7 @@ registered for TrIPE yet.
 .P
 When a pair of peer hosts are made aware of each other, they begin a key
 negotiation, using an authenticated Diffie-Hellman key exchange
-protocol.  This enables them to agree a 
+protocol.  This enables them to agree a
 .I keyset :
 a collection of short-term symmetric keys and other parameters (such as
 sequence numbering spaces).  Keysets expire after a fixed amount of
@@ -91,7 +91,7 @@ and
 .B "\\$1" \c
 .if !'\\$2'.' \ \\$2\c
 .if !'\\$3'' \{\
-: 
+:
 .I "\\$3" \c
 .\}
 ..
@@ -106,7 +106,7 @@ and
 .LS 2n
 ..
 .P
-We need to deal with a number of data items during the protocol.  
+We need to deal with a number of data items during the protocol.
 .if t \{\
 Object names are given in
 .I italics .
@@ -117,7 +117,7 @@ indicates the peer's corresponding value.  If a compound data item name
 is primed, toggle the primed-ness of the components.
 .P
 Data objects are given types which determine their representation in
-protocol messages.  Type names are given in 
+protocol messages.  Type names are given in
 .B UPPERCASE .
 .P
 .T1 "Atomic data items"
@@ -144,12 +144,12 @@ be the integer to be represented, and let
 be the number of octets required to represent
 .I n
 in base-256 format with no leading zeroes, except that if
-.I n 
+.I n
 = 0
-then 
+then
 .I z
 = 1; in other cases,
-.I z 
+.I z
 is the unique integer such that
 .ie t 256\*(^(\fIz\fP\-1\*(^) \(<= \fIn\fP < 256\*(^(\fIz\fP\*(^).
 .el 256^{z-1} <= n < 256^z.
index 94c7c3b8496558fa3afde06f6747c383025a5864..7fb59c3e0d70630aa2fd691a5a555fdb8e20212d 100644 (file)
@@ -120,12 +120,12 @@ option.  From this point on, the server is ready to process more
 commands and reply to them.
 .PP
 Responses to background commands are indicated by a line beginning with
-one of the tokens 
+one of the tokens
 .BR BGOK ,
 .BR BGFAIL ,
 or
 .BR BGINFO ,
-followed by the command tag.  These correspond to the 
+followed by the command tag.  These correspond to the
 .BR OK ,
 .BR FAIL ,
 and
@@ -257,7 +257,7 @@ one to an
 .B INFO
 line, in a fixed-column format.  Column zero contains the key letter for
 selecting that message type; column one contains either a space or a
-.RB ` + ' 
+.RB ` + '
 sign, if the message type is disabled or enabled respectively; and a
 textual description of the message type begins at column 3 and continues
 to the end of the line.
@@ -360,7 +360,7 @@ Causes the server to emit an
 line for each command it supports.  Each line lists the command name,
 followed by the names of the arguments.  This may be helpful as a memory
 aid for interactive use, or for program clients probing for features.
-.SP 
+.SP
 .BI "IFNAME " peer
 Emits an
 .B INFO
@@ -389,7 +389,7 @@ line is written containing the peer's name, as given to
 .BR ADD .
 .SP
 .BI "NOTIFY " tokens\fR...
-Issues a 
+Issues a
 .B USER
 notification to all interested administration clients.
 .SP
@@ -420,7 +420,7 @@ line is printed describing the outcome:
 .RS
 .TP
 .BI "ping-ok " millis
-A response was received 
+A response was received
 .I millis
 after the ping was sent.
 .TP
@@ -516,7 +516,7 @@ is provided; otherwise the command fails with the error
 .BR "service-exists" .
 .SP
 .BI "SVCENSURE " service " \fR[" version \fR]
-Ensure that 
+Ensure that
 .I service
 is provided, and (if specified) to at least the given
 .IR version .
@@ -530,7 +530,7 @@ Send a
 .BR BGFAIL )
 response to the service job with the given
 .IR jobid ,
-passing the 
+passing the
 .I tokens
 as the reason for failure.  The job is closed.
 .SP
@@ -615,7 +615,7 @@ The statistics-gathering is experimental and subject to change.
 .SP
 .BR "TRACE " [\fIoptions\fP]
 Selects trace outputs: see
-.B "Trace lists" 
+.B "Trace lists"
 above.  Message types provided are:
 .RS
 .PP
@@ -699,7 +699,7 @@ is reserved to the Straylight/Edgeware implementation.
 Enables or disables asynchronous broadcasts
 .IR "for the current connection only" .
 See
-.B "Trace lists" 
+.B "Trace lists"
 above.  The default watch state for the connection the server opens
 automatically on stdin/stdout is to show warnings and trace messages;
 other connections show no asynchronous broadcast messages.  (This is
@@ -726,7 +726,7 @@ All of the above.
 .RE
 .SP
 .BI "WARN " tokens\fR...
-Issues a 
+Issues a
 .B USER
 warning to all interested administration clients.
 .SH "ERROR MESSAGES"
@@ -757,7 +757,7 @@ of arguments was wrong.
 The
 .I word
 is not a valid time interval specification.  Acceptable time
-specifications are nonnegative integers followed optionally by 
+specifications are nonnegative integers followed optionally by
 .BR d ,
 .BR h ,
 .BR m ,
@@ -787,7 +787,7 @@ An error occurred during the attempt to become a daemon, as reported by
 The given port number is out of range.
 .SP
 .BI "not-service-provider " service
-(For 
+(For
 .BR SVCRELEASE .)
 The invoking client is not the current provider of the named
 .IR service ,
@@ -870,7 +870,7 @@ There is no peer called
 .BR ADD .)
 The port name
 .I port
-couldn't be found in 
+couldn't be found in
 .BR /etc/services .
 .TP
 .BI "unknown-service " service
@@ -1028,7 +1028,7 @@ there was a problem with the file, usually there will have been
 warnings before this.
 .SP
 .BI "KEYMGMT bad-public-keyring " message
-The public keyring couldn't be read.  Usually, there will have been 
+The public keyring couldn't be read.  Usually, there will have been
 .B key-file-error
 warnings before this.
 .SP
@@ -1125,7 +1125,7 @@ hard asymmetric crypto sums.
 .BI "KX " peer " unexpected " msgtoken
 The message received wasn't appropriate for this stage of the key
 exchange process.  This may mean that one of our previous packets got
-lost.  For 
+lost.  For
 .BR pre-challenge ,
 it may simply mean that the peer has recently restarted.
 .SP
@@ -1141,7 +1141,7 @@ An unknown key-exchange message arrived.
 .SS "PEER warnings"
 These are largely concerned with management of peers and the low-level
 details of the network protocol.  The second word is usually the name of
-a peer, or 
+a peer, or
 .RB ` \- '
 if none is relevant.
 .SP
@@ -1259,7 +1259,7 @@ if none.
 .SP
 .BI "TUN \- bsd no-tunnel-devices"
 The driver couldn't find an available tunnel device.  Maybe if you
-create some more 
+create some more
 .BI /dev/tun nn
 files, it will work.
 .SP
index 92b1aef229d74565594f2fed54140079aa4fa847..bebe3312370a8927e891b5cfa84d14af5554b4b4 100644 (file)
@@ -79,7 +79,7 @@ key-exchange keys, stored in
 .PP
 The master authority has a configuration file
 .BR tripe-keys.master ,
-usually created by copying the template provided and editing it.  
+usually created by copying the template provided and editing it.
 .PP
 The published repository consists of a tarball of the
 .B repos
@@ -97,7 +97,7 @@ it's checking the right key.
 A peer starts by downloading a copy of
 .B tripe-keys.conf
 and then making sure it's authentic.  (This is one of the tricky bits.
-The other is getting public keys back to the master authority.)  This is
+The other is getting public keys back to the master authority.)         This is
 enough for the peer to fetch a copy of the repository, verify the
 signature, and assemble a public keyring for the other peers in the
 network.
@@ -142,7 +142,7 @@ option.  With an argument, shows help about that
 .IR command .
 .TP
 .B "setup"
-Constructs a new repository and makes a signing key (as for 
+Constructs a new repository and makes a signing key (as for
 .BR newmaster )
 and key-exchange parameters.  Fails if
 .B repos
@@ -180,7 +180,7 @@ all is well, it replaces the current
 .B repos
 directory with the version in the new archive, and if necessary it
 replaces the current configuration file with the new one in the
-archive.  It then does a 
+archive.  It then does a
 .B rebuild
 to construct a new
 .B keyring.pub
index dccb8557d03de17188e7d7276a22b08a56a60ab6..70bd356ea33e4825376425291c2cac2cd8bacb2c 100644 (file)
@@ -55,7 +55,7 @@ substitutions, of the form
 .BI ${ name } \fR,
 which are replaced by the value assigned to
 .IR name .
-Many 
+Many
 .IR name s
 have significance to the
 .B tripe-keys
@@ -116,7 +116,7 @@ set up automatically.
 .TP
 .I kx
 Key-exchange algorithm to use.  Either
-.B dh 
+.B dh
 (integer Diffie-Hellman)
 or
 .B ec
@@ -184,7 +184,7 @@ is
 .BR ec .
 .TP
 .I sig-genalg
-Key-generation algorithm for signing key.  Default depends on 
+Key-generation algorithm for signing key.  Default depends on
 .I sig
 as follows.
 .TS
index f7f53433df0501cfed5d10819129ffe55c12cc8b..843d1853a4cef3be2a4dc02a3caead458c5035eb 100644 (file)
@@ -95,7 +95,7 @@ Both
 .I local-port
 and
 .I remote-port
-must be numbers; 
+must be numbers;
 .I remote-addr
 may be a hostname or an IP address in dotted-quad format.  Exactly two
 .B peer
@@ -129,7 +129,7 @@ Apply a given filter to packets received from the right peer.
 Begin the next branch of the first fork filter node named
 .I tag
 in each filter chain.  See below for more about filter chains.
-.TP 
+.TP
 .BI flood\fR[\fP: type : millis : size\fR]
 Flood both peers with random packets.  If
 .I type
index e58c28cf4acf665473cbffeb30b1c03eeab65dbb..b287673a9344b486f89168705dd81dbc24159f8d 100644 (file)
@@ -44,7 +44,7 @@ tripe \- a simple VPN daemon
 .RB [ \-n
 .IR tunnel ]
 .br
-       
+
 .RB [ \-U
 .IR user ]
 .RB [ \-G
@@ -54,7 +54,7 @@ tripe \- a simple VPN daemon
 .RB [ \-T
 .IR trace-opts ]
 .br
-       
+
 .RB [ \-k
 .IR priv-keyring ]
 .RB [ \-K
@@ -510,7 +510,7 @@ If the
 is omitted, the same file descriptor is used for input and output.
 .PP
 The dynamic allocation script must be named by an absolute or relative
-pathname, beginning with 
+pathname, beginning with
 .RB ` / '
 or
 .RB ` . '.
index d46dd33db5f82666e56f3ff3735252a22df806bd..9c1143779a2566d6c1e8ae4c5cf73f4fe4d98783 100644 (file)
@@ -156,7 +156,7 @@ server on its command line.  Arguments added using this option are added
 .I after
 any passed automatically by
 .B tripectl
-(e.g., 
+(e.g.,
 .BR \-a ).
 .TP
 .B "\-l, \-\-syslog"
@@ -218,7 +218,7 @@ responses are ignored.
 .SS "Starting the tripe server"
 If any of the options
 .BR \-s ,
-.B \-p 
+.B \-p
 or
 .B \-S
 are given,
index 7f531ccdaa69ff5db0b44c65f4acfa40f05391d2..45f705d6c5b8293466f913cfb541d43083fc89df 100644 (file)
@@ -43,7 +43,7 @@ The
 .B tripemon
 program is a fairly simple graphical monitor program for TrIPE.  It's
 not ever-so user-friendly in some ways, but it works fairly well.  A
-perusal of 
+perusal of
 .BR tripe-admin (5)
 would help you understand it better.  That said, describing the program
 in detail is probably less interesting than letting you explore it for
index 8d1c2a94f7dba115f0b4e12f05c11ef321f3140c..880ae90024177b40b8dff18c2951255391d1ddf2 100644 (file)
@@ -186,7 +186,7 @@ order.
   with the property that, for any $K \in \keys \mathcal{E}$, any plaintext
   message $x$, and any ciphertext $y$ returned as a result of $E_K(x)$, we
   have $D_K(y) = x$.
-\end{definition}  
+\end{definition}
 
 \begin{definition}[Chosen plaintext security for symmetric encryption]
   \label{def:sym-cpa}
@@ -239,10 +239,10 @@ $g^\gamma$.  This is the \emph{decision Diffie-Hellman problem}
     \begin{eqnalign}[rl]
       \Adv{ddh}{G}(A) =
       & \Pr[\alpha \getsr \Nupto{q}; \beta \getsr \Nupto{q} :
-            A(g^\alpha, g^\beta, g^{\alpha\beta}) = 1] - {} \\
+           A(g^\alpha, g^\beta, g^{\alpha\beta}) = 1] - {} \\
       & \Pr[\alpha \getsr \Nupto{q}; \beta \getsr \Nupto{q};
-            \gamma \getsr \Nupto{q} :
-            A(g^\alpha, g^\beta, g^\gamma) = 1].
+           \gamma \getsr \Nupto{q} :
+           A(g^\alpha, g^\beta, g^\gamma) = 1].
     \end{eqnalign}
   \end{equation}
   The \emph{insecurity function of the decision Diffie-Hellman problem in
@@ -362,7 +362,7 @@ and then decrypts the ciphertext $y$.
     Function $\id{decrypt}(k, \id{ty}, c)$: \+ \\
       $(i, y, \tau) \gets c$; \\
       \IF $V_{k.\Xid{K}{mac-in}}((\id{ty}, i, y), \tau) = 0$ \THEN \\ \ind
-        \RETURN $\bot$; \- \\
+       \RETURN $\bot$; \- \\
       \IF $i < k.\id{seq-in}$ \THEN \RETURN $\bot$; \\
       $m \gets D_{k.\Xid{K}{enc-in}}(y)$; \\
       $k.\id{seq-in} \gets i + 1$; \\
@@ -411,28 +411,28 @@ in figure~\ref{fig:kx-support}.
 
 \begin{table}
   \begin{tabularx}{\textwidth}{Mr X}
-    G                     & A cyclic group known by all participants \\
-    q = |G|               & The prime order of $G$ \\
-    g                     & A generator of $G$ \\
-    E_K(\cdot)            & Encryption under key $K$, here used to denote
-                            application of the $\id{encrypt}(K, \cdot)$
-                            operation \\ 
+    G                    & A cyclic group known by all participants \\
+    q = |G|              & The prime order of $G$ \\
+    g                    & A generator of $G$ \\
+    E_K(\cdot)           & Encryption under key $K$, here used to denote
+                           application of the $\id{encrypt}(K, \cdot)$
+                           operation \\
     \alpha \inr \Nupto{q} & Alice's private key \\
-    a = g^{\alpha}        & Alice's public key \\
+    a = g^{\alpha}       & Alice's public key \\
     \rho_A \inr \Nupto{q} & Alice's secret Diffie-Hellman value \\
-    r_A = g^{\rho_A}      & Alice's public \emph{challenge} \\
+    r_A = g^{\rho_A}     & Alice's public \emph{challenge} \\
     c_A = H(\cookie{cookie}, r_A)
-                          & Alice's \emph{cookie} \\
+                         & Alice's \emph{cookie} \\
     v_A = \rho_A \xor H(\cookie{expected-reply}, r_A, r_B, b^{\rho_A})
-                          & Alice's challenge \emph{check value} \\
+                         & Alice's challenge \emph{check value} \\
     r_B^\alpha = a^{\rho_B}
-                          & Alice's reply \\
+                         & Alice's reply \\
     K = r_B^{\rho_A} = r_B^{\rho_A} = g^{\rho_A\rho_B}
-                          & Alice and Bob's shared secret key \\
+                         & Alice and Bob's shared secret key \\
     w_A = H(\cookie{switch-request}, c_A, c_B)
-                          & Alice's \emph{switch request} value \\
+                         & Alice's \emph{switch request} value \\
     u_A = H(\cookie{switch-confirm}, c_A, c_B)
-                          & Alice's \emph{switch confirm} value \\
+                         & Alice's \emph{switch confirm} value \\
   \end{tabularx}
 
   \caption{Names used during key-exchange}
@@ -452,7 +452,7 @@ in figure~\ref{fig:kx-support}.
   \caption{Message contents, as sent by Alice}
   \label{tab:kx-messages}
 \end{table}
-  
+
 \begin{messages}
 \item[kx-pre-challenge] Contains a plain statement of Alice's challenge.
   This is Alice's first message of a session.
@@ -641,33 +641,33 @@ clog up all of Alice's slots.
       $\id{send}(\cookie{kx-pre-challenge}, r_A)$; \- \\[\medskipamount]
     Procedure $\id{kx-receive}(\id{type}, \id{data})$: \\ \ind
       \IF $\id{type} = \cookie{kx-pre-challenge}$ \THEN \\ \ind
-        \id{msg-pre-challenge}(\id{data}); \- \\
+       \id{msg-pre-challenge}(\id{data}); \- \\
       \ELSE \IF $\id{type} = \cookie{kx-cookie}$ \THEN \\ \ind
-        \id{msg-cookie}(\id{data}); \- \\
+       \id{msg-cookie}(\id{data}); \- \\
       \ELSE \IF $\id{type} = \cookie{kx-challenge}$ \THEN \\ \ind
-        \id{msg-challenge}(\id{data}); \- \\
+       \id{msg-challenge}(\id{data}); \- \\
       \ELSE \IF $\id{type} = \cookie{kx-reply}$ \THEN \\ \ind
-        \id{msg-reply}(\id{data}); \- \\
+       \id{msg-reply}(\id{data}); \- \\
       \ELSE \IF $\id{type} = \cookie{kx-switch}$ \THEN \\ \ind
-        \id{msg-switch}(\id{data}); \- \\
+       \id{msg-switch}(\id{data}); \- \\
       \ELSE \IF $\id{type} = \cookie{kx-switch-ok}$ \THEN \\ \ind
-        \id{msg-switch-ok}(\id{data}); \-\- \\[\medskipamount]
+       \id{msg-switch-ok}(\id{data}); \-\- \\[\medskipamount]
     Procedure $\id{msg-pre-challenge}(\id{data})$: \+ \\
       \IF $\id{state} \ne \cookie{challenge}$ \THEN \RETURN; \\
       $r \gets \id{data}$; \\
       \IF $\Xid{n}{chal} \ge \Xid{n}{chal-thresh}$ \THEN \\ \ind
-        $\id{send}(\cookie{kx-cookie}, r_A, \id{cookie}(r_A)))$; \- \\
+       $\id{send}(\cookie{kx-cookie}, r_A, \id{cookie}(r_A)))$; \- \\
       \ELSE \+ \\
-        $\id{new-chal}(r)$; \\
-        $\id{send}(\cookie{kx-challenge}, r_A,
-                   \id{cookie}(r), \id{checkval}(r))$; \-\-\\[\medskipamount]
+       $\id{new-chal}(r)$; \\
+       $\id{send}(\cookie{kx-challenge}, r_A,
+                  \id{cookie}(r), \id{checkval}(r))$; \-\-\\[\medskipamount]
     Procedure $\id{msg-cookie}(\id{data})$: \+ \\
       \IF $\id{state} \ne \cookie{challenge}$ \THEN \RETURN; \\
       $(r, c_A) \gets \id{data}$; \\
       \IF $c_A \ne \id{cookie}(r_A)$ \THEN \RETURN; \\
       $\id{new-chal}(r)$; \\
       $\id{send}(\cookie{kx-challenge}, r_A,
-                 \id{cookie}(r), \id{checkval}(r))$; \- \\[\medskipamount]
+                \id{cookie}(r), \id{checkval}(r))$; \- \\[\medskipamount]
     Procedure $\id{msg-challenge}(\id{data})$: \+ \\
       \IF $\id{state} \ne \cookie{challenge}$ \THEN \RETURN; \\
       $(r, c_A, v) \gets \id{data}$; \\
@@ -677,7 +677,7 @@ clog up all of Alice's slots.
       $k \gets \id{chal-tab}[i].k$; \\
       $y \gets \id{encrypt}(k, \cookie{kx-reply}, r^\alpha)$; \\
       $\id{send}(\cookie{kx-reply}, c_A, \id{cookie}(r),
-                 \id{checkval}(r), y)$
+                \id{checkval}(r), y)$
     \next
     Procedure $\id{msg-reply}(\id{data})$: \+ \\
       $(c, c_A, v, y) \gets \id{data}$; \\
@@ -685,7 +685,7 @@ clog up all of Alice's slots.
       $i \gets \id{find-chal}(c)$; \\
       \IF $i = \bot$ \THEN \RETURN; \\
       \IF $\id{check-reply}(i, \id{chal-tab}[i].r, v) = \bot$ \THEN \\ \ind
-        \RETURN; \- \\
+       \RETURN; \- \\
       $k \gets \id{chal-tab}[i].k$; \\
       $x \gets \id{decrypt}(k, \cookie{kx-reply}, y)$; \\
       \IF $x = \bot$ \THEN \RETURN; \\
@@ -706,8 +706,8 @@ clog up all of Alice's slots.
       \IF $x = \bot$ \THEN \RETURN; \\
       $(x, w) \gets x$; \\
       \IF $\id{state} = \cookie{challenge}$ \THEN \\ \ind
-        \IF $x \ne b^{\rho_A}$ \THEN \RETURN; \\
-        $\id{chal-commit} \gets \id{chal-tab}[i]$; \- \\
+       \IF $x \ne b^{\rho_A}$ \THEN \RETURN; \\
+       $\id{chal-commit} \gets \id{chal-tab}[i]$; \- \\
       \ELSE \IF $c \ne \id{chal-commit}.c$ \THEN \RETURN; \\
       \IF $w \ne H(\cookie{switch-request}, c, c_A)$ \THEN \RETURN; \\
       $w \gets H(\cookie{switch-confirm}, c_A, c)$; \\
@@ -736,13 +736,13 @@ clog up all of Alice's slots.
       $r$; $c$; $\id{replied}$; $k$; \- \\[\medskipamount]
     Function $\id{find-chal}(c)$: \+ \\
       \FOR $i = 0$ \TO $\Xid{n}{chal}$ \DO \\ \ind
-        \IF $\id{chal-tab}[i].c = c$ \THEN \RETURN $i$; \- \\
+       \IF $\id{chal-tab}[i].c = c$ \THEN \RETURN $i$; \- \\
       \RETURN $\bot$; \- \\[\medskipamount]
     Function $\id{cookie}(r)$: \+ \\
       \RETURN $H(\cookie{cookie}, r)$; \- \\[\medskipamount]
     Function $\id{check-reply}(i, r, v)$: \+ \\
       \IF $i \ne \bot \land \id{chal-tab}[i].\id{replied} = 1$ \THEN \\ \ind
-        \RETURN $i$; \- \\
+       \RETURN $i$; \- \\
       $\rho \gets v \xor H(\cookie{expected-reply}, r, r_A, r^\alpha)$; \\
       \IF $g^\rho \ne r$ \THEN \RETURN $\bot$; \\
       \IF $i = \bot$ \THEN $i \gets \id{new-chal}(r)$; \\
@@ -752,17 +752,17 @@ clog up all of Alice's slots.
     \next
     Function $\id{checkval}(r)$: \\ \ind
       \RETURN $\rho_A \xor H(\cookie{expected-reply},
-                             r_A,r, b^{\rho_A})$; \- \\[\medskipamount]
+                            r_A,r, b^{\rho_A})$; \- \\[\medskipamount]
     Function $\id{new-chal}(r)$: \+ \\
       $c \gets \id{cookie}(r)$; \\
       $i \gets \id{find-chal}(c)$; \\
       \IF $i \ne \bot$ \THEN \RETURN $i$; \\
       \IF $\Xid{n}{chal} < \Xid{n}{chal-max}$ \THEN \\ \ind
-        $i \gets \Xid{n}{chal}$; \\
-        $\id{chal-tab}[i] \gets \NEW \id{chal-slot}$; \\
-        $\Xid{n}{chal} \gets \Xid{n}{chal} + 1$; \- \\
+       $i \gets \Xid{n}{chal}$; \\
+       $\id{chal-tab}[i] \gets \NEW \id{chal-slot}$; \\
+       $\Xid{n}{chal} \gets \Xid{n}{chal} + 1$; \- \\
       \ELSE \\ \ind
-        $i \getsr [\Xid{n}{chal-max}]$; \- \\
+       $i \getsr [\Xid{n}{chal-max}]$; \- \\
       $\id{chal-tab}[i].r \gets r$; \\
       $\id{chal-tab}[i].c \gets c$; \\
       $\id{chal-tab}[i].\id{replied} \gets 0$; \\
@@ -835,7 +835,7 @@ See figure~\ref{fig:cbc} for a diagram of CBC encryption.
   \caption{Encryption using CBC mode}
   \label{fig:cbc}
 \end{figure}
-    
+
 \begin{definition}[CBC mode]
   \label{def:cbc}
   Let $P\colon \keys P \times \Bin^\ell to \Bin^\ell$ be a pseudorandom
@@ -848,20 +848,20 @@ See figure~\ref{fig:cbc} for a diagram of CBC encryption.
       $I \getsr \Bin^\ell$; \\
       $y \gets I$; \\
       \FOR $i = 0$ \TO $|x|/\ell$ \DO \\ \ind
-        $x_i \gets x[\ell i \bitsto \ell (i + 1)]$; \\
-        $y_i \gets P_K(x_i \xor I)$; \\
-        $I \gets y_i$; \\
-        $y \gets y \cat y_i$; \- \\
+       $x_i \gets x[\ell i \bitsto \ell (i + 1)]$; \\
+       $y_i \gets P_K(x_i \xor I)$; \\
+       $I \gets y_i$; \\
+       $y \gets y \cat y_i$; \- \\
       \RETURN $y$;
     \next
     Algorithm $\Xid{D}{CBC}^P_K(y)$: \+ \\
       $I \gets y[0 \bitsto \ell]$; \\
       $x \gets \emptystring$; \\
       \FOR $1 = 0$ \TO $|y|/\ell$ \DO \\ \ind
-        $y_i \gets y[\ell i  \bitsto  \ell (i + 1)]$; \\
-        $x_i \gets P^{-1}_K(y_i) \xor I$; \\
-        $I \gets y_i$; \\
-        $x \gets x \cat x_i$; \- \\
+       $y_i \gets y[\ell i  \bitsto  \ell (i + 1)]$; \\
+       $x_i \gets P^{-1}_K(y_i) \xor I$; \\
+       $I \gets y_i$; \\
+       $x \gets x \cat x_i$; \- \\
       \RETURN $x$;
   \end{program}
 \end{definition}
@@ -925,39 +925,39 @@ figure~\ref{fig:cbc-steal} for a diagram.
       "e" [dd] ="x"
       "i" [uu] ="y"
       []!{"x"; "e" **{}, "x"+/4pt/ ="p",
-          "x"; "y" **{}, "x"+/4pt/ ="q",
-          "y"; "x" **{}, "y"+/4pt/ ="r",
-          "y"; "i" **{}, "y"+/4pt/ ="s",
-          "e";
-          "p" **\dir{-};
-          "q" **\crv{"x"};
-          "r" **\dir{-};
-          "s" **\crv{"y"};
-          "i" **\dir{-}?>*\dir{>}}
+         "x"; "y" **{}, "x"+/4pt/ ="q",
+         "y"; "x" **{}, "y"+/4pt/ ="r",
+         "y"; "i" **{}, "y"+/4pt/ ="s",
+         "e";
+         "p" **\dir{-};
+         "q" **\crv{"x"};
+         "r" **\dir{-};
+         "s" **\crv{"y"};
+         "i" **\dir{-}?>*\dir{>}}
       "xor" :[dd] *+[F]{E}="e"
       "e" [l] {K} :"e"
       "e" [dddddlll] *+=(1, 0)+[F]{\mathstrut y_{n-2}}="i"
       "e" [dd] ="x"
       "i" [uu] ="y"
       []!{"x"; "e" **{}, "x"+/4pt/ ="p",
-          "x"; "y" **{}, "x"+/4pt/ ="q",
-          "y"; "x" **{}, "y"+/4pt/ ="r",
-          "y"; "i" **{}, "y"+/4pt/ ="s",
-          "x"; "y" **{} ?="c" ?(0.5)/-4pt/ ="cx" ?(0.5)/4pt/ ="cy",
-          "e";
-          "p" **\dir{-};
-          "q" **\crv{"x"};
-          "cx" **\dir{-};
-          "c" *[@]\cir<4pt>{d^u};
-          "cy";
-          "r" **\dir{-};
-          "s" **\crv{"y"};
-          "i" **\dir{-}?>*\dir{>}}
+         "x"; "y" **{}, "x"+/4pt/ ="q",
+         "y"; "x" **{}, "y"+/4pt/ ="r",
+         "y"; "i" **{}, "y"+/4pt/ ="s",
+         "x"; "y" **{} ?="c" ?(0.5)/-4pt/ ="cx" ?(0.5)/4pt/ ="cy",
+         "e";
+         "p" **\dir{-};
+         "q" **\crv{"x"};
+         "cx" **\dir{-};
+         "c" *[@]\cir<4pt>{d^u};
+         "cy";
+         "r" **\dir{-};
+         "s" **\crv{"y"};
+         "i" **\dir{-}?>*\dir{>}}
   \end{graph} \]
 
   \caption{Encryption using CBC mode with ciphertext stealing}
   \label{fig:cbc-steal}
-\end{figure}  
+\end{figure}
 
 \begin{definition}[CBC stealing]
   \label{def:cbc-steal}
@@ -974,34 +974,34 @@ figure~\ref{fig:cbc-steal} for a diagram.
       $t = |x| \bmod \ell$; \\
       \IF $t \ne 0$ \THEN $x \gets x \cat 0^{\ell-t}$; \\
       \FOR $i = 0$ \TO $|x|/\ell$ \DO \\ \ind
-        $x_i \gets x[\ell i \bitsto \ell (i + 1)]$; \\
-        $y_i \gets P_K(x_i \xor I)$; \\
-        $I \gets y_i$; \\
-        $y \gets y \cat y_i$; \- \\
+       $x_i \gets x[\ell i \bitsto \ell (i + 1)]$; \\
+       $y_i \gets P_K(x_i \xor I)$; \\
+       $I \gets y_i$; \\
+       $y \gets y \cat y_i$; \- \\
       \IF $t \ne 0$ \THEN \\ \ind
-        $b \gets |y| - 2\ell$; \\
-        $y \gets $\=$y[0 \bitsto b] \cat
-                     y[b + \ell \bitsto |y|] \cat {}$ \\
-                  \>$y[b \bitsto b + t]$; \- \\
+       $b \gets |y| - 2\ell$; \\
+       $y \gets $\=$y[0 \bitsto b] \cat
+                    y[b + \ell \bitsto |y|] \cat {}$ \\
+                 \>$y[b \bitsto b + t]$; \- \\
       \RETURN $y$;
     \next
     Algorithm $\Xid{D}{CBC-steal}^P_K(y)$: \+ \\
       $I \gets y[0 \bitsto \ell]$; \\
       $t = |y| \bmod \ell$; \\
       \IF $t \ne 0$ \THEN \\ \ind
-        $b \gets |y| - t - \ell$; \\
-        $z \gets P^{-1}_K(y[b \bitsto b + \ell])$; \\
-        $y \gets $\=$y[0 \bitsto b] \cat
-                     y[b + \ell \bitsto |y|] \cat {}$ \\
-                  \>$z[t \bitsto \ell]$; \- \\
+       $b \gets |y| - t - \ell$; \\
+       $z \gets P^{-1}_K(y[b \bitsto b + \ell])$; \\
+       $y \gets $\=$y[0 \bitsto b] \cat
+                    y[b + \ell \bitsto |y|] \cat {}$ \\
+                 \>$z[t \bitsto \ell]$; \- \\
       $x \gets \emptystring$; \\
       \FOR $1 = 0$ \TO $|y|/\ell$ \DO \\ \ind
-        $y_i \gets y[\ell i \bitsto \ell (i + 1)]$; \\
-        $x_i \gets P^{-1}_K(y_i) \xor I$; \\
-        $I \gets y_i$; \\
-        $x \gets x \cat x_i$; \- \\
+       $y_i \gets y[\ell i \bitsto \ell (i + 1)]$; \\
+       $x_i \gets P^{-1}_K(y_i) \xor I$; \\
+       $I \gets y_i$; \\
+       $x \gets x \cat x_i$; \- \\
       \IF $t \ne 0$ \THEN \\ \ind
-        $x \gets x \cat z[0 \bitsto t] \xor y[b \bitsto b + t]$; \- \\
+       $x \gets x \cat z[0 \bitsto t] \xor y[b \bitsto b + t]$; \- \\
       \RETURN $x$;
   \end{program}
 \end{definition}
@@ -1038,9 +1038,9 @@ figure~\ref{fig:cbc-steal} for a diagram.
     Function $\id{steal}(l, y)$: \+ \\
       $t \gets l \bmod \ell$; \\
       \IF $t \ne 0$ \THEN \\ \ind
-        $b \gets |y| - 2\ell$; \\
-        $y \gets $\=$y[0 \bitsto b] \cat
-                     y[b + \ell \bitsto |y|] \cat y[b \bitsto b + t]$; \- \\
+       $b \gets |y| - 2\ell$; \\
+       $y \gets $\=$y[0 \bitsto b] \cat
+                    y[b + \ell \bitsto |y|] \cat y[b \bitsto b + t]$; \- \\
       \RETURN $y$;
   \end{program}
   Comparing this to definition~\ref{def:cbc-steal} shows that $A'$ simlates
@@ -1093,9 +1093,9 @@ $2^\ell$ possible values for $y^*$ and in the second there are $2^\ell - n +
   \Pr[C_n]
   & = \sum_{x \in \Bin^\ell} \Pr[C_n \mid x^* = x] \Pr[x^* = x] \\
   & = \sum_{x \in \Bin^\ell}
-          \Pr[x^* = x] \sum_{0\le i<n} \Pr[y^* = z_i \xor x] \\
+         \Pr[x^* = x] \sum_{0\le i<n} \Pr[y^* = z_i \xor x] \\
   & \le \sum_{0\le i<n} \frac{1}{2^\ell - n}
-        \sum_{x \in \Bin^\ell} \Pr[x^* = x] \\
+       \sum_{x \in \Bin^\ell} \Pr[x^* = x] \\
   & = \frac{n}{2^\ell - n}
 \end{eqnarray}
 
@@ -1141,7 +1141,7 @@ as required.
 \bibliography{mdw-crypto,cryptography,cryptography2000,rfc}
 \end{document}
 
-%%% Local Variables: 
+%%% Local Variables:
 %%% mode: latex
 %%% TeX-master: "wrestlers"
 %%% End:
index 4173b42254b765ed6244aca143a4280ae9d50f3c..dae92e1e2e0da063e1e5dd2171fb568150d66451 100644 (file)
 ## it under the terms of the GNU General Public License as published by
 ## the Free Software Foundation; either version 2 of the License, or
 ## (at your option) any later version.
-## 
+##
 ## TrIPE is distributed in the hope that it will be useful,
 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 ## GNU General Public License for more details.
-## 
+##
 ## You should have received a copy of the GNU General Public License
 ## along with TrIPE; if not, write to the Free Software Foundation,
 ## Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index ddede1054e204ca8fe83a3941944082d9026df37..bac4e7f2dc7d851c8f5a81892b603d7b0b88c4ad 100755 (executable)
@@ -106,7 +106,7 @@ case ${tunnel-`$tripe --tunnels | head -1`} in
     fi
     ;;
 esac
-  
+
 # --- Do what was wanted ---
 
 case "$1" in
@@ -140,10 +140,10 @@ case "$1" in
       [ -x $i ] || continue
       name=`basename $i`
       case $name in *~|\#*) continue;; esac
-      if $i; then 
+      if $i; then
        echo -n " $name"
       else
-        echo -n " ($name failed)"
+       echo -n " ($name failed)"
       fi
     done
     echo " done"
index 398a299e1485bdd4bddc7163e6327b0d50090677..1997036678e40b7909bd65ed09fef9dd893b06c5 100644 (file)
 ## it under the terms of the GNU General Public License as published by
 ## the Free Software Foundation; either version 2 of the License, or
 ## (at your option) any later version.
-## 
+##
 ## TrIPE is distributed in the hope that it will be useful,
 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 ## GNU General Public License for more details.
-## 
+##
 ## You should have received a copy of the GNU General Public License
 ## along with TrIPE; if not, write to the Free Software Foundation,
 ## Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index 6da6eb4a0c008d346a14e647e7aa922a02b0eb7a..9ca903c5785fbf33fd23565fc1262cbe06e4ff2b 100644 (file)
@@ -182,9 +182,9 @@ Key management utility for TrIPE.
 
 Options supported:
 
--h, --help             Show this help message.
--v, --version          Show the version number.
--u, --usage            Show pointlessly short usage string.
+-h, --help              Show this help message.
+-v, --version           Show the version number.
+-u, --usage             Show pointlessly short usage string.
 
 Subcommands available:
 """
@@ -279,7 +279,7 @@ def cmd_upload(args):
       OS.rename(new, base)
   finally:
     OS.chdir(cwd)
-    rmtree('tmp')    
+    rmtree('tmp')
 
 def cmd_update(args):
   cwd = OS.getcwd()
@@ -343,7 +343,7 @@ def cmd_clean(args):
 ### Main driver
 
 class UsageError (Exception): pass
-  
+
 commands = {'help': (cmd_help, 0, 1, ''),
             'newmaster': (cmd_newmaster, 0, 0, ''),
             'setup': (cmd_setup, 0, 0, ''),
index 2b59cf9fa27896c040a3cc549717853fdabeb477..eef2a00c4342037bcf10057d6154d59178d2c34d 100644 (file)
@@ -41,8 +41,8 @@
 ### Master key integrity
 
 # Since the master public key is contained within the repository, we must
-# check its integrity: therefore we record its sequence number and 
-# fingerprint here.  These are filled in automatically by 
+# check its integrity: therefore we record its sequence number and
+# fingerprint here.  These are filled in automatically by
 # `tripe-keys upload'.  Leave them as they are.
 master-sequence = @MASTER-SEQUENCE@
 hk-master = @HK-MASTER@
index 6c223df7e3bac8b9c59927f491ac79f5870d4a39..28aa143986ce31d2e10b7d15923366a04e6a35de 100644 (file)
 ## it under the terms of the GNU General Public License as published by
 ## the Free Software Foundation; either version 2 of the License, or
 ## (at your option) any later version.
-## 
+##
 ## TrIPE is distributed in the hope that it will be useful,
 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 ## GNU General Public License for more details.
-## 
+##
 ## You should have received a copy of the GNU General Public License
 ## along with TrIPE; if not, write to the Free Software Foundation,
 ## Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index c7764108f88045fb2db6e5c2d348bf00717fe697..4d0472a6a7c56e82c93d341fea011309683da8d4 100644 (file)
@@ -1242,7 +1242,7 @@ class MonitorWindow (MyWindow):
     me.unping()
   def destroy(me):
     if me.pinger is not None:
-      GO.source_remove(me.pinger)    
+      GO.source_remove(me.pinger)
   def report(me, msg):
     moanbox(msg)
     return True
@@ -1282,12 +1282,12 @@ Graphical monitor for TrIPE VPN.
 
 Options supported:
 
--h, --help             Show this help message.
--v, --version          Show the version number.
--u, --usage            Show pointlessly short usage string.
+-h, --help              Show this help message.
+-v, --version           Show the version number.
+-u, --usage             Show pointlessly short usage string.
 
--d, --directory=DIR    Use TrIPE directory DIR.
--a, --admin-socket=FILE        Select socket to connect to."""
+-d, --directory=DIR     Use TrIPE directory DIR.
+-a, --admin-socket=FILE Select socket to connect to."""
       exit(0)
     elif o in ('-v', '--version'):
       version(stdout)
index ca364c01e71d7c642dd1191bef2377c60c467aff..a46bb8e51f8ae72a6c5c82429c1becccbe598b50 100644 (file)
 ## it under the terms of the GNU General Public License as published by
 ## the Free Software Foundation; either version 2 of the License, or
 ## (at your option) any later version.
-## 
+##
 ## TrIPE is distributed in the hope that it will be useful,
 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 ## GNU General Public License for more details.
-## 
+##
 ## You should have received a copy of the GNU General Public License
 ## along with TrIPE; if not, write to the Free Software Foundation,
 ## Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index 6e36adc2a945f883b9348e4296cde8231771e02f..df8399930c697f7915908b3f5dc875ff6d65f037 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2003 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -411,7 +411,7 @@ int main(int argc, char *argv[])
 
   udp_me.sin_family = udp_peer.sin_family = AF_INET;
   parseaddr(argv[optind], &udp_me.sin_addr, &pt);
-  udp_me.sin_port = pt; 
+  udp_me.sin_port = pt;
   parseaddr(argv[optind + 1], &udp_peer.sin_addr, &pt);
   udp_peer.sin_port = pt;
 
index 041b76f35968753514ec798021d3ae321ecbd97e..ad9c70c27dac5d6c9793ed9889db5dbf607ea26e 100644 (file)
 ## it under the terms of the GNU General Public License as published by
 ## the Free Software Foundation; either version 2 of the License, or
 ## (at your option) any later version.
-## 
+##
 ## TrIPE is distributed in the hope that it will be useful,
 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 ## GNU General Public License for more details.
-## 
+##
 ## You should have received a copy of the GNU General Public License
 ## along with TrIPE; if not, write to the Free Software Foundation,
 ## Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index 107362eed6bfb1ca1488cd03e6ddd088316f903f..97bba83be3a4535d4bf7c05a1024252d506b0c86 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2001 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -483,7 +483,7 @@ static void floodtimer(struct timeval *tv, void *vv)
   PASS(f->p->f, buf, sz);
   setflood(f);
 }
-  
+
 static void setflood(flood *f)
 {
   struct timeval tv;
index 01438ea8498fdbd41fc5cb4aa79a6325cdb99234..e1748e2efc7e97b46d213667e4ea109a3759f1f3 100644 (file)
 ## it under the terms of the GNU General Public License as published by
 ## the Free Software Foundation; either version 2 of the License, or
 ## (at your option) any later version.
-## 
+##
 ## TrIPE is distributed in the hope that it will be useful,
 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 ## GNU General Public License for more details.
-## 
+##
 ## You should have received a copy of the GNU General Public License
 ## along with TrIPE; if not, write to the Free Software Foundation,
 ## Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index d98283bcd3fcb0eb8ded9890c9b62d4e1892b795..ecf222fd8d11cf53c3b33e981b66d9fa6bdb81f5 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2001 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -385,7 +385,7 @@ static void a_rawalert(unsigned f_and, unsigned f_eq, const char *status,
 {
   admin *a, *aa;
   dstr d = DSTR_INIT;
-  
+
   if (!(flags & F_INIT))
     return;
   dstr_puts(&d, status);
@@ -567,10 +567,10 @@ static long a_parsetime(const char *p)
     case 'h': t *= 60;
     case 'm': t *= 60;
     case 's': if (q[1] != 0)
-    default:    t = -1;
+    default:   t = -1;
     case 0:   break;
   }
-  return (t);    
+  return (t);
 }
 
 /* --- @a_findpeer@ --- *
@@ -986,7 +986,7 @@ static void a_resolved(struct hostent *h, void *v)
   sel_rmtimer(&r->t);
   xfree(r->addr);
   a_bgrelease(&r->bg);
-} 
+}
 
 /* --- @a_restimer@ --- *
  *
@@ -1093,7 +1093,7 @@ static void a_resolve(admin *a, admin_resop *r, const char *tag,
           a->seq, BGTAG(r), r->addr); )
 
   /* --- If the name is numeric, do it the easy way --- */
-  
+
   if (inet_aton(av[i], &r->sa.sin.sin_addr)) {
     T( trace(T_ADMIN, "admin: resop %s done the easy way", BGTAG(r)); )
     func(r, ARES_OK);
@@ -1349,7 +1349,7 @@ static void a_ping(admin *a, unsigned ac, char *av[],
     a_bgrelease(&pg->bg);
   }
   return;
-    
+
 bad_syntax:
   a_fail(a, "bad-syntax", "%s", cmd, "[OPTIONS] PEER", cmd, A_END);
 fail:
@@ -1565,7 +1565,7 @@ static int traceish(admin *a, unsigned ac, char *av[],
          }
          a_fail(a, "bad-%s-option", what, "%c", *p, A_END);
          return (0);
-        tropt_ok:;
+       tropt_ok:;
          break;
       }
       p++;
@@ -1669,7 +1669,7 @@ static void acmd_setifname(admin *a, unsigned ac, char *av[])
     a_notify("NEWIFNAME", "?PEER", p, "%s", p_ifname(p), "%s", av[1], A_END);
     p_setifname(p, av[1]);
     a_ok(a);
-  }  
+  }
 }
 
 static void acmd_getchal(admin *a, unsigned ac, char *av[])
@@ -1779,7 +1779,7 @@ static void acmd_stats(admin *a, unsigned ac, char *av[])
         "ip-bytes-in=%lu", st->sz_ipin,
         A_END);
   a_info(a,
-        "ip-packets-out=%lu", st->n_ipout, 
+        "ip-packets-out=%lu", st->n_ipout,
         "ip-bytes-out=%lu", st->sz_ipout,
         A_END);
   a_info(a, "rejected-packets=%lu", st->n_reject, A_END);
@@ -1882,7 +1882,7 @@ static const acmd acmdtab[] = {
   { "tunnels", 0,                      0,      0,      acmd_tunnels },
   { "version", 0,                      0,      0,      acmd_version },
   { "warn",    "MESSAGE ...",          1,      0xffff, acmd_warn },
-  { "watch",   "[OPTIONS]",            0,      1,      acmd_watch },
+  { "watch",   "[OPTIONS]",            0,      1,      acmd_watch },
   { 0,         0,                      0,      0,      0 }
 };
 
@@ -1893,7 +1893,7 @@ static void acmd_help(admin *a, unsigned ac, char *av[])
   for (c = acmdtab; c->name; c++) {
     if (c->help)
       a_info(a, "%s", c->name, "*%s", c->help, A_END);
-    else 
+    else
       a_info(a, "%s", c->name, A_END);
   }
   a_ok(a);
@@ -2040,7 +2040,7 @@ static void a_line(char *p, size_t len, void *vp)
       if (c->argmin > ac || ac > c->argmax) {
        if (!c->help)
          a_fail(a, "bad-syntax", "%s", c->name, "", A_END);
-       else 
+       else
          a_fail(a, "bad-syntax", "%s", c->name, "%s", c->help, A_END);
       } else
        c->func(a, ac, av + 1);
index 5258cf9c66c1ef24e573ea3998a08af071e85c41..8eef16a257fa4f562d33ba8b38f4fa597128ec83 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2005 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index 8577d91e3f9dd3e93f69f43d3bf66243f0810153..396ecaede13b83c5f430014637c7e2f01b700764 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2001 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
  * %$r_A = g^{\rho_A}$%                        Alice's challenge
  * %$c_A = H(\cookie{cookie}, r_A)$%   Alice's cookie
  * %$v_A = \rho_A \xor H(\cookie{expected-reply}, a, r_A, r_B, b^{\rho_A})$%
- *                                     Alice's challenge check value
+ *                                     Alice's challenge check value
  * %$r_B^\alpha = a^{\rho_B}$%         Alice's reply
  * %$K = r_B^{\rho_A} = r_B^{\rho_A} = g^{\rho_A\rho_B}$%
- *                                     Alice and Bob's shared secret key
+ *                                     Alice and Bob's shared secret key
  * %$w_A = H(\cookie{switch-request}, c_A, c_B)$%
- *                                     Alice's switch request value
+ *                                     Alice's switch request value
  * %$u_A = H(\cookie{switch-confirm}, c_A, c_B)$%
- *                                     Alice's switch confirm value
+ *                                     Alice's switch confirm value
  *
  * The messages are then:
  *
@@ -75,7 +75,7 @@
  *
  * %$\cookie{kx-switch-ok}, E_K(u_A))$%
  *     Switch received.  Committed; send data; move to @KXS_SWITCH@.
- */ 
+ */
 
 /*----- Tunable parameters ------------------------------------------------*/
 
@@ -598,7 +598,7 @@ static kxchal *respond(keyexch *kx, unsigned msg, buf *b)
       goto badcheck;
 
     /* --- Fill in a new challenge block --- */
-    
+
     kxc = kxc_new(kx);
     G_COPY(gg, kxc->c, c);
     G_COPY(gg, kxc->r, r);
@@ -678,7 +678,7 @@ bad:
   G_DESTROY(gg, cc);
   G_DESTROY(gg, r);
   mp_drop(cv);
-  return (0);  
+  return (0);
 }
 
 /* --- @dochallenge@ --- *
@@ -857,7 +857,7 @@ static void commit(keyexch *kx, kxchal *kxc)
   kx->r[0] = kxc;
   kx->nr = 1;
   kxc_stoptimer(kxc);
-  ksl_link(kx->ks, kxc->ks);  
+  ksl_link(kx->ks, kxc->ks);
 }
 
 /* --- @doreply@ --- *
@@ -886,7 +886,7 @@ static int doreply(keyexch *kx, buf *b)
   if (BLEFT(b)) {
     a_warn("KX", "?PEER", kx->p, "invalid", "reply", A_END);
     goto bad;
-  }    
+  }
   if (kx->s == KXS_CHAL) {
     commit(kx, kxc);
     kx->s = KXS_COMMIT;
@@ -1012,7 +1012,7 @@ static int doswitchok(keyexch *kx, buf *b)
   return (0);
 
 bad:
-  return (-1);  
+  return (-1);
 }
 
 /*----- Main code ---------------------------------------------------------*/
index edd31b2a443b7bc52e59637190390550e479a2de..422b01fee80a0fb1cb2168a847941ed34f6e1fb8 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2001 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -293,13 +293,13 @@ static int algs_samep(const algswitch *a, const algswitch *aa)
 /* --- @keymoan@ --- *
  *
  * Arguments:  @const char *file@ = name of the file
- *              @int line@ = line number in file
- *              @const char *msg@ = error message
- *              @void *p@ = argument pointer
+ *             @int line@ = line number in file
+ *             @const char *msg@ = error message
+ *             @void *p@ = argument pointer
  *
- * Returns:     ---
+ * Returns:    ---
  *
- * Use:         Reports an error message about loading a key file.
+ * Use:                Reports an error message about loading a key file.
  */
 
 static void keymoan(const char *file, int line, const char *msg, void *p)
@@ -384,7 +384,7 @@ tymatch:;
 
   /* --- Good, we're happy --- *
    *
-   * Dodginess!  We change the group over here, but don't free any old group
+   * Dodginess!         We change the group over here, but don't free any old group
    * elements.  This assumes that the new group is basically the same as the
    * old one, and will happily adopt the existing elements.  If it isn't,
    * then we lose badly.  Check this, then.
@@ -598,7 +598,7 @@ tymatch:;
 
   /* --- Ensure that the group is correct --- *
    *
-   * Dodginess!  We assume that if this works, our global group is willing to
+   * Dodginess!         We assume that if this works, our global group is willing to
    * adopt this public element.  Probably reasonable.
    */
 
index bb2397fc72a79d701cb6664ceb6dba66266851f6..0a4952a8b96498d33bf23bdb6dece605ff61d4e4 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2001 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -56,7 +56,7 @@
 /* --- Encrypted data format --- *
  *
  * Let %$p_i$% be the %$i$%-th plaintext message, with type %$t$%.  We first
- * compute 
+ * compute
  *
  *   %$c_i = \mathcal{E}\textrm{-CBC}_{K_{\text{E}}}(p_i)$%
  *
@@ -159,7 +159,7 @@ static int doencrypt(keyset *ks, unsigned ty, buf *b, buf *bb)
     rc = -1;
   }
   ks->sz_exp = nsz;
-  return (rc);  
+  return (rc);
 }
 
 /* --- @dodecrypt@ --- *
@@ -277,7 +277,7 @@ void ks_drop(keyset *ks)
  *
  * Arguments:  @const void *k@ = pointer to key material
  *             @size_t x, y, z@ = offsets into key material (see below)
- *             @peer *p@ = pointer to peer information 
+ *             @peer *p@ = pointer to peer information
  *
  * Returns:    A pointer to the new keyset.
  *
index 1e5d0766af274f023053ceae1084861f8520ddee..25354f1a57c99fd988b6778a21dace9dd47ba76d 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2001 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -90,7 +90,7 @@ static void p_ponged(peer *p, unsigned msg, buf *b)
   uint32 id;
   const octet *magic;
   ping *pg;
-  
+
   IF_TRACING(T_PEER, {
     trace(T_PEER, "peer: received %s reply from %s",
          p_pingtype(msg), p->spec.name);
@@ -239,7 +239,7 @@ found:
        case MISC_PING:
          buf_put(p_txstart(p, MSG_MISC | MISC_PONG), BCUR(&b), BLEFT(&b));
          p_txend(p);
-         break;        
+         break;
        case MISC_PONG:
          p_ponged(p, MISC_PONG, &b);
          break;
@@ -768,7 +768,7 @@ peer *p_find(const char *name)
     if (strcmp(name, p->spec.name) == 0)
       return (p);
   }
-  return (0);  
+  return (0);
 }
 
 /* --- @p_destroy@ --- *
index 92a5f775f03b456a0068317508db70294bedcb77..06b409ec534cde5fb5eac29b20cc8dd61f9bbb88 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2001 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index f9cf0e86ecca9956ec6d8ea8644cd15055f99efb..670e14101924339888de1eb5066afff0b26a3dba 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2001 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index 5f00718db5ecdd40b7bb195893e8d06b4fb37477..3db1cb965faf8a15aa824c0f9210644c62b0bc27 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2001 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -194,9 +194,9 @@ typedef struct keyset {
   unsigned long sz_exp;                        /* Data limit for the keyset */
   T( unsigned seq; )                   /* Sequence number for tracing */
   unsigned f;                          /* Various useful flags */
-  gcipher *cin, *cout;                         /* Keyset ciphers for encryption */
+  gcipher *cin, *cout;                 /* Keyset ciphers for encryption */
   size_t tagsz;                                /* Length to truncate MAC tags */
-  gmac *min, *mout;                    /* Keyset MACs for integrity */
+  gmac *min, *mout;                    /* Keyset MACs for integrity */
   uint32 oseq;                         /* Outbound sequence number */
   seqwin iseq;                         /* Inbound sequence number */
 } keyset;
index cf6c6d02518a84a2b2985ba5101005c5df93fcd5..3a45b1e9c459c1d13b6e47264e8031dba95eb54c 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2001 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -41,7 +41,7 @@ struct tunnel {
   sel_file f;                          /* Selector for tunnel device */
   struct peer *p;                      /* Pointer to my peer */
   unsigned n;                          /* Number of my tunnel device */
-};  
+};
 
 /* --- @t_read@ --- *
  *
index 42503548b94ee2bfdf7085fbb3de9769effd1ff1..53f1978b3793e579f5cfcffaf73fe014f028c9c6 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2003 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -46,7 +46,7 @@ struct tunnel {
   const tunnel_ops *ops;               /* Pointer to operations */
   sel_file f;                          /* Selector for TUN/TAP device */
   struct peer *p;                      /* Pointer to my peer */
-};  
+};
 
 /* --- @t_read@ --- *
  *
index 0df028e49365710c7053db8f9800f00b482f3d69..785d008f6c31ef15e2a8727ed8af1d3e88f9c590 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2005 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -55,7 +55,7 @@ struct tunnel {
 #   define ST_EOF 4u                   /*   File descriptor reported EOF */
   size_t n;                            /* Number of bytes used in buffer */
   octet buf[PKBUFSZ];                  /* Buffer for incoming data */
-};  
+};
 
 /*----- Static variables --------------------------------------------------*/
 
index bdf23fe4454066dc0e08e96c41016f881521018f..3274db1c3d07cdd3c03814568541b57008d4cc38 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2001 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index be9dd915d995070556af50ef28d941b9c2a9c47c..67a0be7cdf0c392d6b8bc47c8c8ff4a69c21ff88 100644 (file)
 ## it under the terms of the GNU General Public License as published by
 ## the Free Software Foundation; either version 2 of the License, or
 ## (at your option) any later version.
-## 
+##
 ## TrIPE is distributed in the hope that it will be useful,
 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 ## GNU General Public License for more details.
-## 
+##
 ## You should have received a copy of the GNU General Public License
 ## along with TrIPE; if not, write to the Free Software Foundation,
 ## Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
index 04dec611dd65edb5612d828c1e5e38daffe6af5a..1bd4c454b606bc13f57b07daff600cf7e979bb95 100644 (file)
Binary files a/wireshark/cap and b/wireshark/cap differ
index 5ea7b9788f7fef579c5a840a334ed34c4e7bef01..798ccd9e820d415e9442862913fb357436f669db 100644 (file)
@@ -7,7 +7,7 @@
  * (c) 2003 Straylight/Edgeware
  */
 
-/*----- Licensing notice --------------------------------------------------* 
+/*----- Licensing notice --------------------------------------------------*
  *
  * This file is part of Trivial IP Encryption (TrIPE).
  *
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * TrIPE is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU General Public License
  * along with TrIPE; if not, write to the Free Software Foundation,
  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -85,7 +85,7 @@ static void prefcb(void) { }
 static gint gethash(proto_tree *tt, int hf, tvbuff_t *b, gint off)
 {
   proto_tree_add_item(tt, hf, b, off, hashsz, FALSE);
-  return (off + hashsz); 
+  return (off + hashsz);
 }
 
 static gint getmp(proto_tree *tt, const hfmp *hf, tvbuff_t *b, gint off)
@@ -119,7 +119,7 @@ static gint getge(proto_tree *tt, const hfge *hf, tvbuff_t *b, gint off)
     proto_tree_add_item(tt, hf->hfy_len, b, off + 2 + len, 2, FALSE);
     proto_tree_add_item(tt, hf->hfy_val, b, off + 4 + len, len2, FALSE);
     r = off + len + len2 + 4;
-  }    
+  }
   return (r);
 }
 
@@ -306,7 +306,7 @@ static void dissect_tripe(tvbuff_t *b, packet_info *p, proto_tree *t)
     proto_tree_add_item(ti, hf_tripe_ct_ct, b, off, -1, FALSE);
     goto done;
   done:;
-  }  
+  }
 }
 
 void proto_register_tripe(void)