Problem is that you're going to have multiple gateways to your network connection, and that's a bit difficult to manage...
Some server or network related unix and linux tools usually have a flag called "interface", where you can tell which interface you wanna use, like in tcpdump, for example:
tcpdump -i eth0
But as I think you are asking about routing standard desktop software, that gets a bit more difficult...
I can tell you a trick for that anyway... My usual fix for dealing with that problems is using a proxy and only having one gateway. Almost any software that uses Internet this days has options for configuring a proxy, so you can do it on any of this ways:
1.- Setting up a proxy on the "unsecured" (an I mean, where the policies are not enforced) part of your network, and pointing your software to that proxy.
2.- Setting a SSH server on another "unsecured" place, say, your home, or a dedicated server you have on the internet, and opening a connection through a special feature that SSH has that creates a socks proxy server:
ssh -D 1234 user@host
That would create on your computer a socks proxy server on port "1234", that would connect to your "host", using your "user", and go to the Internet through the connection that your "host" has... Then, on your local software, you only need to open the proxy configuration tools, and point to localhost:1234.
Nice tricks for avoiding corporate internet policies :P
:D
2@gman: Nothing about this answer is specific to websites. – Lightness Races with Monica – 8 years ago
4The OP wants to choose network interface based on application program. This answer shows how to choose based on destination host. – Bennett McElwee – 7 years ago
I'm not going to downvote this (it is good advice for another question), but I'm certainly not going to upvote this either (for reasons stated by @gman and @bennett-mcelwee). – ratskin – 6 years ago
Per above, this does not answer the question of how to lock a specific app to a specific NIC. – catchdave – 5 years ago
19This isn't really an answer is it? The question is how to force an app not a website. For example what I wanted Safari to go over VPN(ppp0) but Firefox to go over en0 regardless of what site they are accessing? That's the question. – gman – 12 years ago