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

topology: simplify local address configuration #4489

Merged
merged 4 commits into from
Mar 21, 2024

Conversation

matzf
Copy link
Collaborator

@matzf matzf commented Mar 19, 2024

The router interface section of the topology.json file previously had two fields to specify the local address of the router:

  • public: IP:port
  • bind: IP

The idea was that normally only public is supplied. When behind NAT, then bind could override the IP address on which the router binds locally, and public would be the address that is visible to the remote router. The only place where this could be relevant is the router BFD keep-alive messages, as these contain the local address of the router in the SCION address header. There is, however, no check that enforces that this matches the underlay address.
In practice, if bind is supplied, the IP of public has simply been ignored.

This change replaces public and bind with a new local field. The old fields are deprecated, but still processed for backwards compatibility.
The local support omitting the IP to bind on any local IP. This was previously possible only by explicitly configuring a zero IP address.

Aside:

  • change the internal representation from net.UDPAddr to netip.AddrPort. Note that this changes the representation in the json dump of the /topology status page.
  • remove unused BRNames

@matzf
Copy link
Collaborator Author

matzf commented Mar 19, 2024

This change is Reviewable

Copy link
Contributor

@oncilla oncilla left a comment

Choose a reason for hiding this comment

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

Reviewed 36 of 36 files at r1, all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @matzf)

@matzf matzf merged commit 2798312 into scionproto:master Mar 21, 2024
4 checks passed
@matzf matzf deleted the router-local-addr branch March 21, 2024 08:14
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.

None yet

2 participants