-
Notifications
You must be signed in to change notification settings - Fork 326
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
add a way to use openresolv #101
Comments
Good idea, such a contribution would be welcomed! |
sadly, I have no skills in C. |
I made some tests about it, and it appears that the use of |
I have implemented the ip-param option. @CircleCode could you test mrbaseman@d847932 please? |
maybe we could include the ip-up.d/ and ip-down.d/ scripts at least as a sample or provide the recipe in the man page |
@mrbaseman thanks for this code. |
@digmore has confirmed in #124 that the ipparam setting from my branch was working, so I have just merged this into master. |
Just a remark: pppd sets a couple of environment variables (see man pppd). ipparam is currently passed through openfortivpn, but inside the ip-up / ip-down scripts one can replace variables in this string as follows: |
@mrbaseman @CircleCode May I ask you to provide an example on how to setup ip-up and ip-down? |
I have just tried with
and /etc/ppp/ip-up.d/000resolvconf:
When you also want to set up routing manually, you should use --no-routes, but you would have to hard-code the routes in the script. See The general task that you describe "only route subdomains" is a quite complex task. For each IP packet you would have to reverse-lookup the domain and then make a routing decision based on the FQDN. However, if you know the assigned subnets, you could check |
@skycaptain I just read your comment again and I think I misunderstood. You were talking about name resolution whereas my answer was about routing. |
@CircleCode I am currently trying to rationalize DNS handling in openfortivpn. The plan is to stop messing with DNS settings in openfortivpn in the future, instead entirely delegate DNS settings to pppd. In this context, would it make sense to drop this issue, and perhaps open an new ticket against pppd? In the short term we could still add openresolv support in openfortivpn. I cannot easily make sense of how to use openresolv in a distribution such as Ubuntu. Could you point me to appropriate documentation? |
@CircleCode See commit f383084. The default is to let pppd handle DNS: from now on openfortivpn will not try to modify |
in #419 I have improved the documentation of the relevant options. I think we can close this issue now, since the necessary options have been implemented in the meantime, the wiki has been created and with the latest pull request the man page will be updated as well. If anything is still missing, please open a new issue. |
this implements the feature request from adrienverge#486 and adrienverge#101
this implements the feature request from adrienverge#486 and adrienverge#101
this implements the feature request from adrienverge#486 and adrienverge#101
this implements the feature request from adrienverge#486 and adrienverge#101, update help and man page
this implements the feature request from adrienverge#486 and adrienverge#101, update help and man page
We have noticed that this issue in fact was not solved. We had to revert what was meant to be a solution, but pppd's ip-up-scripts are much more tricky to maintain than just installing resolvconf in the hope that it does the right thing. |
when openresolv is available, please add a way to use it so that openfortivpn does not overwrite resolv.conf.
The text was updated successfully, but these errors were encountered: