FQDN for routes should expand to all IPs (second round)
PATCH 1/1 FQDN for routes should expand to all IPs (second round)
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
(resent - to get it into the mailing list)
Hi Stefan!
I believe you've noticed we've included a patch which aims to remove the randomisation I found when reviewing your patch.
- From the following review discussion, a few other things needs to be changed and I hope you are willing to look into adopting your patch to those guidelines. This is also to follow the standards [1] we try to introduce as well.
So, to give a summary to what needs to be done:
* This feature should be #ifdef'ed, so that it can be disabled for those not wanting this feature.
* MAX_IPS_PER_HOSTNAME should be set via ./configure. I'd probably recommend that if this value is 0 the feature is not enabled (covers the first point automatically and simplifies ./configure) If f.ex. only
- --enable-resolve-all-ips (probably need a better targeted name) is given without a number, the default should be 20.
* Implement this patch on top of the frp branch, and make sure you add the possibility to disable the randomisation of resolving.
I hope I haven't forgotten or overseen anything now.
Would you be willing to do this job? When these things are covered, I believe the patch has reached a state where it is suitable for inclusion.
kind regards,
David Sommerseth
[1]
<http://www.secure-computing.net/wiki/index.php/OpenVPN/Developer_documentation>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/
iEYEARECAAYFAkuIEQsACgkQDC186MBRfroqKQCfZGkkMtIUDkIIkXYXXLirOlts nBcAn2nIn+xsVu/9Fz7AOlzEgQPohETw
=SE/7
-----END PGP SIGNATURE-----
Quoted 4 lines
- From the following review discussion, a few other things needs to be changed and I hope you are willing to look into adopting your patch to those guidelines. This is also to follow the standards [1] we try to introduce as well.
Sure, I'd like to get this in the main OpenVPN code, so I'll do what it takes.
Quoted 3 lines
So, to give a summary to what needs to be done:
* This feature should be #ifdef'ed, so that it can be disabled for those not wanting this feature.
AFAIK this is a bug-fix rather than a feature (the current behavior for FQDNs mapping to multiple IPs is pretty difficult to justify), so I wonder why it requires such #ifdef'ing.
Quoted 5 lines
*
MAX_IPS_PER_HOSTNAMEshould be set via ./configure. I'd probably recommend that if this value is 0 the feature is not enabled (covers the first point automatically and simplifies ./configure) If f.ex. only
- --enable-resolve-all-ips (probably need a better targeted name) is given without a number, the default should be 20.
I'll do that. I do wonder: IIUC setting this to 1 might result in reproducing the current (buggy) behavior, so would #ifdef'ing still be necessary?
Quoted 1 line
* Implement this patch on top of the frp branch,
I'm not sure what you mean by the "frp" branch. Is tht a new branch in the Git repository?
Quoted 2 lines
and make sure you add the possibility to disable the randomisation of resolving.
Of course, as before I'll just try and keep the "old" code and/or behavior.
Quoted 2 lines
Would you be willing to do this job? When these things are covered, I believe the patch has reached a state where it is suitable for inclusion.
OK, I'll let you know when it's ready for review,
Stefan
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Quoted 7 lines · Stefan Monnier
Quoted 4 lines
- From the following review discussion, a few other things needs to be changed and I hope you are willing to look into adopting your patch to those guidelines. This is also to follow the standards [1] we try to introduce as well.
Sure, I'd like to get this in the main OpenVPN code, so I'll do what it takes.
Cool, thanks a lot!
Quoted 7 lines
Quoted 3 lines
So, to give a summary to what needs to be done:
* This feature should be #ifdef'ed, so that it can be disabled for those not wanting this feature.AFAIK this is a bug-fix rather than a feature (the current behavior for FQDNs mapping to multiple IPs is pretty difficult to justify), so I wonder why it requires such #ifdef'ing.
I was doing some considerations back and forth here before starting this second round. The issue is that it changes the behaviour quite a lot from what might be expected from earlier versions (if you're used to the former behaviour). And it introduces some new code paths, including a new function (getaddr_all). So I would prefer to consider this, at least for now, as a feature change rather than a bug fix.
By all means, I do see that in your perspective the current default behaviour is considered as a bug. But others might have a different opinion about that. Those doing the testing will anyway be requested to enable all these new features, so this feature will be tested and considered for default enablement later on in the process. But it will be easier to track down where a bug was introduced later on, by being able to disable such bigger functional changes.
Quoted 9 lines
Quoted 5 lines
*
MAX_IPS_PER_HOSTNAMEshould be set via ./configure. I'd probably recommend that if this value is 0 the feature is not enabled (covers the first point automatically and simplifies ./configure) If f.ex. only
- --enable-resolve-all-ips (probably need a better targeted name) is given without a number, the default should be 20.I'll do that. I do wonder: IIUC setting this to 1 might result in reproducing the current (buggy) behavior, so would #ifdef'ing still be necessary?
I prefer that having it set to 0 gives the old code path. The value of one can be used to have the same behaviour as 0, but with your new code path.
Quoted 4 lines
Quoted 1 line
* Implement this patch on top of the frp branch,
I'm not sure what you mean by the "frp" branch. Is tht a new branch in the Git repository?
Yes, it's the feature removal branch. The reason for this is that the removal of the randomisation is found in this branch. And here you'll only find those changes, so a conflict with other fea
Quoted 4 lines
Quoted 2 lines
and make sure you add the possibility to disable the randomisation of resolving.
Of course, as before I'll just try and keep the "old" code and/or behavior.
Thanks!
Quoted 4 lines
Quoted 2 lines
Would you be willing to do this job? When these things are covered, I believe the patch has reached a state where it is suitable for inclusion.
OK, I'll let you know when it's ready for review,
Thanks again, Stefan! I appreciate your effort into getting this code ready for inclusion! (Even though, my requirements might be a big PITA :)) Anyhow, I only try to follow the guidelines the community have agreed on, in discussions with James. Following those guidelines should hopefully give a higher probability to get the code more easily accepted into the stable releases.
kind regards,
David Sommerseth
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/
iEYEARECAAYFAkuKWaIACgkQDC186MBRfrqY6ACfSxy7smYDsqNVnVh7+cUvbGG9 5/UAnREh8N/QTBKOSpD/EEVsEhuMefPq
=XPby
-----END PGP SIGNATURE-----
Quoted 4 lines
I was doing some considerations back and forth here before starting this second round. The issue is that it changes the behaviour quite a lot from what might be expected from earlier versions (if you're used to the former behaviour).
I'm at a loss when it comes to try and imagine someone who's used to the current behavior and bothered by the new behavior. Really. How can the current behavior ever be preferable? Why would someone ever prefer that a route would be randomly chosen to either go through the VPN or not.
I haven't heard any such someone raise her voice, and neither have I heard anyone come up with a scenario where such a someone could exist.
If someone could give at least some vaguely plausible scenario, that'd help.
Quoted 3 lines
And it introduces some new code paths, including a new function (
getaddr_all). So I would prefer to consider this, at least for now, as a feature change rather than a bug fix.
OK, so it's a question of code, not of behavior. That does make sense.
Quoted 6 lines
Quoted 6 lines
Quoted 5 lines
*
MAX_IPS_PER_HOSTNAMEshould be set via ./configure. I'd probably recommend that if this value is 0 the feature is not enabled (covers the first point automatically and simplifies ./configure) If f.ex. only
- --enable-resolve-all-ips (probably need a better targeted name) is given without a number, the default should be 20.
Quoted 7 lines
Quoted 3 lines
I'll do that. I do wonder: IIUC setting this to 1 might result in reproducing the current (buggy) behavior, so would #ifdef'ing still be necessary?
I prefer that having it set to 0 gives the old code path. The value of one can be used to have the same behaviour as 0, but with your new code path.
That also makes sense then, yes.
Quoted 6 lines
Quoted 3 lines
Quoted 1 line
* Implement this patch on top of the frp branch,
I'm not sure what you mean by the "frp" branch. Is tht a new branch in the Git repository?
Yes, it's the feature removal branch. The reason for this is that the removal of the randomisation is found in this branch. And here you'll only find those changes, so a conflict with other fea
I see, that's fine. IIUC, this will cause a conflict when merging with some of the IPv6 code. We'll cross this bridge when we get there.
Stefan
Quoted 9 lines · Stefan Monnier
I'm at a loss when it comes to try and imagine someone who's used to the
current behavior and bothered by the new behavior. Really. How can the
current behavior ever be preferable? Why would someone ever prefer that
a route would be randomly chosen to either go through the VPN or not.
Quoted 6 lines
I haven't heard any such someone raise her voice, and neither have I heard anyone come up with a scenario where such a someone could exist.
If someone could give at least some vaguely plausible scenario, that'd help.
Maybe there's more than one tunnel and there's some stupid load balancing going on using a hosts file? (Along with deleting all non-vpn routes.)
??
Karl <[email protected]...>
Free Software: "You don't pay back, you pay forward."
-- Robert A. Heinlein
Quoted 5 lines
Quoted 2 lines
If someone could give at least some vaguely plausible scenario, that'd help.
Maybe there's more than one tunnel and there's some stupid load balancing going on using a hosts file? (Along with deleting all non-vpn routes.)
[ Setting aside the fact that using OpenVPN's broken handling of
multi-FQDN to implement this is far from the only option. ]
I'm not even sure *how* this could work: how would you ensure that the different tunnels happen to (together) route all IPs rather than all chosing the same IP (for example)?
Stefan
Quoted 6 lines · Stefan Monnier
Quoted 5 lines
Quoted 2 lines
If someone could give at least some vaguely plausible scenario, that'd help.
Maybe there's more than one tunnel and there's some stupid load balancing going on using a hosts file? (Along with deleting all non-vpn routes.)
Quoted 7 lines
[ Setting aside the fact that using OpenVPN's broken handling of
multi-FQDN to implement this is far from the only option. ]I'm not even sure *how* this could work: how would you ensure that the
different tunnels happen to (together) route all IPs rather than all chosing the same IP (for example)?
I'm just waving my hands here; I'm not thinking closely about the details and don't want to. It sounded plausible when it popped into my head so I sent a braindump. I was thinking along the lines of "well if you might want to randomize remote endpoint choice using FQDNs resolved from a hosts file..."
Sorry if this has been more confusing than helpful.
Karl <[email protected]...>
Free Software: "You don't pay back, you pay forward."
-- Robert A. Heinlein