1 diff -uNr openswan-2.3.0.orig/programs/loggerfix openswan-2.3.0/programs/loggerfix
2 --- openswan-2.3.0.orig/programs/loggerfix 1970-01-01 00:00:00.000000000 +0000
3 +++ openswan-2.3.0/programs/loggerfix 2005-02-02 20:34:54.000000000 +0000
6 +# use filename instead of /dev/null to log, but dont log to flash or ram
7 +# pref. log to nfs mount
8 +echo "$*" >> /dev/null
10 diff -uNr openswan-2.3.0.orig/programs/look/look.in openswan-2.3.0/programs/look/look.in
11 --- openswan-2.3.0.orig/programs/look/look.in 2003-10-31 02:32:42.000000000 +0000
12 +++ openswan-2.3.0/programs/look/look.in 2005-02-02 20:34:54.000000000 +0000
15 pat="$pat|$defaultroutephys\$|$defaultroutevirt\$"
17 - for i in `echo "$IPSECinterfaces" | tr '=' ' '`
18 + for i in `echo "$IPSECinterfaces" | sed 's/=/ /'`
22 diff -uNr openswan-2.3.0.orig/programs/manual/manual.in openswan-2.3.0/programs/manual/manual.in
23 --- openswan-2.3.0.orig/programs/manual/manual.in 2004-11-01 22:49:01.000000000 +0000
24 +++ openswan-2.3.0/programs/manual/manual.in 2005-02-02 20:34:54.000000000 +0000
30 + }' | sed ':a;N;$!ba;s/\n/ /g'`"
33 diff -uNr openswan-2.3.0.orig/programs/_startklips/_startklips.in openswan-2.3.0/programs/_startklips/_startklips.in
34 --- openswan-2.3.0.orig/programs/_startklips/_startklips.in 2004-12-10 12:38:28.000000000 +0000
35 +++ openswan-2.3.0/programs/_startklips/_startklips.in 2005-02-02 20:34:54.000000000 +0000
38 unset MODPATH MODULECONF # no user overrides!
39 depmod -a >/dev/null 2>&1
42 + then modprobe -v ipsec
48 if test ! -f $ipsecversion
50 diff -uNr openswan-2.3.0.orig/programs/setup/setup.in openswan-2.3.0/programs/setup/setup.in
51 --- openswan-2.3.0.orig/programs/setup/setup.in 2004-03-22 00:24:06.000000000 +0000
52 +++ openswan-2.3.0/programs/setup/setup.in 2005-02-02 20:34:54.000000000 +0000
56 start|--start|stop|--stop|_autostop|_autostart)
57 - if test " `id -u`" != " 0"
58 + if [ "x${USER}" != "xroot" ]
60 echo "permission denied (must be superuser)" |
61 logger -s -p $IPSECsyslog -t ipsec_setup 2>&1
65 + # make sure all required directories exist
66 + if [ ! -d /var/run/pluto ]
68 + mkdir -p /var/run/pluto
70 + if [ ! -d /var/lock/subsys ]
72 + mkdir -p /var/lock/subsys
74 tmp=/var/run/pluto/ipsec_setup.st
75 outtmp=/var/run/pluto/ipsec_setup.out
77 diff -uNr openswan-2.3.0.orig/programs/showhostkey/showhostkey.in openswan-2.3.0/programs/showhostkey/showhostkey.in
78 --- openswan-2.3.0.orig/programs/showhostkey/showhostkey.in 2004-11-14 13:40:41.000000000 +0000
79 +++ openswan-2.3.0/programs/showhostkey/showhostkey.in 2005-02-02 20:34:54.000000000 +0000
84 -host="`hostname --fqdn`"
85 +host="`cat /proc/sys/kernel/hostname`"
89 diff -uNr openswan-2.3.0.orig/programs/send-pr/send-pr.in openswan-2.3.0/programs/send-pr/send-pr.in
90 --- openswan-2.3.0.orig/programs/send-pr/send-pr.in 2003-07-14 12:26:17.000000000 +0000
91 +++ openswan-2.3.0/programs/send-pr/send-pr.in 2005-02-02 20:34:54.000000000 +0000
94 if [ "$fieldname" != "Category" ]
96 - values=`${BINDIR}/query-pr --valid-values $fieldname | tr '\n' ' ' | sed 's/ *$//g;s/ / | /g;s/^/[ /;s/$/ ]/;'`
97 + values=`${BINDIR}/query-pr --valid-values $fieldname | sed ':a;N;$!ba;s/\n/ /g' | sed 's/ *$//g;s/ / | /g;s/^/[ /;s/$/ ]/;'`
98 valslen=`echo "$values" | wc -c`
100 values="choose from a category listed above"
103 desc="<${values} (one line)>";
105 - dpat=`echo "$desc" | tr '\]\[*+^$|\()&/' '............'`
106 + dpat=`echo "$desc" | sed 's/[][*+^$|\()&/]/./g'`
107 echo "/^>${fieldname}:/ s/${dpat}//" >> $FIXFIL
109 echo "${fmtname}${desc}" >> $file
111 desc=" $default_val";
113 desc=" <`${BINDIR}/query-pr --field-description $fieldname` (multiple lines)>";
114 - dpat=`echo "$desc" | tr '\]\[*+^$|\()&/' '............'`
115 + dpat=`echo "$desc" | sed 's/[][*+^$|\()&/]/./g'`
116 echo "s/^${dpat}//" >> $FIXFIL
118 echo "${fmtname}" >> $file;
120 desc="${default_val}"
122 desc="<`${BINDIR}/query-pr --field-description $fieldname` (one line)>"
123 - dpat=`echo "$desc" | tr '\]\[*+^$|\()&/' '............'`
124 + dpat=`echo "$desc" | sed 's/[][*+^$|\()&/]/./g'`
125 echo "/^>${fieldname}:/ s/${dpat}//" >> $FIXFIL
127 echo "${fmtname}${desc}" >> $file
128 diff -uNr openswan-2.3.0.orig/programs/_realsetup/_realsetup.in openswan-2.3.0/programs/_realsetup/_realsetup.in
129 --- openswan-2.3.0.orig/programs/_realsetup/_realsetup.in 2004-12-10 13:10:04.000000000 +0000
130 +++ openswan-2.3.0/programs/_realsetup/_realsetup.in 2005-02-02 20:34:54.000000000 +0000
133 # misc pre-Pluto setup
135 - perform test -d `dirname $subsyslock` "&&" touch $subsyslock
136 + perform test -d `echo $subsyslock | sed -r 's/(^.*\/)(.*$)/\1/'` "&&" touch $subsyslock
138 if test " $IPSECforwardcontrol" = " yes"
141 lsmod 2>&1 | grep "^xfrm_user" > /dev/null && rmmod -s xfrm_user
144 - perform test -d `dirname $subsyslock` "&&" rm -f $subsyslock
145 + perform test -d `echo $subsyslock | sed -r 's/(^.*\/)(.*$)/\1/'` "&&" touch $subsyslock "&&" rm -f $subsyslock
147 perform rm -f $info $lock $plutopid
148 perform echo "...Openswan IPsec stopped" "|" $LOGONLY
149 --- openswan-2.3.0.orig/programs/_plutorun/_plutorun.in 2004-11-03 20:21:08.000000000 +0000
150 +++ openswan-2.3.0/programs/_plutorun/_plutorun.in 2005-02-02 20:34:54.000000000 +0000
155 - if test ! -w "`dirname $stderrlog`"
156 + if test ! -w "`echo $stderrlog | sed -r 's/(^.*\/)(.*$)/\1/'`"
158 echo Cannot write to directory to create \"$stderrlog\".
160 diff -urN openswan-2.3.1.old/programs/_startklips/_startklips.in openswan-2.3.1/programs/_startklips/_startklips.in
161 --- openswan-2.3.1.old/programs/_startklips/_startklips.in 2005-04-10 23:57:51.000000000 +0200
162 +++ openswan-2.3.1/programs/_startklips/_startklips.in 2005-04-11 00:00:36.000000000 +0200
163 @@ -262,15 +262,15 @@
164 echo "FATAL ERROR: Both KLIPS and NETKEY IPsec code is present in kernel"
167 -if test ! -f $ipsecversion && test ! -f $netkey && modprobe -qn ipsec
168 +if test ! -f $ipsecversion && test ! -f $netkey && insmod ipsec
170 # statically compiled KLIPS/NETKEY not found; try to load the module
175 if test ! -f $ipsecversion && test ! -f $netkey
182 @@ -278,18 +278,18 @@
188 - modprobe -qv ipcomp
192 # xfrm4_tunnel is needed by ipip and ipcomp
193 - modprobe -qv xfrm4_tunnel
194 + insmod -qv xfrm4_tunnel
195 # xfrm_user contains netlink support for IPsec
196 - modprobe -qv xfrm_user
197 + insmod -qv xfrm_user
198 # load the most common ciphers/algo's