Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Internal scan of rfc6598 using --no-private-ipv4 #1721

Closed
xlc opened this issue Sep 26, 2023 · 4 comments
Closed

Internal scan of rfc6598 using --no-private-ipv4 #1721

xlc opened this issue Sep 26, 2023 · 4 comments
Assignees

Comments

@xlc
Copy link
Contributor

xlc commented Sep 26, 2023

Original issue paritytech/substrate#9922

This happened to one of our collator node.

is_global is including Shared Address Space (100.64.0.0/10) which causes the problem.

We need to either have a generalized way to specify the ranges to block, or have another flag to block shared address space, or explicitly block it when no-private-ipv4 is enabled

@bkchr
Copy link
Member

bkchr commented Sep 27, 2023

CC @paritytech/networking

@altonen
Copy link
Contributor

altonen commented Sep 27, 2023

We could introduce another flag --only-global-ipv4 as suggested here which filters out a whole bunch of addresses. That seems more natural than patching --no-private-ipv4 to include Shared Address Space

@dmitry-markin
Copy link
Contributor

That's interesting, because the docs and sources of ip_network::Ipv4Network::is_global clearly say that the Shared Address Space (100.64.0.0/10) is not considered global. And we already use IpNetwork::is_global which uses Ipv4Network::is_global internally for IPv4 addresses when --no-private-ipv4 is specified:

Some(Protocol::Ip4(addr)) if !IpNetwork::from(addr).is_global() => false,

What exactly is the problem with the collator node? Should the IPv4 shared address space be included or excluded from the connection attempts? Becasue right now --no-private-ipv4 flag behaves exactly as the proposed --only-global-ipv4.

@xlc
Copy link
Contributor Author

xlc commented Sep 28, 2023

yeah I read the docs wrong. Right now it should work. Let me double check the logs and service provider.

@xlc xlc closed this as completed Sep 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

No branches or pull requests

4 participants