2018
03.29

ssh master just for the ports

Hey all

decided to write about something that i use way more often than i care about and have shown others on how to do.

sample from my ssh config:
Host foo
Hostname ADDRESS1
LocalForward 5432 ADDRESS2:5432
LocalForward 7777 ADDRESS3:8080
IdentityFile ~/.ssh/key.pem
User poa

now lets say i do not want to open an ssh shell but i do need those ports forwarded locally, then lets use some ssh master like such:
ssh -f -N -M -S /tmp/file-sock foo

this will forward the ports without needing to keep a terminal open.

to exit this:
ssh -S /tmp/file-sock -O exit foo

and done.

now lets say that you want to automate this into functions so that you can use this with multiple host names, then all you do is add these lines to either your .zshrc or .bashrc files:

function tunnel() { if [ -z $1 ] ; then echo "need hostname" ; else ssh -f -N -M -S /tmp/file-${1} ${1} ; fi }
function killtunnel() { if [ -z $1 ] ; then echo "need hostname" ; else ssh -S /tmp/file-${1} -O exit ${1} ; fi }

so now when you run tunnel foo it will start it up and create an appropriately named sock file. to kill it you just run killtunnel foo

voila.

2018
03.16

Hey all, sorry for the hiatus. work and life has been taking time but i am back and will have more updates soon.

Today’s weirdness comes in the form of a recruiter that to my knowledge is trying to position himself as the master of multiple domins…. or they were just blasting a list of email addresses.

Here is a shot of the subject lines (names blacked out for reasons):

Click to enlarge

both of these are from the same exact person, or at least the same automailer.

Here is the first email:

Click to enlarge

And here is email number two:

Click to enlarge

I feel that sometimes some recruiters are just trying to carpet bomb the landscape when their services are not needed.