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

unable to use port forwarding with softnet #278

Closed
remarkov opened this issue Oct 14, 2022 · 5 comments
Closed

unable to use port forwarding with softnet #278

remarkov opened this issue Oct 14, 2022 · 5 comments
Labels
bug Something isn't working enhancement New feature or request

Comments

@remarkov
Copy link

While attempting to switch to using softnet we noticed that it is not possible to use port forwarding to forward packets to a VM from the host like we normally do with a pf rule like

echo "rdr pass inet proto tcp from any to any port {some random port} -> {VM's IP address from `tart ip`} port 22" | sudo pfctl -ef -

That would allow us to use SSH on the VM by connecting to the host using that "random port" specified in the pf rule.
Unfortunately that does not work if VM is running with softnet, we're getting a connection timeout.

Any help or advice on this would be much appreciated!

@fkorotkov fkorotkov added bug Something isn't working enhancement New feature or request labels Oct 14, 2022
@edigaryev
Copy link
Collaborator

Softnet prevents communication with non-globally routable networks, is that your case?

@edigaryev edigaryev removed their assignment Oct 24, 2022
@remarkov
Copy link
Author

Yes, I think that is the root cause of the issue. Is there any workaround for that or does it require changes to softnet?

@abehn-lbi
Copy link

Would this be similar to, not being able to route network traffic down an established VPN connection on the MacOS Host?

@edigaryev
Copy link
Collaborator

Would this be similar to, not being able to route network traffic down an established VPN connection on the MacOS Host?

I think this is more similar to #473, shared networking (NAT) used in both Tart and the Softnet only supports VPN apps utilizing the Network Extension.

@fkorotkov
Copy link
Contributor

Orchard allows to port-forward and SSH to VMs created with Softnet:

orchard create vm --net-softnet --image ghcr.io/cirruslabs/macos-ventura-base:latest ventura-base
orchard ssh vm ventura-base

We don't see a compelling reason to bake similar functionality in Tart directly.

@fkorotkov fkorotkov closed this as not planned Won't fix, can't repro, duplicate, stale Jun 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants