I have Machine A, which has internet access and has Tor running on port 9150. I have Machine B, which can't access the internet but can access Machine A via SSH. I want to run a command on Machine B (no internet machine); this command on Machine B accesses the internet. I want this command to go through Machine A port 9150. I don't have sudo access on Machine B, but I have sudo access on machine A.
How do I go about setting this up?