Skip to content

Commit

Permalink
VPN: OpenVPN: Servers [legacy] - disable DCO, only supported for new …
Browse files Browse the repository at this point in the history
…instances (and prevents server startup for tun devices).
  • Loading branch information
AdSchellevis committed Jul 25, 2024
1 parent c95f42b commit 89135cd
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/etc/inc/plugins.inc.d/openvpn.inc
Original file line number Diff line number Diff line change
Expand Up @@ -530,6 +530,10 @@ function openvpn_reconfigure($mode, $settings, $device_only = false)
}

$conf .= "dev-type {$settings['dev_mode']}\n";
if ($settings['dev_mode'] == 'tun') {
/* legacy does not support DCO */
$conf .= "disable-dco\n";
}
$conf .= "dev-node /dev/{$devnode}\n";
$conf .= "writepid /var/run/openvpn_{$mode_id}.pid\n";
$conf .= "script-security 3\n";
Expand Down

0 comments on commit 89135cd

Please sign in to comment.