Re: More - Safari Download Security Alerts
Re: More - Safari Download Security Alerts
- Subject: Re: More - Safari Download Security Alerts
- From: Jean-Daniel Dupas <email@hidden>
- Date: Tue, 16 Dec 2008 20:29:28 +0100
Le 16 déc. 08 à 20:02, Dave a écrit :
Hi,
I looked at xattr but can't find a man page and couldn't seem to
find much about it anywhere. I did a xattr -l CleanUp.App, and it
produced a dump of the data and resource forks. I can't see any
attribute names. Is there any docs on xattr? Or better still, what
is the command I would need to remove the quarantine status of the
file?
xattr -d com.apple.quarantine myFile
The problem is that the fact OS X uses an extended attribute to store
this flag is an implementation details (and may change). That's why
you should use Launch Services.
One other thing, is xattr guaranteed to be on the user's system? Oh,
and will this work on Version of MacOS X < 10.5 ?
Yes, it's garantee on Mac OS 10.5, and this attribute is not supported
on previous versions, so you don't have to care (if xattr does not
exists, just skip this step in your installer).
Thanks a lot
All the Best
Dave
On 16 Dec 2008, at 18:23, Geoff Beier wrote:
I see. I didn't catch the dialog on the disk image itself. While
diving into package maker is the right thing to do, you should be
able
to fix your installer so that your workflow looks like:
1. Download the .dmg file.
2. Mount the image. (security dialog? i don't think i get these)
3. Launch the installer script (security dialog. no way around this
one)
Then the installer:
a. creates your directory
b. copies your cleanup app, real app, etc. to your directory
c. uses either the launch servcies calls (actually xattr probably
makes more sense from an applescript) to clear the quarantine
attributes from the cleanup app and real app
4. cleanup app (no security dialog thanks to the above)
5. real app (ditto)
If that's a good enough workflow to get your demo out the door and
buy
you some time to learn packagemaker, clearing those attributes ought
to be an easy addition to your install script.
HTH,
Geoff
On Tue, Dec 16, 2008 at 12:55 PM, Dave <email@hidden>
wrote:
On 16 Dec 2008, at 17:46, Geoff Beier wrote:
Sorry. I was pointing to a different part of the advice:
you
want to bypass the warning for your real app after the user has
accepted
the
warning in for your installer, look at the keys and constants in
<LaunchServices/LSQuarantine.h> for what you can pass to
LSSetItemAttribute() in LaunchServices.
I think it should work if you don't feel like PackageMaker
works for
you. Did you try it? Did it work?
Did you try calling LSSetItemAttribute() on your cleanup bundle
and on
your real application? (or shelling out to xattr if that's easier
from
the context of your installer?) Did it fix your warnings? What
problems did it cause you? All I saw in your follow-up was
discussion
about packagemaker. Did I miss where you talked about trying the
LaunchServices calls?
Sorry, I misunderstood. I haven't used any LaunchServices calls,
it wouldn't
really work anyway, since I'd get still get 2 or 3 security
dialogs and I
just want one (or none).
1. Download .dmg file.
2. Mount the Image (Security Dialog).
3. Launch the Installer AppleScript (Security Dialog).
4. Launch the CleanUp AppleScript Security Dialog).
5. Launch the Real App, (Security Dialog after doing the
LaunchServices
magic).
All I have done is to create an Installer with PackageMaker, but I
can't get
it to installer a folder with the files in it.
All the Best
Dave
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden