Skip to content

Commit

Permalink
dco-win: disable dco in server mode if multiple --local options defined
Browse files Browse the repository at this point in the history
dco-win doesn't yet support multisocket, so for the time
being we have to fallback to tap-windows6.

Change-Id: I8724eda269b816dd2cfd0833d467e6d24054e96f
Signed-off-by: Lev Stipakov <[email protected]>
Acked-by: Gert Doering <[email protected]>
Message-Id: <[email protected]>
URL: https://www.mail-archive.com/[email protected]/msg30805.html
Signed-off-by: Gert Doering <[email protected]>
  • Loading branch information
lstipakov authored and cron2 committed Feb 5, 2025
1 parent 060ead6 commit 4719687
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/openvpn/dco.c
Original file line number Diff line number Diff line change
Expand Up @@ -279,6 +279,12 @@ dco_check_option_ce(const struct connection_entry *ce, int msglevel, int mode)
msg(msglevel, "NOTE: --remote is not defined. This DCO version doesn't support multipeer. Disabling Data Channel Offload");
return false;
}

if ((mode == MODE_SERVER) && (ce->local_list->len > 1))
{
msg(msglevel, "NOTE: multiple --local options defined, disabling data channel offload");
return false;
}
#endif

return true;
Expand Down Expand Up @@ -355,6 +361,12 @@ dco_check_startup_option(int msglevel, const struct options *o)
return false;
}

if ((o->mode == MODE_SERVER) && o->ce.local_list->len > 1)
{
msg(msglevel, "multiple --local options defined, disabling data channel offload");
return false;
}

#elif defined(TARGET_LINUX)
/* if the device name is fixed, we need to check if an interface with this
* name already exists. IF it does, it must be a DCO interface, otherwise
Expand Down

0 comments on commit 4719687

Please sign in to comment.