![]() ![]() I am using this to create an SSH tunnel for Sophos Endpoint Security and Control to fetch its updates from a server that is only accessible from an internal network. Let me know if this saved your day and what you are using it for. Now go to the Saved Sessions list and enter your name, then hit the Save button. No window should come up but your ssh tunnel should be working. Step 1: Loading the Gateway If you haven’t done so, start by creating the SSH gateway server and save it on your system. Right click your task and select Runto see if it works as expected.You can adjust more settings like in the Conditionstab, unselect Start the task only if the computer is on AC power to make sure your tunnel also starts when your laptop is operating on battery, if necessary.Next to Add arguments, enter the name of your putty session (e.g.Use the Browsebutton to find plink.exe, which belongs to putty, you can download it here.You could add another trigger at startup or login if you need that. This will restart the SSH tunnel every 30 minutes, so you might be left without connection for at most 30 minutes. I chose Daily, recur every 1 days, Repeat task every 30 minutes for the duration of 1 day and stop all running tasks at the end of repetition interval. Select a trigger that suits your needs.For that see: How to create SSH tunnel using PuTTY in Windows And then you open a connection in another PuTTY instance to the forwarded port. The process will only have access to local resources. You open a connection in one PuTTY instance to the jump host and forward a local port to the protected host. Click the checkbox Do not store the password.Choose Run whether user is logged on or not (this is important to make sure the window does not pop up).Next run the following command to forward port 5000 on the remote machine to port 3000 on the local machine. sudo systemctl restart sshd OR sudo service sshd restart. In the tree on the left, select the folder Task Scheduler Library. Next, you need to restart sshd to apply the recent change you made.Press WINDOWS + R and enter Taskschd.msc to start the Windows Task Scheduler.If you worry about security, best restrict the rights of the user that you connect to as much as possible. Without a window there is no way to enter the passphrase of course -). Make sure to use keys for authentication and that the key does not require a passphrase. Set up your SSH tunnel in putty and save it as a session (e.g.Please let us know in the comments whether it works the same in your windows version. It requires admin rights and is tested on Windows 7 Professional only. You use Putty to tunnel some port through SSH to a foreign network but manually starting it again and again annoys you and the window gets in the way? Here is your solution. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |