Skip to contentSkip to conversation

Avoid repetition of "this config may cache passwords in memory" (v2)

PATCH Applied David Sommerseth 1 participant 2 messages Apr 26, 2010 – Apr 30, 2010

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Avoid repetition of "this config may cache passwords in memory" (v2)

From: David Sommerseth <[email protected]...>

For OpenVPN clients with long living connections, this message is repeated everytime the connection is renegotiated. This patch removes this behaviour and will only show this warning once.

---
 misc.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
misc.c +3 -1
index 643ffad..47f1b95 100644
@@ -1588,14 +1588,16 @@ void
 purge_user_pass (struct user_pass *up, const bool force)
 {
   const bool nocache = up->nocache;
+  static bool warn_shown = false;
   if (nocache || force)
     {
       CLEAR (*up);
       up->nocache = nocache;
     }
-  else
+  else if (!warn_shown)
     {
       msg (M_WARN, "WARNING: this configuration may cache passwords in memory -- use the auth-nocache option to prevent this");
+      warn_shown = true;
     }
 }
 
Signature · 1 line
1.6.6.1
author Applied
#1 lore raw

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 11 lines · David Sommerseth

From: David Sommerseth <[email protected]...>

For OpenVPN clients with long living connections, this message is repeated everytime the connection is renegotiated. This patch removes this behaviour and will only show this warning once.

---
 misc.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

This patch received an ACK on the developers meeting 2010-04-29
<http://thread.gmane.org/gmane.network.openvpn.devel/3673>

Applied to feat_misc and merged into allmerged.
Commit 793e2baffbe8b6cc34570046d9329f8abfd68c77

kind regards,

David Sommerseth
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/

iEYEARECAAYFAkvbTaAACgkQDC186MBRfrrkZACgi44P4rcPYDGibCfN/8oR8JlF CD0AoJ8atZqXJRXcaCyee0CdWZqShH5H
=OWHH
-----END PGP SIGNATURE-----