starter: Properly refer to the ipsec script if it was renamed
authorTobias Brunner <tobias@strongswan.org>
Mon, 22 Jul 2013 15:59:49 +0000 (17:59 +0200)
committerTobias Brunner <tobias@strongswan.org>
Mon, 22 Jul 2013 16:00:19 +0000 (18:00 +0200)
src/starter/Makefile.am
src/starter/confread.c
src/starter/starter.c

index 0c2d250..48110dd 100644 (file)
@@ -15,6 +15,7 @@ AM_CPPFLAGS = \
        -DIPSEC_CONFDIR=\"${sysconfdir}\" \
        -DIPSEC_PIDDIR=\"${piddir}\" \
        -DIPSEC_EAPDIR=\"${eapdir}\" \
+       -DIPSEC_SCRIPT=\"${ipsec_script}\" \
        -DDEV_RANDOM=\"${random_device}\" \
        -DDEV_URANDOM=\"${urandom_device}\" \
        -DPLUGINS=\""${starter_plugins}\"" \
index f0f05b0..2fb0226 100644 (file)
@@ -38,7 +38,7 @@
 static const char ike_defaults[] = "aes128-sha1-modp2048,3des-sha1-modp1536";
 static const char esp_defaults[] = "aes128-sha1,3des-sha1";
 
-static const char firewall_defaults[] = "ipsec _updown iptables";
+static const char firewall_defaults[] = IPSEC_SCRIPT " _updown iptables";
 
 static bool daemon_exists(char *daemon, char *path)
 {
index 9620fb6..06eb142 100644 (file)
@@ -295,7 +295,7 @@ static void generate_selfcert()
 #endif
                ignore_result(setegid(gid));
                ignore_result(seteuid(uid));
-               ignore_result(system("ipsec scepclient --out pkcs1 --out cert-self --quiet"));
+               ignore_result(system(IPSEC_SCRIPT " scepclient --out pkcs1 --out cert-self --quiet"));
                ignore_result(seteuid(0));
                ignore_result(setegid(0));