{"id":131,"date":"2011-10-18T08:26:23","date_gmt":"2011-10-18T14:26:23","guid":{"rendered":"http:\/\/www.degen.net\/?p=131"},"modified":"2011-10-18T08:26:23","modified_gmt":"2011-10-18T14:26:23","slug":"text-is-best-and-other-remote-access-tricks","status":"publish","type":"post","link":"https:\/\/www.degen.net\/?p=131","title":{"rendered":"Text is Best and other Remote Access Tricks"},"content":{"rendered":"<p>No no, that&#8217;s not &#8220;txt&#8221; as in OMG &#8211; LOL &#8211; BFD txting; but rather my return to the romance of the CLI. Don&#8217;t get me wrong &#8211; I never stopped appreciating the unadulterated power of the command line, it&#8217;s just taken my need to leverage outbound SSH from multiple locked down networks to fully embrace the simple elegance of my home server ala putty.<\/p>\n<p><strong>Challenge &#8211; IMAP access from a restricted network<\/strong><\/p>\n<p>As I&#8217;m increasingly, &#8220;taking my show on the road&#8221;, I sometimes find myself in work enviormnets with limited, blocked or proxy access to the outside world (DAMN you PROXY!! &#8211; but that is a topic for another day.) Solution, get connected to my home server and connect to fire-walled resources from there. On a recent engagement I found that while most outbound traffic was allowed, IMAP was not. Web and SSH were being passed however; so in concept, the solution is basic enough &#8211; make an SSH connection to my home server, and run an IMAP client from there.<\/p>\n<p>Already having an Mint Linux server (loves me some Mint), setup primarily for file serving, I simply opened SSH port 22 to the outside world. After connecting via Putty I required a textual mail client that would support IMAP. I&#8217;ll be honest, it&#8217;s been years since I&#8217;ve used PINE, so I was a bit unaware of what other CLI email clients are out there &#8211; fortunately I discovered &#8220;MUTT&#8221; &#8211; http:\/\/mutt.sourceforge.net\/<\/p>\n<p>Mutt can be a bit intimidating. While easy to install, like most Debian packages (sudo apt-get install mutt), the &#8220;Devil in the details&#8221;, is the not included by default, .muttrc config file. Yes you can read the project wiki or grab a sample one from others, but I found a web based automated builder tool &#8211; http:\/\/www.muttrcbuilder.org\/ &#8211; it does the trick quite nicely, just add your custom elements and bingo. Within a few minutes I was able to check and clear mail with no client side setup other then establishing an SSH session &#8211; pretty slick!<\/p>\n<p><strong>Challenge &#8211; Secure VNC access of the Internet<\/strong><\/p>\n<p>So let&#8217;s say you only have that same SSH connection, but you need more visual goodness then a CLI email client can provide? Sounds like a you want a VNC connection &#8211; but how unsafe would that be to run over the Internet? Enter VNC (Port 5900) Tunneling via Putty.<\/p>\n<p>First, launch Putty and enter the address you would like to connect to via SSH. Before establishing a session, look on the left hand side, you will see various configuration options. Expand the categories -&gt; Connection -&gt; SSH -&gt; Tunnels. Select Tunnels add the following information under add new forwarded port:<\/p>\n<p>Source Port 5900<br \/>\nDestination Port 127.0.0.1:5900<\/p>\n<p>Now establish your SSH connection (Login), once connected open your VNC client and point the host back at your local machine &#8211; 127.0.0.1 and Bonus you&#8217;re all set.<\/p>\n<p>So regardless your UI preference there&#8217;s an SSH solution out there for you &#8211; Enjoy!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>No no, that&#8217;s not &#8220;txt&#8221; as in OMG &#8211; LOL &#8211; BFD txting; but rather my return to the romance of the CLI. Don&#8217;t get me wrong &#8211; I never stopped appreciating the unadulterated power of the command line, it&#8217;s just taken my need to leverage outbound SSH from multiple locked down networks to fully [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[9,12],"tags":[29,30,28,26,27,31],"class_list":["post-131","post","type-post","status-publish","format-standard","hentry","category-linuxunix","category-windows","tag-email","tag-imap","tag-linux-remote","tag-putty","tag-ssh","tag-vnc"],"_links":{"self":[{"href":"https:\/\/www.degen.net\/index.php?rest_route=\/wp\/v2\/posts\/131","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.degen.net\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.degen.net\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.degen.net\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.degen.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=131"}],"version-history":[{"count":14,"href":"https:\/\/www.degen.net\/index.php?rest_route=\/wp\/v2\/posts\/131\/revisions"}],"predecessor-version":[{"id":145,"href":"https:\/\/www.degen.net\/index.php?rest_route=\/wp\/v2\/posts\/131\/revisions\/145"}],"wp:attachment":[{"href":"https:\/\/www.degen.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=131"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.degen.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=131"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.degen.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=131"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}