Skip to contentSkip to conversation

Log the negotiated (NCP) cipher

PATCH In review Steffan Karger 3 participants 3 messages May 15, 2017 – May 17, 2017

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Log the negotiated (NCP) cipher

To make it clear that NCP is in effect, print a log message (at --verb 2) to show that we selected a cipher using NCP.

---
 src/openvpn/ssl.c | 6 ++++++
 1 file changed, 6 insertions(+)
src/openvpn/ssl.c +6 -0
index 21c9d6f..3d5e824 100644
@@ -1959,6 +1959,12 @@ tls_session_update_crypto_params(struct tls_session *session,
         return false;
     }
 
+    if (strcmp(options->ciphername, session->opt->config_ciphername))
+    {
+        msg(D_HANDSHAKE, "Data Channel: using negotiated cipher '%s'",
+            options->ciphername);
+    }
+
     init_key_type(&session->opt->key_type, options->ciphername,
                   options->authname, options->keysize, true, true);
 
Signature · 1 line
2.7.4
#1 lore raw

Am 15.05.17 um 16:43 schrieb Steffan Karger:

Quoted 2 lines

To make it clear that NCP is in effect, print a log message (at --verb 2) to show that we selected a cipher using NCP.

ACK, also works as advertised:

May 17 18:23:09 hermes ovpn-aead-v6[15271]:

keto.blinkt.de/188.109.222.115 Data Channel: using negotiated cipher 'AES-256-GCM'

#2 lore raw
In reply to Steffan Karger

Your patch has been applied to the master and release/2.4 branch.

commit d4071dd1553ea5a70ab03659c623ff2ceeefaf9e (master) commit 4ae06ef696638efcf4cd045e4541877ef5a92e68 (release/2.4)

Author: Steffan Karger
Date:   Mon May 15 16:43:55 2017 +0200
     Log the negotiated (NCP) cipher

     Signed-off-by: Steffan Karger <[email protected]...>
     Acked-by: Arne Schwabe <[email protected]...>
     Message-Id: <[email protected]...>
     URL: https://www.mail-archive.com/[email protected]/msg14656.html
     Signed-off-by: Gert Doering <[email protected]...>

--
kind regards,

Gert Doering