wireless printing with VPN

Discussion in 'Mac Accessories' started by Macinthelou, Jan 30, 2015.

  1. Macinthelou macrumors member

    Joined:
    Mar 15, 2011
    #1
    I am essentially always connected to my work network via VPN when I am using my MBP at home. This may be a simple question, but is there a way to connect via wifi to a printer? I tried this with my very old printer (Canon MP610) connected to an Airport (also older version) and was only able to get it to work if I disconnected from VPN.

    Are there newer printers that I could do this with?
     
  2. hallux macrumors 68020

    hallux

    Joined:
    Apr 25, 2012
    #2
    The concept of a VPN is that it creates a secure tunnel between the endpoints. No offramps so to speak, an "offramp" would be needed to access resources on your home network such as a printer.

    Put another way, when you connect to your work VPN you get an IP address from that network, because your home printer has a network address from your home network, you now can't communicate with it.

    It's not the fault of your printer, the only way around it is to plug it in as a USB printer.
     
  3. Macinthelou thread starter macrumors member

    Joined:
    Mar 15, 2011
    #3
    Thanks for the reply. I read something about certain printers having wifi-direct or something like that, in other words, it sounds like you can connect to the printer independent of your home network. Does that sound right?
     
  4. hallux macrumors 68020

    hallux

    Joined:
    Apr 25, 2012
    #4
    If you're hard-wired for the VPN connection, that MAY work as the wireless would be a different network. If you're on wireless, it wouldn't work as your wireless card can typically connect to only one network at a time.
     
  5. glenthompson macrumors 68000

    glenthompson

    Joined:
    Apr 27, 2011
    Location:
    Virginia
    #5
    Most VPN connections block any other network access. Your only option is to use a usb printer connection.
     
  6. priitv8 macrumors 68020

    Joined:
    Jan 13, 2011
    Location:
    Estonia
    #6
    What effect would the option to not send all traffic over VPN play in OS X built-in VPN? I always assumed it will decide based on destination's subnet, over which link to transmit, no?
     

    Attached Files:

    • VPN.png
      VPN.png
      File size:
      144.3 KB
      Views:
      19
  7. glenthompson macrumors 68000

    glenthompson

    Joined:
    Apr 27, 2011
    Location:
    Virginia
    #7
    That might allow access to local devices. I used to use a Cisco client that blocked all local network access. If you have some control over the client configuration it may work. I didn't have that option.
     
  8. SlCKB0Y, Feb 1, 2015
    Last edited: Feb 1, 2015

    SlCKB0Y macrumors 68040

    SlCKB0Y

    Joined:
    Feb 25, 2012
    Location:
    Sydney, Australia
    #8
    Rubbish.

    I'm sitting here connected to 3 remote VPNs. Only traffic destined for each target network uses its respective VPN and everything else goes unencrypted on my normal public interface.

    Internet access does not go over my VPNs nor does any LAN traffic.

    For me:
    anything on 10.0.0.0/8 goes over VPN1
    192.168.0.0/24 goes over VPN2
    192.168.1.0/24 goes over VPN3

    192.168.10.0/24 is my local LAN
    and all other traffic goes out of my internet connection

    You just need to know how to setup the routing properly.

    When a ppp connection is dialed (i.e. each time my Mac connects to a VPN), the file /etc/ppp/ip-up is run. Each time a VPN disconnects, the file /etc/ppp/ip-down is automatically run by ppp daemon.

    I differentiate each remote VPN using the VPN gateway IP. This IP is automatically passed to each of these script as the variable $5 and $1 is the interface name

    This is an example of a /etc/ppp/ip-up file

    In this example file, there are two VPNs configured. One has a gateway of 192.168.2.1 and the other has a gateway of 192.168.95.1.

    If the gateway IP of the VPN I am connecting to matches the "if" statement, then the route commands in that block are added.

    Here is an example /etc/ppp/ip-up file (used for deleting the VPN routes when you disconnect).

     

Share This Page