From: Serge <snp@z9.ru>
To: wireguard@lists.zx2c4.com
Subject: Re: Tunnel traffic in VRF
Date: Sun, 26 Jan 2020 19:46:26 +0000 [thread overview]
Message-ID: <CAN1uEJ2XALrdwaFjCv3557ef6rKcCGXA79kgK+79WOCddc4Nsg@mail.gmail.com> (raw)
In-Reply-To: <38df62df-2c77-48b1-f020-48a410ff381e@orlandi.com>
[-- Attachment #1.1: Type: text/plain, Size: 728 bytes --]
On Sat, 25 Jan 2020 at 14:24, Daniele Orlandi <daniele@orlandi.com> wrote:
> A proper binding to the correct VRF would be a better approach, however.
On user-level it can be done by SO_BINDTODEVICE socket option:
«Applications that are to work within a VRF need to bind their socket to
the VRF device:
setsockopt(sd, SOL_SOCKET, SO_BINDTODEVICE, dev, strlen(dev)+1);
»
But I am not sure how things work on kernel level.
It would be great to add an option like 'listen-interfaces':
wg set <interface> [listen-port <port>] [listen-interfaces
<interface1>[,<interface2>]... ]
[Interface]
ListenPort=54002
ListenInterfaces=vrf-red,vrf-green
This option can be useful in a non-VRF environment too.
[-- Attachment #1.2: Type: text/html, Size: 869 bytes --]
[-- Attachment #2: Type: text/plain, Size: 148 bytes --]
_______________________________________________
WireGuard mailing list
WireGuard@lists.zx2c4.com
https://lists.zx2c4.com/mailman/listinfo/wireguard
prev parent reply other threads:[~2020-01-30 1:56 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-01-24 0:03 Daniele Orlandi
2020-01-25 6:55 ` Steven Honson
2020-01-25 9:13 ` Toke Høiland-Jørgensen
2020-01-25 14:10 ` Daniele Orlandi
2020-01-25 16:03 ` b13253
2020-01-26 19:46 ` Serge [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=CAN1uEJ2XALrdwaFjCv3557ef6rKcCGXA79kgK+79WOCddc4Nsg@mail.gmail.com \
--to=snp@z9.ru \
--cc=wireguard@lists.zx2c4.com \
/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;
as well as URLs for NNTP newsgroup(s).