Unable to start openvpn3 if `/etc/openvpn3/netcfg.json` is a symlink

Open
#444 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
53/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
cpp, linux
Domain
networking

Research direction

Start by tracing how OpenVPN 3 reads /etc/openvpn3/netcfg.json during client-session startup and compare its behavior for a symlink and a regular file. The report provides a minimal NixOS configuration that reproduces the failure; use it to investigate and verify the fix. Done means a client session can start when netcfg.json points to a file in the Nix store.

Written by the indexing model from the issue text.

Description

On NixOS, configuration files are symlinks to the real files in the nix store. Openvpn3 fails to start a client session in this configuration. Removing the link or using a regular file allows a tunnel to be established.

Image

The nix conf used to setup openvpn is very minimal:

programs.openvpn3 = {
    enable = true;
    netcfg.settings = {
        log_level = 4;
    };
};

Nix options for Openvpn3

My full nix files are public if there's some extra context to be gleaned there, but the options above are the only vpn-related ones I set anywhere.

Dominant language
C++
Stars
1.2k
Forks
473
PR merge metrics
No merged PRs in 30d

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from OpenVPN/openvpn3

All issues in OpenVPN/openvpn3

Similar issues

More C++ issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.