From time to time, I'll be on my Macbook using a program that accesses the network – whether Firefox, or Sony's Reader Library – really, it seems like it could happen with any program that accesses the network – and for no reason that I can discern so far (that is, it happens intermittently) the OS X firewall dialog pops up to ask me the question:

[OS X firewall dialog] Do you want the application "Reader Library.app"
to accept incoming network
connections? Clicking Deny may limit
the application's behavior. This
setting can be changed in the Firewall
pane of Security preferences. [Deny] [Allow]

Except it doesn't actually let me click anything before it disappears! That is:

the dialog pops up, ...

then goes away by itself a second later,

then pops up again, ...

then goes away by itself a second later,

etc.

It happens a few times before stopping. It wouldn't be so maddening to be interrupted if I could just be allowed to click "Allow" and make the darn thing go away for good.

In Security preferences I have the firewall turned "On", and I would like to keep it that way.

Has anybody seen this problem, found the source, and figured out a solution or workaround?

@NSD: I have a few $40 routers already :-) The idea with an application firewall is to prevent applications from going out without my permission. My $40 external router necessarily can't do that.
–
Chris W. ReaMar 27 '10 at 15:53

2

@Hasaan, too many consumer routers nowadays support UPnP by default, and won't tell you when an application uses that to open a port. Keep that firewall running. @Chris, the built-in firewall will only block INCOMING connections; LittleSnitch also monitors outgoing connections, if that's what you want.
–
ArjanApr 28 '10 at 21:16

1

I never saw this on my 2.33 Core 2 Duo machine. I bought the new "early 2011" MBP, transferred all my data from the old machine, and now I'm seeing this problem for the first time ever. It's really aggravating! I don't believe it's just an SMB problem, since obviously, I'm using the same network environment I was before, just a new machine (and a special 10.6.6 build for the new laptop).
–
khedronMar 28 '11 at 4:54

Several people have hit around the solution, but haven't stated it clearly, so here it is:

Every app in OS X should be signed by the developer. This signature ensures that the contents of the application haven't been changed. The firewall verifies this signature as part of its process. When the signature verification process fails, you will receive this Allow/Deny error message every time you use the program, even if you click Allow on the dialog box.

Why is the signature verification failing? This can happen for several reasons, but primarily it is because somewhere along the line you've changed the contents of the /Applications/YourProblemApplication.app container. For example, if you use Monolingual or a similar app to remove other language files to save disk space, you've modified the contents of the app. If you've used a program like CandyBar or IconDubber to change the icon (.icns) file, you've also changed the contents of the app.

The easiest way to fix this problem is to delete the .app that is generating this error (be sure to empty the recycle bin). Reinstall the .app and this time, don't modify the contents.

BTW, the whole signature process can lead to plenty of errors in other applications, especially security conscious apps like VPNs. For example, my Cisco Unified Personal Communicator stopped working after running Monolingual (but would only generate deny errors in the Console log).

+1 Thanks, this was the cause of the issue in my case for Adobe Flash Builder -- there is a file named application.xml deep within the bundle that is apparently used to store the license key. Needless to say, it changes when one enters the license key to register the app. In my case, the issue was resolved by re-signing the application after entering the license key using a self-signed certificate.
–
TamásSep 28 '12 at 8:31

Deleting the app and reinstalling fixed it for me (app was PHPStorm).
–
JustinNov 18 '14 at 19:15

Symptoms
According to the Apple Support Forums link posted earlier, the popup appears only for certain apps. Adding a permanent exception did not fix the issue for the poster there. Asker reports the popup appearing for all apps, although intermittent.

Diagnosis
It seems that the firewall is not correctly recognizing the applications and/or acting incorrectly upon their detection. This belief is reinforced by the notion that for some people not all apps are causing this.

Testing
To determine what in the firewall is b0rked, we could test several scenarios:

A completely clean computer with only some basic apps installed. This will guarantee that the system-wide config as well as the user-configs would be clean.

A new user. If the affected people could create a new account and the firewall doesn't b0rk under that account, the user's config is invalid and would need to be rebuild (i.e. cp'ed from the new user).

If we do this option, we can also diff the config files and check for anomalies.

Disable the firewall. This will probably fix the symptoms. If it doesn't, we're screwed. Disabling and enabling might also fix it, but we would need to test if that is the case. I cannot figure why that would work, though.

Extra info
Some people are suggesting to turn off their firewall, but no-one who reported the problems seems to have done so (or they haven't reported back) so we don't know if this fixes it.

Thanks. Can you please clarify if your workaround is a speculative suggestion, or have you yourself worked around this same problem using the method you described? If so, how long does the "fix" stick before things get wonky again?
–
Chris W. ReaMar 26 '10 at 13:06

It is speculative, I'm afraid to say. However, I have reformatted my answer to be more specific and to list all options I could find. It would be great if you could test the second and last solution. If those work, we could post back at Apple Support with a solution.
–
ZsubMar 26 '10 at 13:55

2

Turning off the firewall wouldn't be a fix. My desired end-goal is to have the firewall work properly, prompting me only when it is a new application I haven't authorized yet, and otherwise staying out of my way ;-)
–
Chris W. ReaMar 27 '10 at 16:02

Yes, but as stated, we can only test this by temporarily turning off the firewall, rebooting, and re-enabling. If the problems are gone, we have something that is at least a temporary fix.
–
ZsubMar 27 '10 at 16:47

I will try it and report back. I will give it a while though to see if it recurs.
–
Chris W. ReaMar 28 '10 at 17:42

This is too partial to be an answer, but I can't comment under superuser's baroque reputation rules. Nonetheless, it is a helpful contribution, IMO.

The problem of the firewall dialog box flashing up for me occurs very reproducibly - it occurs in the open/save dialog of every applications when I am at work.

At my office there is a mixed network of windows machines, of macs and of ubuntu/linux fileservers. In my studio, by contrast, there are only macs. The problem never occurs at the studio.

Furthermore I can make the problem go away at work - If i log in to the linux machine and turn off the SMB fileshare daemon (i.e. running /etc/init.d/smbd stop) then the problem also goes away.

So the problem or me at least is to do with applications using the open/save dialog box with a SAMBA share on the network.

The linux server is running version 3.5.4 of the SAMBA suite; I'd be interested to hear if the same problem can be caused by shares from windows machines, or different versions of samba - or possibly different fileshare configurations in the one version of samba.

As far as turning off the firewall goes - yes, this does work around the problem. However, I am frequently using unknown wireless cafes and do not regard turning off the firewall as an option. Interestingly, though, turning the firewall off then on again causes the problem to stop temporarily. Once I have restarted the firewall the problem does not recur again for the next few save dialogs at least. I don't know how long that effect lasts - I wasn't trying to be rigorous last time I tried - but I have just restarted it again and will report back.

i think it happens when you change the application. for example, go into the itunes app package and change the app's icon. then it sees that the app is altered and ALWAYS pops up the message, even if you click allow. annoying.

Though your post itself is not an answer (but you don't have enough reputation to comment yet), it might be interesting to see if that's true in all case. If it's true, then it's related to code signing. So, please see the notes about codesign --verify -vv in If Mac code signing is tampered with, what might fail?, and let us know if that fails for your iTunes?
–
ArjanNov 14 '10 at 7:39

I've found that if I go into an app and bring up an open or save dialog, I can wait until the "Do you want to ..." window pops up and immediately press the esc key. After I've done that, the problem no longer occurs in that app, even after I quit and restart it.