Add Packet level firewall programmatically in Mac
I want to Add Firewall rule in Mac, OSX, how can i do that programmatically, 
basically as long as application is running these firewall rules should be active, else, it should be deactivated,  
Add Packet level firewall programmatically in Mac
===

I want to Add Firewall rule in Mac, OSX, how can i do that programmatically, 
basically as long as application is running these firewall rules should be active, else, it should be deactivated,  