public inbox for development@lists.ipfire.org
 help / color / mirror / Atom feed
From: Antonio Quartulli <antonio@mandelbit.com>
To: Michael Tremer <michael.tremer@ipfire.org>
Cc: development@lists.ipfire.org
Subject: Re: [PATCH 0/3] OpenVPN: Fix N2N connections shown as DISCONNECTED while up
Date: Wed, 28 Oct 2026 20:20:02 +0100	[thread overview]
Message-ID: <c8b22255-772f-4610-9d15-735b3f8b7705@mandelbit.com> (raw)
In-Reply-To: <8707D8AE-46F3-466E-A604-20C95B64BD88@ipfire.org>

Hi Michael,

On 28/10/2026 18:28, Michael Tremer wrote:
> Hello Antonio,
> 
> Thank you so much for your patch.

Thanks for considering it! :)

> 
> I am happy to merge this and create a separate file with the function so that it can be re-used properly.
> 
>  From which version of OpenVPN will this work?

This code aims at working around the existing OpenVPN (mis)behaviour and 
therefore works for all versions.

When my fix will be merged in upstream OpenVPN (see my comment in bug 
#13897) this code in IPFire will become mostly a no-op, but nothing will 
break.

I hope this helps clarifying the scenario.

Regards,

> 
> All the best,
> -Michael
> 
>> On 27 Oct 2026, at 22:21, Antonio Quartulli <antonio@mandelbit.com> wrote:
>>
>> Hi all!
>>
>> This is my first contribution to IPFire, so bear with me if I am doing
>> things the wrong way :)
>>
>> This is what this small series addresses:
>>
>> In P2P mode OpenVPN leaves its management state at AUTH/WAIT when a new
>> session attempt never completes (e.g. a stray packet from the internet),
>> although the tunnel keeps working. The WUI then shows the N2N connection
>> as DISCONNECTED (bug #13897).
>>
>> A fix for OpenVPN has already been published for review [1], but it is
>> not integrated yet. These patches fix IPFire while OpenVPN still
>> misbehaves.
>>
>> A test harness is included to verify the fix and possibly perform
>> regression testing in the future.
>>
>> Notes:
>> - index.cgi and ovpnmain.cgi now require the new
>>   /var/ipfire/ovpn-functions.pl, so it needs to be shipped with the next
>>   Core Update. I left the filelists to you.
>> - wio.cgi (WIO addon) still uses the old check and has the same problem;
>>   I can send a follow-up if wanted.
>>
>> [1] https://gerrit.openvpn.net/c/openvpn/+/2040
>>
>> Antonio Quartulli (3):
>>   ovpn-functions.pl: Add a helper to get the status of N2N connections
>>   ovpnmain.cgi/index.cgi: Use OpenVPN::n2n_status()
>>   tests: Add tests for OpenVPN::n2n_status()
>>
>> config/cfgroot/ovpn-functions.pl              | 96 +++++++++++++++++++
>> config/rootfiles/common/configroot            |  1 +
>> html/cgi-bin/index.cgi                        | 12 +--
>> html/cgi-bin/ovpnmain.cgi                     | 58 +----------
>> lfs/configroot                                |  1 +
>> .../ovpn-functions.pl/data/auth_pending       |  6 ++
>> .../cfgroot/ovpn-functions.pl/data/connected  |  7 ++
>> .../data/connected_stray_session              |  8 ++
>> .../cfgroot/ovpn-functions.pl/data/empty      |  1 +
>> .../cfgroot/ovpn-functions.pl/data/exiting    |  7 ++
>> .../ovpn-functions.pl/data/never_connected    |  6 ++
>> .../ovpn-functions.pl/data/notifications      | 11 +++
>> .../ovpn-functions.pl/data/reconnected        | 11 +++
>> .../ovpn-functions.pl/data/reconnecting       |  9 ++
>> .../cfgroot/ovpn-functions.pl/data/truncated  |  3 +
>> .../cfgroot/ovpn-functions.pl/n2n_status.pl   | 73 ++++++++++++++
>> .../config/cfgroot/ovpn-functions.pl/test.sh  | 70 ++++++++++++++
>> 17 files changed, 315 insertions(+), 65 deletions(-)
>> create mode 100644 config/cfgroot/ovpn-functions.pl
>> create mode 100644 tests/config/cfgroot/ovpn-functions.pl/data/auth_pending
>> create mode 100644 tests/config/cfgroot/ovpn-functions.pl/data/connected
>> create mode 100644 tests/config/cfgroot/ovpn-functions.pl/data/connected_stray_session
>> create mode 100644 tests/config/cfgroot/ovpn-functions.pl/data/empty
>> create mode 100644 tests/config/cfgroot/ovpn-functions.pl/data/exiting
>> create mode 100644 tests/config/cfgroot/ovpn-functions.pl/data/never_connected
>> create mode 100644 tests/config/cfgroot/ovpn-functions.pl/data/notifications
>> create mode 100644 tests/config/cfgroot/ovpn-functions.pl/data/reconnected
>> create mode 100644 tests/config/cfgroot/ovpn-functions.pl/data/reconnecting
>> create mode 100644 tests/config/cfgroot/ovpn-functions.pl/data/truncated
>> create mode 100644 tests/config/cfgroot/ovpn-functions.pl/n2n_status.pl
>> create mode 100755 tests/config/cfgroot/ovpn-functions.pl/test.sh
>>
>> -- 
>> 2.55.0
>>
>>
> 

-- 
Antonio Quartulli

CEO and Co-Founder
Mandelbit Srl
https://www.mandelbit.com



      reply	other threads:[~2026-10-28 19:20 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-27 22:21 Antonio Quartulli
2026-10-27 22:21 ` [PATCH 1/3] ovpn-functions.pl: Add a helper to get the status of N2N connections Antonio Quartulli
2026-10-27 22:21 ` [PATCH 2/3] ovpnmain.cgi/index.cgi: Use OpenVPN::n2n_status() Antonio Quartulli
2026-10-27 22:21 ` [PATCH 3/3] tests: Add tests for OpenVPN::n2n_status() Antonio Quartulli
2026-10-28 17:28 ` [PATCH 0/3] OpenVPN: Fix N2N connections shown as DISCONNECTED while up Michael Tremer
2026-10-28 19:20   ` Antonio Quartulli [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c8b22255-772f-4610-9d15-735b3f8b7705@mandelbit.com \
    --to=antonio@mandelbit.com \
    --cc=development@lists.ipfire.org \
    --cc=michael.tremer@ipfire.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox