Skip to contentSkip to conversation

2.3.12 vs git-master with cipher negotiation

Openvpn-devel debbie10t 4 participants 4 messages Aug 25, 2016 – Aug 26, 2016

lore
Share & tools
lore

debbie10t

author
#0 lore raw

Hi,

this is an odd one that i am only reporting as it feels like something may have been over looked.

1.
Start off running win10 server openvpn git-master 20160818 with --cipher AES-256-CBC defined

Linux client running git:master/d1bd37fd508ee046
with --cipher AES-256-CBC defined

Client connects ok --cipher is negotiated up to AES-256-*GCM*
ie: Data Channel Encrypt: Cipher 'AES-256-GCM' initialized with 256 bit key

No problem.
===

2.a
Now leave the client running and stop the server Uninstall openvpn on the server and then install 2.3.12-i601_x86-64 Restart the server.

Now server cannot negotiate --cipher and is set at AES-256-CBC Connecting linux client cannot renegotiate --cipher and is set at AES-256-GCM On --ping-restart --cipher is not reset and so the client can no longer connect.

Problem.
===

2.b
At the same time a winXP client is running openvpn 2.3.12-i001_i686 with --cipher AES-256-CBC defined

When this connects to the git:master server AES-256-CBC is honoured as the client cannot negotiate

When the server is changed to 2.3.12 the winXP client *can* reconnect

No problem
===

I hazard a guess that --client --ping-restart does not reset --cipher. but I do not know if that is intended ..

Regards

#1 lore raw

Hi,

Quoted 5 lines · On Thu, Aug 25, 2016 at 04:17:25PM +0100, debbie10t wrote:

Now server cannot negotiate --cipher and is set at AES-256-CBC Connecting linux client cannot renegotiate --cipher and is set at AES-256-GCM
On --ping-restart --cipher is not reset and so the client can no longer connect.

This is a problem indeed, thanks for noticing and clearly describing it.

(In other words: upon reconnection, the --cipher setting should be "what is in the config", not "what was negotiated in a previous connect", so it needs to be stored in a session-dependent variable internally, and not override the config variable - which makes the code less nice...)

Steffan, are you listening? ;-)

gert

Signature · 4 lines
USENET is *not* the non-clickable part of WWW!
                                                           //www.muc.de/~gert/
Gert Doering - Munich, Germany                             [email protected]...
fax: +49-89-35655025                        [email protected]...
#2 lore raw

Hi,

Quoted 8 lines · Gert Doering

Hi,

Quoted 5 lines · On Thu, Aug 25, 2016 at 04:17:25PM +0100, debbie10t wrote:

Now server cannot negotiate --cipher and is set at AES-256-CBC Connecting linux client cannot renegotiate --cipher and is set at AES-256-GCM
On --ping-restart --cipher is not reset and so the client can no longer connect.

Quoted 9 lines

This is a problem indeed, thanks for noticing and clearly describing it.

(In other words: upon reconnection, the --cipher setting should be "what is in the config", not "what was negotiated in a previous connect", so it needs to be stored in a session-dependent variable internally, and not override the config variable - which makes the code less nice...)

Steffan, are you listening? ;-)

FWIW: this is not a new problem, it just happens to show up now; if you do a
push "cipher aes-128-cbc"
on a v2.3 server it will happily push it (even a v2.1 server would). The connection would not be established (unless the client happened to use "cipher aes-128-cbc" already) but after a reconnect the connection *would* work. I'm not saying it shouldn't be fixed, I'm just saying that this is not "new" behaviour.

HTH,

JJK

#3 lore raw
In reply to Gert Doering
Quoted 7 lines · Gert Doering
Quoted 5 lines · On Thu, Aug 25, 2016 at 04:17:25PM +0100, debbie10t wrote:

Now server cannot negotiate --cipher and is set at AES-256-CBC Connecting linux client cannot renegotiate --cipher and is set at AES-256-GCM
On --ping-restart --cipher is not reset and so the client can no longer connect.

Quoted 8 lines

This is a problem indeed, thanks for noticing and clearly describing it.

(In other words: upon reconnection, the --cipher setting should be "what is in the config", not "what was negotiated in a previous connect", so it needs to be stored in a session-dependent variable internally, and not override the config variable - which makes the code less nice...)

Steffan, are you listening? ;-)

Yes, I am, and I agree that this needs to be fixed. This could also cause problems when roaming from one server to the next. Just didn't find time to respond yet. It's on my list.

-Steffan