From: Gianluca Gabrielli <tuxmealux@protonmail.com>
To: "wireguard@lists.zx2c4.com" <wireguard@lists.zx2c4.com>
Subject: Re: TCP Wireguard with socat
Date: Mon, 12 Mar 2018 05:15:52 -0400 [thread overview]
Message-ID: <kvc0wmbZv_OgdINTzQhQnFxt0vFHFoqpVqYTFQkfPYOY_vqZHJN-bEvL9oJYuk-LJHubVyWlP2JCXTbRLK_9fGp7r298KveBFiOsF6P9r4Y=@protonmail.com> (raw)
In-Reply-To: <e0bff705-f328-0071-0fb7-0367d36f0074@urlichs.de>
=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90 Original Me=
ssage =E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90
On March 9, 2018 10:45 PM, Matthias Urlichs <matthias@urlichs.de> wrote:
> On 09.03.2018 17:41, Gianluca Gabrielli wrote:
>=20
> > My first thought has been to make use of socat
>=20
> socat can do either packet streams or byte streams. A UDP socket (or a
>=20
> tun/tap interface) is a packet stream. TCP is a byte stream. You can't
>=20
> forward a packet stream into a byte stream. (Well, OK, socat does allow
>=20
> you to set that up, but it won't work.)
>=20
> You need wrap your packets in some sort of frame (simplest: precede each
>=20
> with a length word (but think about byte ordering)). I'm sure there are
>=20
> programs which do that, or you can write your own. socat can't do it.
Forwarding UDP packets (message oriented) into a TCP connection (stream ori=
ented) could be done without any problem. Think about an OpenVPN TCP tunnel=
where you've redirected all your traffic, UDP connections as well.
Do you mean that socat just forward packets through the two specified chann=
el without wrapping them?
next prev parent reply other threads:[~2018-03-12 9:05 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-03-09 16:41 Gianluca Gabrielli
2018-03-09 21:45 ` Matthias Urlichs
2018-03-12 9:15 ` Gianluca Gabrielli [this message]
2018-03-12 11:30 ` Matthias Urlichs
2018-03-12 14:37 ` Gianluca Gabrielli
2018-03-12 15:14 ` Gianluca Gabrielli
2018-03-12 15:44 ` Tim Sedlmeyer
2018-03-12 16:45 ` Gianluca Gabrielli
2018-03-12 17:05 ` Matthias Urlichs
2018-03-12 18:47 ` Matthias Urlichs
2018-03-13 9:19 ` Gianluca Gabrielli
2018-03-13 13:43 ` Matthias Urlichs
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='kvc0wmbZv_OgdINTzQhQnFxt0vFHFoqpVqYTFQkfPYOY_vqZHJN-bEvL9oJYuk-LJHubVyWlP2JCXTbRLK_9fGp7r298KveBFiOsF6P9r4Y=@protonmail.com' \
--to=tuxmealux@protonmail.com \
--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).