Jump to content
Not connected, Your IP: 35.168.18.209
yepper

Way to edit AirVPN config file to use my preferred DNS?

Recommended Posts

I use OpenVPN for Android on my Nvidia Shield TV with my AirVPN config files. It lets you edit your VPN Profile to "Override DNS Settings by Server," and enter your own preferred DNS server and backup DNS server. But (I think) then your DNS requests don't get tunneled. I'm presently looking into how to use DNScrypt with my setup, but it's getting really complicated, so meanwhile it seems like it would be a lot simpler if there were a way to edit my AirVPN config file to make it use my choice of DNS and backup DNS addresses, so my DNS woud still get tunneled. Can I do that? If so, could someone get me started by pointing me to a landmark in my AirVPN config file to make the edits in a text editor?

Share this post


Link to post

Hello!
 

Have you tried Eddie for Android? It has the DNS setting I believe you're looking for . Maybe that's the altogether simpler option you're looking for.


Moderators do not speak on behalf of AirVPN. Only the Official Staff account does. Please also do not run Tor Exit Servers behind AirVPN, thank you.
Did you make a guide or how-to for something? Then contact me to get it listed in my new user guide's Guides Section, so that the community can find it more easily.

Share this post


Link to post

^ Yes, I had tried Eddie first thing, but I'm sorry, I tore my hair out for several days over its instability I experienced — it kept spontaneously kicking me off my VPN connection — so I settled on OpenVPN for Android, and it's been rock solid day in and day out.

 

Do you know how to manually edit my AirVPN config file to specify my preferred DNS addresses?

Share this post


Link to post

My AirVPN config looks like this at the beginning:

# --------------------------------------------------------
# Air VPN | https://airvpn.org | Friday 15th of March 2019 01:41:11 AM
# OpenVPN Client Configuration
# AirVPN_Netherlands_UDP-443
# --------------------------------------------------------

client
dev tun
remote nl.vpn.airdns.org 443
resolv-retry infinite
nobind
persist-key
persist-tun
auth-nocache
route-delay 5
verb 3
explicit-exit-notify 5
remote-cert-tls server
cipher AES-256-CBC
comp-lzo no
proto udp
key-direction 1
<ca>
-----BEGIN CERTIFICATE-----
.
.
.

I've been googling around, and I've stumbled onto this:

dhcp-option DNS x.x.x.x

Could I simply replace the line in my above config (I'm just taking a wild guess):

remote nl.vpn.airdns.org 443

...with, for example, Google's, for my desired primary and secondary DNS addresses to be tunneled through my VPN?:

dhcp-option DNS 8.8.4.4
dhcp-option DNS 8.8.8.8

How would I test this? How does one determine one's actual DNS address that gets used?

Share this post


Link to post

As of this writing, there have been 677 views of this thread. Are there no seasoned OpenVPN techies among you who can help me out and tell me the syntax to manually specify the DNS servers I wish to use in my AirVPN config file?

Share this post


Link to post

My AirVPN config looks like this at the beginning:

# --------------------------------------------------------
# Air VPN | https://airvpn.org | Friday 15th of March 2019 01:41:11 AM
# OpenVPN Client Configuration
# AirVPN_Netherlands_UDP-443
# --------------------------------------------------------

client
dev tun
remote nl.vpn.airdns.org 443
resolv-retry infinite
nobind
persist-key
persist-tun
auth-nocache
route-delay 5
verb 3
explicit-exit-notify 5
remote-cert-tls server
cipher AES-256-CBC
comp-lzo no
proto udp
key-direction 1
<ca>
-----BEGIN CERTIFICATE-----
.
.
.

I've been googling around, and I've stumbled onto this:

dhcp-option DNS x.x.x.x

Could I simply replace the line in my above config (I'm just taking a wild guess):

remote nl.vpn.airdns.org 443

...with, for example, Google's, for my desired primary and secondary DNS addresses to be tunneled through my VPN?:

dhcp-option DNS 8.8.4.4
dhcp-option DNS 8.8.8.8

How would I test this? How does one determine one's actual DNS address that gets used?

 

 

Not sure on how to implement, but to check if they are being used visit https://ipleak.net/ or https://leaktest.online/dns/

Share this post


Link to post

^ Thanks for that. I tried-out the ipleak.net test on my Mac—no VPN involved—and it said my DNS was 162.158.76.230, which is in an adjacent state to mine in the USA. I was surprised, because I have my router set to use the Cloudflare DNS 1.1.1.1, but when I investigated 162.158.76.230, it said it was a Cloudflare IP address. Is that normal, or should it have shown 1.1.1.1? Or does Cloudflare 1.1.1.1 hand-off DNS duties to a more nearby location?

 

I still wish someone could tell me how to edit my AirVPN config to use my chosen DNS within the tunnel. Should my syntax be based on what AirVPN used for its own DNS, for example:

remote 1.1.1.1 443

...or should I use the aforementioned syntax?:

dhcp-option DNS 1.1.1.1

Surely some of the over 800 viewers of this thread must know this right off the top of your head. A little help here, please, experts!

Share this post


Link to post

^ Thanks for that. I tried-out the ipleak.net test on my Mac—no VPN involved—and it said my DNS was 162.158.76.230, which is in an adjacent state to mine in the USA. I was surprised, because I have my router set to use the Cloudflare DNS 1.1.1.1, but when I investigated 162.158.76.230, it said it was a Cloudflare IP address. Is that normal, or should it have shown 1.1.1.1? Or does Cloudflare 1.1.1.1 hand-off DNS duties to a more nearby location?

 

Correct, it hands off to all of the closest servers to you that cloudflare owns.  I normally get at least 30+ servers listed on ipleak.

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Security Check
    Play CAPTCHA Audio
    Refresh Image

×
×
  • Create New...