views:

266

answers:

3

Hello All,

I have a client - server application, where I want to add a exception to firewall so that my applications can communicate properly. I want to add add an exception to the firewall (without changing the setup for the other firewalls options).

I am using Carbon, Qt, C++. However, I feel this has more to do with some install time settings.

Any suggestions are highly appreciated. Thanks, Rahul

A: 

in my opinion, if you`re opening a socket, your Mac-firewall will automatic give you the chance to allow or deny the connection.... did you try it?

hase
Sorry, I think missed a detail there, that it should not be user interactive. This all should happen in background.
Rahul
I tried what you suggested. I want set firewall to always allow incoming connections
Rahul
A: 

I'm not sure this is would be good practice without notifying the user or asking the user for permission. Since osx has a built in system for creating application signing and the user must explicitly enable this level of security.

That being said, you should have a look at

/usr/libexec/ApplicationFirewall/socketfilterfw

and

/usr/libexec/ApplicationFirewall/com.apple.alf.plist

OS X also use ipfw and I'm pretty sure it supersedes any rules set by the application filter. So you could make an ipfw rule as well.

jkyle
A: 

I prefer protect my mac and for it i use ProteMac Netmine .It's firewall which controls all the network.In

Julia