-
Notifications
You must be signed in to change notification settings - Fork 83
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
Interface specific addresses #26
base: master
Are you sure you want to change the base?
Conversation
723b659
to
f17dec6
Compare
3dc5a26
to
153d97c
Compare
if (mask != null) | ||
{ | ||
var network = IPNetwork.Parse(local, mask); | ||
return network.Contains(remote); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When testing this on multi-interface setup, I was still seeing some weird results, like my local Hyper-V interface addresses being used in answers to queries sent from remote machines on a completely different network, which I'd expect would be filtered out.
} | ||
|
||
// Can not determine reachability, assume that network routing can do it. | ||
return true; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are there no further heuristics we could use if all else fails? Maybe something like local.AddressFamily == remote.AddressFamily
? In my multi-interface test setup I was seeing a lot of IPv6 responses that get removed if I add that additional comparison, but I'm not sure if that's right or wrong...
See issue #25