aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorHimbeer <himbeer@disroot.org>2024-08-31 12:59:49 +0200
committerHimbeer <himbeer@disroot.org>2024-08-31 12:59:49 +0200
commit8fcdf11906a5748ac712944ad9a13d469f71de78 (patch)
tree368ac5c0d441230acc6745c522702d0bdf0183f0 /src
parent3803db829d2b893bbf06176ed1d122a9db623ec8 (diff)
Fix native eth0 ULA prefix inconsistency with GUA subnetting scheme
The subnet ID was incorrectly set to 0. The GUA prefix is subnetted differently and uses 0 for the WAN-side address of the router, starting internal subnets at 1. This commit sets the ULA subnet ID of the native eth0 interface from 0 to 1. The VLAN subnet IDs are already implemented correctly.
Diffstat (limited to 'src')
-rw-r--r--src/main.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main.rs b/src/main.rs
index 97eba45..57bca23 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -103,7 +103,7 @@ fn main() -> Result<()> {
fn configure_lan(conn: &Connection) -> Result<()> {
conn.address_flush("eth0".into())?;
conn.address_add_link_local("eth0".into(), LINK_LOCAL.into(), 64)?;
- conn.address_add("eth0".into(), ula!(0).into(), 64)?;
+ conn.address_add("eth0".into(), ula!(1).into(), 64)?;
conn.address_add("eth0".into(), "10.128.0.254".parse()?, 24)?;
Ok(())