• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
When is a disk image file encrypted?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

When is a disk image file encrypted?


  • Subject: When is a disk image file encrypted?
  • From: Luther Fuller <email@hidden>
  • Date: Mon, 27 Nov 2006 15:07:28 -0600

My script is designed to compress (UDZO) [and optionally encrypt] a read-write (UDRW) or an uncompressed read-only (UDRO) disk image file. It should ignore other disk image files. It should ignore any encrypted disk image file. Here is the script to test that ...

try
	"hdiutil imageinfo " & sourceImage & " -format"
	set dmgInfo to (do shell script the result)
on error
	-- notify user that format is not available
	return
end try
if dmgInfo is not in {"UDRW", "UDRO"} then
	-- notify user that input file is not right format
	return
end if

If the dmg file is encrypted, the 'do shell script ...' shows a dialog asking for the password. I see the illogic of this and simply click Cancel. My users will probably be confused by this dialog. To avoid the dialog, I need to be able to determine if the file is encrypted WITHOUT reading the file. Or I need to be able to supress the password dialog, if possible.

The 'hdiutil imageinfo ...' command, without '-format', does return encryption status, but not until you enter the password via the dialog.

I've looked at the DiskImageMounter application. It's scriptable, but no commands to handle encryption.

Any ideas? ... or am I screwed?

_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/mailman//archives/applescript-users

This email sent to email@hidden
  • Prev by Date: InDesign CS2 Library Asset on specific page
  • Next by Date: Re: InDesign CS2 Library Asset on specific page
  • Previous by thread: Re: InDesign CS2 Library Asset on specific page
  • Next by thread: curl for FTP....
  • Index(es):
    • Date
    • Thread