-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
option to make Sandstorm accessible through Tor with a .onion address #14
Comments
sandstorm-io/sandstorm#447 is the ticket in
question.
|
Issue referenced in the above PR that describes a few current problems with a Sandstorm Tor Hidden service: sandstorm-io/sandstorm#434 Note that there is still some benefit to setting up a hidden service endpoint even if we're not hiding the ip address and location of our server. It would give people a (better) alternative to TLS for transport security (or even a layer on top of it), as well as a .onion address that cannot be censored. So it might be worth implementing a hidden service endpoint even with the current leaking of IP addresses. |
If you're interested in hidden services, there are two different Sandstorm
My suggestion would be that static publishing be what you start with. Given
The last of these seems IMHO the coolest. You can get working on it right I can say more about that if you're interested! For what it's worth, the
I imagine that Kenton and/or other core team members will have opinions Some further info can be found in the docs: But maybe that explains what next steps y'all can do without waiting on us! |
Hey thanks for thinking about this! A Tor driver for Sandstorm sounds really cool. This could definitely be something we look into. Another thing to think about is using a tor hidden service as a gateway to the sandstorm shell itself (and apps running within it). This is useful because it gives us an alternative to TLS and PKI. This would allow users to create, modify, share (and maybe publish?) grains belonging to any application. Presumably these two models could coexist. |
So I'm thinking the best place to start is a hidden service gateway to sandstorm -- it is something we know we will want eventually regardless, and it doesn't look like too much work is needed to support it. Seems like the multiple BASE_URL/WILDCARD_HOST support is the only thing we need. How would you feel about us putting together a PR for this? Outstanding things that I can think of are:
|
Howdy @jacksingleton ! re: two different BASE_URL/WILDCARD_HOST values I thought this would be super-tough, since Meteor probably wants just one BASE_URL. But then I saw this: iron-meteor/iron-router#1110 which is about Telescope fighting Meteor's BASE_URL support and winning. For you, I think that you should do something in Then I figure if a request comes in via the Tor hidden service, it'll use the hidden service BASE_URL & WILDCARD_HOST. Related thoughts here:
re: decide what BASE_URL to use for any given request:
re: syntax for config file:
BTW @jacksingleton the BASE_URL parsing occurs in C++-land (look for NOTE: FWIW, the above design implies that there should still be one default _Other notes_ You'll probably need to sanity-check the static publishing code to make sure that, if you make a request via the hidden service, the auto-generated static publishing subdomain that you get is on the hidden service too. |
Oh interesting. I think it’s generally ill advised to run a hidden service that you want to remain anonymous while running the same server on the open web because it’s fairly easy for an attacker to corrolate changes, downtime, performance issues, etc (that can even be triggered by the attacker). But that doesn’t mean nobody will want to do it :) And checking for a response from a host header is definitely a lot easier that the correlation attacks. Another strategy that crossed my mind was to have the shell look for a
Sounds good!
|
Sure. I'm also OK with the other things you suggested. :P |
: D
The others seemed less invasive to me!
|
There are some things that can be done independently of the sandstorm code.
I would propose that all three of these features default to |
Cameron, +1 to your thoughtfulness on this.
|
In
I may be missing a word. Via what? |
Tor can accept UDP DNS queries on localhost using the But there's a caveat (which is why it's important to provide a toggle), this feature can only resolve A records. Other record types (MX, TXT, AAAA) will be returned as either "NOERROR, Answer: 0" or "NXDOMAIN". |
I think the what is Tor. Tor can expose a dns resolver locally which will route all queries through the Tor network. It would be awesome to do transparent proxying with iptables + privoxy + tor. We can also look at Whonix: https://www.whonix.org/wiki/Hidden_Services I do want to separate two motivations for running a hidden service:
The benefits of 1 are that we provide an alternative (and possibly layer on top of) to TLS/PKI. It makes our service more censorship resilient and harder to man in the middle. Benefits of 2 include all the benefits of 1 and also make it really difficult to identify where the Sandstorm server is being hosted. The downside is that if this is what you want, you really shouldn't provide any access to that Sandstorm NOT over Tor otherwise you open yourself up to correlation attacks. |
Semi-sorry about how long this is getting. @jacksingleton and I talked more today. Here are the minutes from that conversation: You'll end up with a
This will flow into Sandstorm as the following environment variables, thanks to
NOTE that this will result in Meteor crashing -- Meteor will hate
So then @jacksingleton can expect that Meteor will receive
Other:
The goal here is to check which BASE_URL is being used for this request, and consistently use that (and its corresponding WILDCARD_HOST) in responding to this request. Going to save this now, then edit to make further changes. |
Hi all, I agree that having multiple What else needs to happen to make it possible to just host a Tor hidden service using Sandstorm? Packaging Tor as an SPK, and sandstorm-io/sandstorm#447 ? Thanks! |
If you want to have a Sandstorm install that is 100% behind Tor, here is what I would do:
Then there are two ways forward to limit DNS leakage. Way 1: Fix Sandstorm issues where the code does DNS lookupsSpecifically sandstorm-io/sandstorm#447 Way 2: Constrain Sandstorm so it can't reach the Internet except via a tor-ification proxyAlternatively, you can limit the Linux VM so that Sandstorm can't communicate with the world, e.g.
Let me know if that's responsive to your question, @elimisteve . |
look into: https://github.com/alecmuffett/eotk |
According to @paulproteus we can work on a patch for Sandstorm to prevent sandstorm from leaking its IP address. we should look at that
The text was updated successfully, but these errors were encountered: