Closed Bug 464575 Opened 11 years ago Closed 11 years ago
Don't set quarantine attributes on files that the OS hasn't quarantined
User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en-US; rv:126.96.36.199) Gecko/20080512 Netscape/9.0 Build Identifier: Camino Version 1.6.4 (188.8.131.52 2008091513) Since Camino has been opted in to Apple's quarantine system, and Apple has declined to document the mechanism whereby Safari allows you to selectively opt files out of it, I would like to request a flag (at least in about:config/user.js) to perform the same action, at least on a global basis. See Bug 464333 for more details. Reproducible: Always Steps to Reproduce: 1.Download a file. 2.Open it. Actual Results: Get a warning dialog letting you know that you downloaded the file. Expected Results: Only get warning dialogs when performing unusual or exceptional actions. I understand that Apple has implemented this as a security feature. I don't want to get into a debate about the desirability or otherwise of this feature.
We're not going make a pref for this. There are already ways for the very small percentage of users who care to strip the attribute from files. And as I said in bug 464333, having every single app manually create a system for allowing users to opt out is a poor solution. If you want a way to turn off quarantining, file a request with Apple for a pref to disable quarantine entirely.
Status: UNCONFIRMED → RESOLVED
Closed: 11 years ago
Resolution: --- → WONTFIX
After further examination, I believe that you're mistaken about Apple specifically opting in Camino. If you look at the source code to the submitted patch in Bug 407215, it is Camino that is quarantining the file, in "nsDownloadListener::QuarantineDownload()", in the lines + lsSetItemAttributeFunc(&tempFSRef, kLSRolesAll, lsItemQuarantineProperties, + quarantineProperties); after setting up quarantineProperties. If you look in System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/Resources/Exceptions.plist you will see that Camino is not listed in there. Apple isn't doing this. Camino is. I am not asking for Camino to specifically opt out of quarantine. I am asking that Camino not specifically opt in.
(In reply to comment #2) > After further examination, I believe that you're mistaken about Apple > specifically opting in Camino. I guess I must have imagined the meeting we had with an Apple engineer at WWDC where he told Mike Pinkerton and I that Camino would automatically be included in the quarantine system and asked us to set extra attributes on downloads (which is what bug 407215 does) to improve the dialog that would pop up. And the dialogs that showed for Camino 0.8 downloads in Leopard before we ever did anything related to quarantine. > If you look in > System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/Resources/Exceptions.plist > you will see that Camino is not listed in there. org.mozilla.navigator is the bundle ID for earlier versions of Camino, and is listed there. There is no reason to expect that if we stopped supporting quarantine they would not add the current bundle ID. > I am not asking for Camino to specifically opt out of quarantine. I am asking > that Camino not specifically opt in. The distinction is irrelevant; either way, you want a pref for Camino not to do quarantining. The WONTFIX applies however you phrase it. We aren't going to participate in a one-app-at-a-time war against the quarantine feature. Once again: if you want a way to opt out of quarantining, file a bug with Apple.
Since some of my comments here and in bug 464333 about our implementation are confusing, I'll clarify even though it's not actually relevant to the resolution of either bug. - Apple opted older versions of Camino into quarantine. Camino 0.8 and earlier quarantined downloads without us ever having even heard of quarantine. - We later added a plist key that allowed us to exclude the profile and caches from quarantine. In retrospect, that would have opted 1.0 and later in to quarantine, but we hadn't noticed at the time that org.mozilla.camino wasn't opted in by the OS. - A while later, bug 407215 added additional information to downloaded files to improve the quarantine UE. Every version of Camino already quarantined files at the time that work began on 407215. From our perspective, we don't think of ourselves as having opted in to quarantine, nor was bug 407215 the cause of quarantining. That's why I keep saying that you are misunderstanding 407215, and why I was confused in the other bug about how you might be able to disable it yourself locally. It may be that absent anything else, the code in 407215 is enough to trigger quarantining, which I think is what you are asserting, but I have no idea since we've never had a configuration of Camino where it would be the only thing involved. You are welcome to experiment with various combinations in a custom build if you want to find out.
I'm not saying that Apple did not opt Camino in, I'm saying that Camino is *currently* not being opted in by Apple, it's being opted in by Camino. What I am asserting is that after removing the quarantine entry from the Info.plist file and verifying that Apple is not currently opting Camino in to the quarantine system, Camino is opting itself in and there is no longer any way of opting out. I do not know that there is no other code in Camino to add a com.apple.quarantine entry to a downloaded file other than Bug 407215, but it is the only thing that I can find that would be involved once the Info.plist entry is removed. This has nothing to do with any "one app at a time war against the quarantining system". Apple DOES provide a mechanism to opt out of the quarantine system. After performing all the steps Apple provides, Firefox and Safari are no longer quarantining files. Camino is. The routine in Bug 407215 and any other code you have in Camino to quarantine files should not take effect if the Info.plist entry in Camino.app is not set to quarantine files.
Reopening based on comment 5 and some testing. Apparently LS does in fact interpret setting *just* the when/where attributes as a request to quarantine the file, even absent anything else that would cause quarantining.
Status: RESOLVED → UNCONFIRMED
Resolution: WONTFIX → ---
Assignee: nobody → stuart.morgan+bugzilla
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Attachment #348315 - Flags: superreview?(mikepinkerton)
Retitling to clarify what the actual bug is.
Summary: Enable opting out of Apple's quarantine system. → Don't set quarantine attributes on files that the OS hasn't quarantined
Thank you. I didn't think I was entirely crazy. :) Looking at the patch... what happens if the file has some extended attributes other than quarantine? It seems to me that you should look specifically for a com.apple.quarantine property before adding one, yesno?
(In reply to comment #9) > what happens if the file has some extended attributes other than quarantine? Nothing. > It seems to me that you should look specifically for a > com.apple.quarantine property before adding one, yesno? It seems to me that Apple is unlikely to put things other than quarantine properties in the quarantine properties dictionary.
Ah, sorry, I see where I was confused. Thanks.
Comment on attachment 348315 [details] [diff] [review] Only annotate quarantined files sr=pink
Attachment #348315 - Flags: superreview?(mikepinkerton) → superreview+
Landed on CVS trunk.
Status: ASSIGNED → RESOLVED
Closed: 11 years ago → 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → Camino2.0
You need to log in before you can comment on or make changes to this bug.