Package: openswan
Version: 1:2.6.20+dfsg-1
Followup-For: Bug #515098

Patch attached.

Changelog snipset:
  * debian/openswan.config: guess current value of 'openswan/enable-oe', based
    on the existence of the 'include /etc/ipsec.d/examples/no_oe.conf' line in
    /etc/ipsec.conf.

-- System Information:
Debian Release: 5.0
  APT prefers stable
  APT policy: (900, 'stable'), (300, 'unstable')
Architecture: i386 (i686)

Kernel: Linux 2.6.26-1-xen-686 (SMP w/1 CPU core)
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
diff -ur openswan-2.6.20+dfsg-old/debian/openswan.config openswan-2.6.20+dfsg/debian/openswan.config
--- openswan-2.6.20+dfsg-old/debian/openswan.config	2009-03-08 19:11:45.000000000 +0100
+++ openswan-2.6.20+dfsg/debian/openswan.config	2009-03-08 22:28:33.000000000 +0100
@@ -6,6 +6,14 @@
 
 db_input medium openswan/restart || true
 
+#guess current value:
+if [ -e /etc/ipsec.conf ]; then
+    if egrep -q "^include /etc/ipsec.d/examples/no_oe.conf$" /etc/ipsec.conf; then
+        db_set openswan/enable-oe false
+    else
+        db_set openswan/enable-oe true
+    fi
+fi
 db_input high openswan/enable-oe || true
 
 db_input high openswan/create_rsa_key || true

Reply via email to