If your computer’s firewall settings prevent you from using iTunes features such as music sharing, AirTunes, and Apple TV, you can change the settings to allow you to use these features.
Open System Preferences, click Security & Privacy, and click Firewall.
Click Firewall Options.
Do one of the following:
If “Block all incoming connections” is selected, deselect it.
If iTunes is included in the list of applications, choose “Allow incoming connections.”
Click OK.