Skip to content
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

main focus of project? #35

Open
adrelanos opened this issue Aug 27, 2018 · 6 comments
Open

main focus of project? #35

adrelanos opened this issue Aug 27, 2018 · 6 comments

Comments

@adrelanos
Copy link
Collaborator

I am wondering what is the main focus of your project?

a) Adding torification to applications which don't come with native torification or
b) better guaranteed torification (absence of leaks going through clearnet) by launching applications isolated in Linux network namespaces?

@lesion
Copy link
Collaborator

lesion commented Aug 28, 2018

isolation is why orjail is born in the first place.
I found many ways a software could leak data while using tor with torify, so I decided to create a jail to handle this issue, and here we are 😃

(quoting README.md :

if you find a way to deanonimize a program running inside orjail (also a shell with root privileges) would be nice to share it with us).

a long-term project would be to rewrite it in C, it will make it a bit more serious.

@adrelanos
Copy link
Collaborator Author

Sounds great!


Which advantages a rewrite in C bring? Could you interface with linux namespaces natively, without calling external binaries such as ip and iptables? Which would then result in a speedup? On the other hand the current bash implementation is small, simple, beautiful and unlikely to introduce exploitable vulnerabilities. Might a C implementation be actually more vulnerable? Even for a python rewrite I see no incentive.

@gibix gibix mentioned this issue Aug 28, 2018
5 tasks
@lesion
Copy link
Collaborator

lesion commented Aug 30, 2018

Which advantages a rewrite in C bring?
I think the surface attack is smaller (imho):

  • let's say an attacker could change your environment before running orjail: using bash it takes total control (e.g. could change $PATH order and create an iptables wrapper, in C you would use libiptc)
  • we're currently using two different wrapper to run your final command: ip netns exec to join the network namespace, and unshare to split ipc/process/mount namespaces. in C would be cleaner.
  • also the usage of sudo to drop privileges as we're doing now is not so good, in C would be way better

@adrelanos
Copy link
Collaborator Author

adrelanos commented Aug 31, 2018 via email

@travankor
Copy link

Why not rewrite in Go? Or Rust?

@bakulf
Copy link
Collaborator

bakulf commented Feb 26, 2020

Rust +1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants