]> git.ipfire.org Git - thirdparty/openvpn.git/commitdiff
auth-token with auth-nocache fix broke --disable-crypto builds
authorDavid Sommerseth <davids@openvpn.net>
Mon, 19 Jun 2017 13:05:07 +0000 (15:05 +0200)
committerDavid Sommerseth <davids@openvpn.net>
Mon, 19 Jun 2017 13:25:42 +0000 (15:25 +0200)
After adding commit 571165360db0392fa83e, it broke builds where
the --disable-crypto was used with ./configure.  This was due to
the delayed_auth_pass_purge() which requires the crypto code paths
being called from init.c without the proper #ifdef encapsulation.

Signed-off-by: David Sommerseth <davids@openvpn.net>
Acked-by: Gert Doering <gert@greenie.muc.de>
Message-Id: <20170619130507.13892-1-davids@openvpn.net>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg14883.html
Signed-off-by: David Sommerseth <davids@openvpn.net>
(cherry picked from commit 5bde5b6d1875fd87b116c943084df0d2f6aee6d0)

src/openvpn/init.c

index ae1f65da2044450a19a38dbc24022631d3b5476e..c6546e6999a1177e909bdb822bb7fef880004c2d 100644 (file)
@@ -1253,6 +1253,8 @@ initialization_sequence_completed (struct context *c, const unsigned int flags)
   /* If we delayed UID/GID downgrade or chroot, do it now */
   do_uid_gid_chroot (c, true);
 
+
+#ifdef ENABLE_CRYPTO
   /*
    * In some cases (i.e. when receiving auth-token via
    * push-reply) the auth-nocache option configured on the
@@ -1264,6 +1266,7 @@ initialization_sequence_completed (struct context *c, const unsigned int flags)
      {
        delayed_auth_pass_purge();
      }
+#endif /* ENABLE_CRYPTO */
 
   /* Test if errors */
   if (flags & ISC_ERRORS)