for blocking outgoing connection using the firewall then follow some simple step..
Use these steps to enable the application firewall:
Choose System Preferences from the Apple menu.
Click Security or Security & Privacy.
Click the Firewall tab.
Unlock the pane by clicking the lock in the lower-left corner and enter the administrator username and password.
Click "Turn On Firewall" or "Start" to enable the firewall.
Click Advanced to customize the firewall configuration.