-
Notifications
You must be signed in to change notification settings - Fork 2
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
MTU value error #15
Comments
It looks like Microsoft's API is a mess. It is impossible to get the MTU correctly. The current solution may only be through the command line and then parse the results. (Some(1450), None) Maybe this feature will be completed sometime in the future. netsh interface ipv4 set interface "wintun" mtu=1450
netsh interface ipv6 set interface "wintun" mtu=2450
netsh interface ipv4 show subinterface
netsh interface ipv6 show subinterface |
This method can retrieve the MTU as expected.
|
The correct MTU value can be obtained either by https://crates.io/crates/mtu or copy the code from this crates into wintun-bindings |
wintun-bindings/src/util.rs
Line 497 in 41ff615
The MTU retrieved is for IPv6, but the MTU is set for IPv4 in the command line. Therefore, the retrieved MTU is always 65535.
The text was updated successfully, but these errors were encountered: