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

Wireguard support - take 2. #1056

Merged
merged 1 commit into from
Jan 8, 2024
Merged

Wireguard support - take 2. #1056

merged 1 commit into from
Jan 8, 2024

Conversation

aanon4
Copy link
Contributor

@aanon4 aanon4 commented Jan 7, 2024

The initial implementation of wireguard support failed for > 1 tunnel server because of the way wireguard handles routing. Wireguard requires not only the next hop route to be specified in the "allowed ips" list, but all possibly destinations. The target 0.0.0.0/0 can help here, but you can only use that on 1 peer .. so the moment we need 2 peers this approach fails.

This version solve the problem by creating unique server/client peers and each can be given 0.0.0.0/0. The cost to do this is that each server must have its own port number, so we cannot use just 1 port for wireguard, but instead an array of ports; 5525, 5526, 5526 ...

Supernode wireguard ports now start at 6526 to allow a single IP to front both a normal wireguard tunnel server and a supernode tunnel server.

The initial implementation of wireguard support failed for > 1 tunnel server
because of the way wireguard handles routing; it doesnt play well with dynamic
routes.
This version solve the problem, but at the cost of an open port per tunnel server
as they cannot be shared.
@aanon4 aanon4 merged commit e486a61 into aredn:main Jan 8, 2024
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

1 participant