Skip to content

Conversation

@tinoue
Copy link

@tinoue tinoue commented Jun 17, 2021

This PR supports GRE tunneling protocol over tailscale network.

@tinoue tinoue changed the title Support GRE IP protocol. Support GRE L2/L3 tunneling protocol. Jun 17, 2021
@DentonGentry
Copy link
Contributor

Could you add Signoff lines to the commit descriptions?
https://github.com/tailscale/tailscale/pull/2162/checks?check_run_id=2880344338

tinoue and others added 3 commits June 26, 2021 13:48
Signed-off-by: Takeshi Inoue <tinoue@xevo.com>
Co-authored-by: Christine Dodrill <me@christine.website>
Signed-off-by: Takeshi Inoue <tinoue@xevo.com>
Co-authored-by: Christine Dodrill <me@christine.website>
Signed-off-by: Takeshi Inoue <tinoue@xevo.com>
@tinoue tinoue force-pushed the tinoue/support-gre branch from 571a394 to 861352a Compare June 26, 2021 04:49
ipproto.UDP,
ipproto.ICMPv4,
ipproto.ICMPv6,
ipproto.GRE,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we don't want to add GRE to the defaultProtos. It needs to be opt-in for users, like we did for SCTP.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bradfitz
Thank you for your comment.
To make GRE as opt-in option is nice idea.

I checked about SCTP and it seems to be allowed by port based ACL.
The problem is GRE doesn't have any port - like ICMP - and current ACL doesn't have protocol based rule.
Do you have any idea ?

@amosbird
Copy link

amosbird commented Nov 4, 2022

Is there any plan to merge this PR?

@tinoue
Copy link
Author

tinoue commented Nov 4, 2022

@amosbird Thanks for reminding me about this PR. Closed becuase the latest tailscale already supports any type of protocol.

@tinoue tinoue closed this Nov 4, 2022
@amosbird
Copy link

amosbird commented Nov 4, 2022

@tinoue Great. Starting from which version does tailscale have this ability?

@tinoue
Copy link
Author

tinoue commented Nov 4, 2022

@amosbird From 1.2.0 according to #2163 (comment)
You can specify any protocol byTailscale ACL rule (see proto field): https://tailscale.com/kb/1018/acls/#acl-rules

bradfitz added a commit that referenced this pull request Dec 22, 2022
01b90df added SCTP support before
(with explicit parsing for ports) and
69de3bf tried to add support for
arbitrary IP protocols (as long as the ACL permited a port of "*",
since we might not know how to find ports from an arbitrary IP
protocol, if it even has such a concept). But apparently that latter
commit wasn't tested end-to-end enough. It had a lot of tests, but the
tests made assumptions about layering that either weren't true, or
regressed since 1.20.

Updates #2162
Updates #2163

Change-Id: I9659b3ece86f4db51d644f9b34df78821758842c
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
bradfitz added a commit that referenced this pull request Jan 14, 2023
01b90df added SCTP support before
(with explicit parsing for ports) and
69de3bf tried to add support for
arbitrary IP protocols (as long as the ACL permited a port of "*",
since we might not know how to find ports from an arbitrary IP
protocol, if it even has such a concept). But apparently that latter
commit wasn't tested end-to-end enough. It had a lot of tests, but the
tests made assumptions about layering that either weren't true, or
regressed since 1.20. Notably, it didn't remove the (*Filter).pre
bidirectional filter that dropped all "unknown" protocol packets both
leaving and entering, even if there were explicit protocol matches
allowing them in.

Also, don't map all unknown protocols to 0. Keep their IP protocol
number parsed so it's matchable by later layers. Only reject illegal
things.

Fixes #6423
Updates #2162
Updates #2163

Change-Id: I9659b3ece86f4db51d644f9b34df78821758842c
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
bradfitz added a commit that referenced this pull request Jan 14, 2023
01b90df added SCTP support before
(with explicit parsing for ports) and
69de3bf tried to add support for
arbitrary IP protocols (as long as the ACL permited a port of "*",
since we might not know how to find ports from an arbitrary IP
protocol, if it even has such a concept). But apparently that latter
commit wasn't tested end-to-end enough. It had a lot of tests, but the
tests made assumptions about layering that either weren't true, or
regressed since 1.20. Notably, it didn't remove the (*Filter).pre
bidirectional filter that dropped all "unknown" protocol packets both
leaving and entering, even if there were explicit protocol matches
allowing them in.

Also, don't map all unknown protocols to 0. Keep their IP protocol
number parsed so it's matchable by later layers. Only reject illegal
things.

Fixes #6423
Updates #2162
Updates #2163

Change-Id: I9659b3ece86f4db51d644f9b34df78821758842c
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
bradfitz added a commit that referenced this pull request Jan 14, 2023
01b90df added SCTP support before
(with explicit parsing for ports) and
69de3bf tried to add support for
arbitrary IP protocols (as long as the ACL permited a port of "*",
since we might not know how to find ports from an arbitrary IP
protocol, if it even has such a concept). But apparently that latter
commit wasn't tested end-to-end enough. It had a lot of tests, but the
tests made assumptions about layering that either weren't true, or
regressed since 1.20. Notably, it didn't remove the (*Filter).pre
bidirectional filter that dropped all "unknown" protocol packets both
leaving and entering, even if there were explicit protocol matches
allowing them in.

Also, don't map all unknown protocols to 0. Keep their IP protocol
number parsed so it's matchable by later layers. Only reject illegal
things.

Fixes #6423
Updates #2162
Updates #2163

Change-Id: I9659b3ece86f4db51d644f9b34df78821758842c
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
coadler pushed a commit to coder/tailscale that referenced this pull request Feb 2, 2023
01b90df added SCTP support before
(with explicit parsing for ports) and
69de3bf tried to add support for
arbitrary IP protocols (as long as the ACL permited a port of "*",
since we might not know how to find ports from an arbitrary IP
protocol, if it even has such a concept). But apparently that latter
commit wasn't tested end-to-end enough. It had a lot of tests, but the
tests made assumptions about layering that either weren't true, or
regressed since 1.20. Notably, it didn't remove the (*Filter).pre
bidirectional filter that dropped all "unknown" protocol packets both
leaving and entering, even if there were explicit protocol matches
allowing them in.

Also, don't map all unknown protocols to 0. Keep their IP protocol
number parsed so it's matchable by later layers. Only reject illegal
things.

Fixes tailscale#6423
Updates tailscale#2162
Updates tailscale#2163

Change-Id: I9659b3ece86f4db51d644f9b34df78821758842c
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants