Skip to content

Instantly share code, notes, and snippets.

@alloydwhitlock
Created September 7, 2017 03:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alloydwhitlock/1e4779b7966d252573e1e2b95fe62ef9 to your computer and use it in GitHub Desktop.
Save alloydwhitlock/1e4779b7966d252573e1e2b95fe62ef9 to your computer and use it in GitHub Desktop.
#!/bin/bash
#
# Clear SSH control master sockets if using Cisco AnyConnect on Mac OS X
$(command -v ifconfig) | $(command -v grep) 'tun3' > /dev/null 2>&1
[[ $? -eq 0 ]] && rm -f ~/.ssh/master-alloydwhitlock@* && echo "Cleared SSH control masters from prior connections..."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment