Posts

Showing posts with the label Networking

A re-introduction to Cisco Zone Based Firewalls

Image
After a few years without having to think about it, I decided to dip my toe back into the murky waters of Zone Based Firewalls recently. Luckily, I'd written enough notes and comments in my previous configs that only a small amount of searching and reading was needed before I got back up to speed. In that vein, here's a very basic starter ZBF config (for when I forget again in six months *derp*)... Create an ACL to hold any firewall exceptions: ip access-list extended aclFirewallExceptions  permit tcp any any eq 56881  permit tcp any any eq 10022 Then, add the ACL to a Class Map: class-map type inspect match-any cmFirewallExceptions  match access-group name aclFirewallExceptions After that, the Class Map is added to a Policy Map: policy-map type inspect pmWanToLan  class type inspect cmFirewallExceptions   inspect  class class-default   drop The policy map is then applied to the relevant Zone Pair: zone-pair security zpWanToLan source WAN de...

Trying out auto-mounting network shares with AppleScript

I wanted a neater way of auto-mounting network shares on startup than simply sticking the path in Login items so I thought I'd search around and see what methods were available. I finally settled on using a bit of AppleScript to first check if the mount point exists and, if not, to attempt to mount the network share. 1 2 3 4 5 6 7 8 9 tell application "Finder" if not (exists POSIX file "/Volumes/Data" ) then try mount volume "afp://some-server.local/Data" end try else display dialog "Already Mounted" end if end tell Given that I wanted to mount multiple shares, putting the above in a function seemed like the way to go. Unfortunately, no matter what I tried, passing the path to Finder as a variable caused the test to always fail - even though though the path could be displayed via dialog as well as appearing in the AppleScript Editor's Events box. After finally giving up on that, I switched ...