• Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Search
  • Register
  • Login
Netgate Discussion Forum
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Search
  • Register
  • Login

Connected IP shows remote address, not local

Scheduled Pinned Locked Moved OpenVPN
2 Posts 2 Posters 459 Views
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • W Offline
    wiz561
    last edited by Aug 3, 2017, 5:04 PM

    I'm running OpenVPN and have a number of subnets and firewall ports open.  For example, let's say my OpenVPN subnet is 10.0.120.0/24 and my domain name is foo.org.  My workstation IP, before the OpenVPN connection is 12.4.1.20, for example.

    When I make an OpenVPN connection back home to foo.org, my IP, if I do a 'what's my ip' search, is my home IP address, which makes sense.  It's not passing traffic through the 12.4.1.20 connection for web browsing or anything like that.  However, the problem exists if I start to look at the apache logs on a server that has a firewall port open on it.  So, for example, if I connect to https://foo.org after I made the openvpn connection, my IP in the apache logs is 12.4.1.20 instead of the 10.0.120.2.

    Is there a way to tell OpenVPN to use the 10.0.120.2 IP instead of the 12.4.1.20 IP that it's showing when I make that connection?  Something makes me think that I can't but was wondering if anybody knows what I'm talking about and if there's a setting to change for it.

    Thanks!

    1 Reply Last reply Reply Quote 0
    • J Offline
      jimp Rebel Alliance Developer Netgate
      last edited by Aug 14, 2017, 7:34 PM

      You'd need to change your DNS such that OpenVPN clients would talk to a DNS server that returns the internal IP address for "foo.org" when they look it up.

      Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

      Need help fast? Netgate Global Support!

      Do not Chat/PM for help!

      1 Reply Last reply Reply Quote 0
      • First post
        Last post
      Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.
        [[user:consent.lead]]
        [[user:consent.not_received]]