Does sshuttle work with OS X 10.8 Mountain Lion?

1,582 views
Skip to first unread message

John Hitchings

unread,
Jul 25, 2012, 1:09:21 PM7/25/12
to sshu...@googlegroups.com
There were issues with sshuttle for the upgrade to 10.7. Before I upgrade to Mountain Lion, has anyone had success running sshuttle on the newest version of the os?

Thanks!

John

Avery Pennarun

unread,
Jul 25, 2012, 2:44:03 PM7/25/12
to John Hitchings, sshu...@googlegroups.com
I haven't heard of anyone testing it yet. That means it probably
doesn't work. :)

Have fun,

Avery

John Hitchings

unread,
Jul 26, 2012, 12:20:39 AM7/26/12
to sshu...@googlegroups.com, John Hitchings
I was successful running sshuttle on 10.8 (with sshuttle already working with scopedroute in 10.7), for what it's worth.

Luis Gonzalez Sandoval

unread,
Jul 26, 2012, 11:55:06 AM7/26/12
to John Hitchings, sshu...@googlegroups.com
Yes, works for me!

Luis

Anand Buddhdev

unread,
Jul 26, 2012, 2:09:36 PM7/26/12
to Luis Gonzalez Sandoval, John Hitchings, sshu...@googlegroups.com
Well, it works on Mountain Lion, but both my colleague and I had kernel panics this afternoon; both panics were caused by, or at least related to ipfw.

Avery Pennarun

unread,
Jul 26, 2012, 2:19:34 PM7/26/12
to John Hitchings, sshu...@googlegroups.com
On Thu, Jul 26, 2012 at 12:20 AM, John Hitchings <hit...@gmail.com> wrote:
> I was successful running sshuttle on 10.8 (with sshuttle already working
> with scopedroute in 10.7), for what it's worth.

Could you clarify what you mean by "alreasdy working with scopedroute in 10.7"?

Also, for the people getting ipfw panics, are you running Safari by any chance?

Thanks,

Avery

John Hitchings

unread,
Jul 26, 2012, 2:25:15 PM7/26/12
to sshu...@googlegroups.com, John Hitchings
> Could you clarify what you mean by "alreasdy working with scopedroute in 10.7"? 

Sorry, I meant that in 10.7, I had to set net.inet.ip.scopedroute=0 to get sshuttle working, but in the setting was preserved upgrading to 10.8 and I didn't need to do anything special to get it working.

$ sysctl -a | grep bootargs
kern.bootargs: net.inet.ip.scopedroute=0

John

Anand Buddhdev

unread,
Jul 27, 2012, 5:36:10 AM7/27/12
to Avery Pennarun, sshu...@googlegroups.com
Hey Avery,

I'm NOT running Safari. The only browser I run is Chrome.

Anand 

Jari Fredriksson

unread,
Sep 30, 2012, 4:15:45 PM9/30/12
to sshu...@googlegroups.com, Avery Pennarun
Sshuttle does not seem to work. Worked fine in MacBook Air original running Lion. Now a new Air with Mountain Lion preinstalled, no joy.

net.inet.ip.scopedroute seems to be 0. No errors visible, -vv or not.

--jarif

Jari Fredriksson

unread,
Sep 30, 2012, 4:17:30 PM9/30/12
to sshu...@googlegroups.com, Avery Pennarun

Addition: so no errors. sshuttle launches and ssh says "Connected". Then, nothing happens. If I run with -vv, it shows no activity when I try to connect to remote hosts.

--jarif

csa...@gmail.com

unread,
Oct 3, 2012, 12:42:08 PM10/3/12
to sshu...@googlegroups.com, Avery Pennarun
I just installed sshuttle for the first time today (cloned from github/master) and I had a couple of kernel panics too. Here are the crash reports in case that helps any:

http://pastie.org/private/brbjrxwh7leo0ceqtfusw
http://pastie.org/private/84a2c5lqxgi5f7anxiniw

Before the first one I also had OpenGarden running so I quit that after rebooting and it crashed again anyway. Before the crash, everything seems to work ok as far as the tunnel is concerned. Didn't see anything of use in the system logs either.
Message has been deleted

phl...@gmail.com

unread,
Oct 24, 2012, 10:25:57 PM10/24/12
to sshu...@googlegroups.com, Avery Pennarun
I'm having the same issue. Everything seems to work fine. net.inet.ip.scopedroute is 0. But nothing is going through the tunnel.

Avery Pennarun

unread,
Oct 25, 2012, 1:54:44 PM10/25/12
to phl...@gmail.com, sshu...@googlegroups.com
On Wed, Oct 24, 2012 at 10:25 PM, <phl...@gmail.com> wrote:
> I'm having the same issue. Everything seems to work fine.
> net.inet.ip.scopedroute is 0. But nothing is going through the tunnel.

Hmmmm. I definitely have a Mountain Lion laptop and sshuttle
definitely works on it. But that laptop happens to have a bunch of
employer-specific hackery on it, so it's not exactly in mint
condition. (My personal laptop is still on Lion.)

Does anyone else have an experience where Mountain Lion *is* working for them?

Avery

Luis Gonzalez Sandoval

unread,
Oct 25, 2012, 2:58:47 PM10/25/12
to Avery Pennarun, phl...@gmail.com, sshu...@googlegroups.com
Hello,

My Macbook Pro are running Mountain Lion 10.8.2 and I use sshuttle every day all day long.
Works for me!

Luis-Gonzalezs-MacBook-Pro:sshuttle lgonzalezsa$ git status
# On branch macos_10_7_only_hack
nothing to commit (working directory clean)
Luis-Gonzalezs-MacBook-Pro:sshuttle lgonzalezsa$ git log
commit 0b2443d85e8d58bd7716e35114d98ccad94a59c7
Author: Ian Wolfcat Atha <i...@atha.io>
Date: Mon Aug 1 17:20:41 2011 -0700

phl...@gmail.com

unread,
Oct 27, 2012, 6:22:32 PM10/27/12
to sshu...@googlegroups.com, Avery Pennarun, phl...@gmail.com
I am running Mountain Lion 10.8.2. It is pretty stock, I have not had the computer for very long.

I have tried using whatever comes with homebrew. I have also tried the apenwarr/sshuttle git repo and thatha/sshuttle git repo.

I have been able to run the client successfully from my desktop and it works great! So it seems I am using it correctly :/

On the macbook it appears to connect properly, I just see no traffic in the terminal when when browsing websites and http://ifconfig.me/ shows the IP for my home network. I get the same behavior when I use the gui app.

Here is the output:

riddler:sshuttle.appenwarr phliver$ ./sshuttle --dns -vr phliver@thehostiuse 0/0
Starting sshuttle proxy.
Listening on ('127.0.0.1', 12300).
DNS listening on ('127.0.0.1', 12300).
firewall manager ready.
c : connecting to server...
 s: latency control setting = True
 s: available routes:
c : connected.
Connected.
firewall manager: starting transproxy.
>> ipfw -q add 12300 check-state ip from any to any
>> ipfw -q add 12300 skipto 12301 tcp from any to 127.0.0.0/8
>> ipfw -q add 12300 fwd 127.0.0.1,12300 tcp from any to 0.0.0.0/0 not ipttl 42 keep-state setup
>> ipfw -q add 12300 divert 12300 udp from any to 192.168.0.1/32 53 not ipttl 42
>> ipfw -q add 12300 divert 12300 udp from any 12300 to any not ipttl 42

Is there any other information I could provide that would help?

mic...@infamia.com

unread,
Nov 1, 2012, 11:11:00 PM11/1/12
to sshu...@googlegroups.com, phl...@gmail.com
WOrks for me, but I haven't tried the -dns option. Your output looks similar to mine. have you tried :

- a known-good remote host?
- specifying a more narrow network range (e.g. 27.120.101.0/24 to check on ifconfig.me )
- I'm assuming you already rebooted your mac :)

Y

phl...@gmail.com

unread,
Nov 2, 2012, 1:23:57 AM11/2/12
to sshu...@googlegroups.com, phl...@gmail.com, mic...@infamia.com
I ended up getting this working. It turns out I had my firewall turned on in preferences.

iirc the firewall is turned off by default on macs.

If I go to system preferences, and then security and privacy, make sure my firewall is turned off then sshuttle works perfectly.

I'm actually a little surprised this is not a more common problem. Do people really run around with their firewalls turned off?

At any rate, as long as everybody else experiences the same behavior, could we get this put in the documentation? Maybe we can prevent this issue for other users in the future.

Jari Fredriksson

unread,
Nov 2, 2012, 5:25:25 AM11/2/12
to sshu...@googlegroups.com
I hope this can be taken care by sshuttle package, it is possibly
anything too compilacated. I too had firewall on, but as I disabled it,
sshuttle started working!

Thanks for this.

--
Jari Fredriksson
Digital Identity Solutions Europe Oy
tel. +358 400 779440
jari.fre...@digital-identity.com

mcma...@gmail.com

unread,
Nov 26, 2012, 3:23:52 AM11/26/12
to sshu...@googlegroups.com
10.8.2.  Works most of the time - but with occasional, terrifying kernel panics.

sandul...@gmail.com

unread,
Apr 20, 2013, 12:10:56 PM4/20/13
to sshu...@googlegroups.com, phl...@gmail.com, mic...@infamia.com
After some tinkering on my 10.8.3, I discovered It's not just the firewall that's causing the trouble. It's PF itself. While PF is enabled, ipfw forwarding rules (which is what sshuttle sets up) silently stop working, so as a result, sshuttle claims it's working perfectly, but nothing will be redirected through.
The firewall uses PF internally, setting up rules at the `com.apple/250.ApplicationFirewall/*` anchor, but it's not the only one. Internet Sharing, as well as AirDrop, use (and enable) PF as well, so bear in mind that using any of those will prevent forwarding from working while they are running.

I think this would definitely be worth putting in the Known Bugs section, but ultimately the application should be made to generate PF redirect rules instead. However, I haven't had success yet in getting those to work.

PS: yes I do get kernel panics too (10.8.3 on 2011 MBA), for what it's worth. Probably about once a day so far. I guess I'll try to get PF to do the forwarding instead.

mma...@gmail.com

unread,
Aug 14, 2013, 11:53:43 PM8/14/13
to sshu...@googlegroups.com, phl...@gmail.com, mic...@infamia.com, sandul...@gmail.com
Does Apple have a we to create a bug report for this issue?

cas...@gmail.com

unread,
Sep 16, 2013, 5:02:00 PM9/16/13
to sshu...@googlegroups.com, phl...@gmail.com, mic...@infamia.com, sandul...@gmail.com
Any progress on this? Sshuttle is a great tool, but the kernel panics are getting annoying.

matt....@gmail.com

unread,
Oct 25, 2013, 8:37:42 PM10/25/13
to sshu...@googlegroups.com, phl...@gmail.com, mic...@infamia.com, sandul...@gmail.com, cas...@gmail.com
I'm also getting kernel panics all the time and hope it can be fixed. But I have no idea how to debug it myself...

Dan Sanduleac

unread,
Oct 28, 2013, 8:15:26 AM10/28/13
to matt....@gmail.com, cas...@gmail.com, phl...@gmail.com, mic...@infamia.com, sshu...@googlegroups.com
Sorry, I haven't had a lot of time lately to further debug this so I left it at that (not at university either anymore so no more pressing need for using sshuttle).
 
The solution seems to be to update and recompile the kernel itself to either:
* implement the PF divert rule (as on other BSD kernels), or
* fix ipfw code (it does provide a kernel stack trace when it crashes, so one could start from there) -- but the problem of its functionality when PF is also turned on remains. 

Of course, neither of these are particularly easy to do, and would require recompiling the kernel on each new system update. However I haven't found a way of making this work with the tools as they are right now. 

mma...@gmail.com

unread,
Dec 6, 2013, 10:04:53 AM12/6/13
to sshu...@googlegroups.com, matt....@gmail.com, cas...@gmail.com, phl...@gmail.com, mic...@infamia.com, sandul...@gmail.com
I'm having grey screen of death crashes under 10.9 too.
Reply all
Reply to author
Forward
0 new messages