• 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
Re: Ejecting An Image Disk
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Ejecting An Image Disk


  • Subject: Re: Ejecting An Image Disk
  • From: Luther Fuller <email@hidden>
  • Date: Fri, 31 Oct 2008 12:31:01 -0500

On Oct 31, 2008, at 11:53 AM, Axel Luttgens wrote:
Let's first consider the problem of hditutil -imageinfo applied to a disk image having at least one mounted volume.

If that volume is R/W, items on that volume are liable to be changed/ created/deleted at any time from other parts of the system; this means that the disk image itself is liable to be continuously modified.
hditutil thus needs to somehow freeze the disk image for a short time, so as to extract the needed info, a *consistent* info, from the disk image.
If you experiment with the -debug flag, you'll notice that hdiutil resolves that problem by attempting to acquire a lock on the disk image.
This will always be successful when the disk image is R/O.
But this will (almost) always fail when the disk image is R/W.

That sounds reasonable. Confirmed recently by an experiment. The Size info could change.
But all I need is the encrypted status.


The reason here seems to be that the "meta-data" itself is encrypted (just do an hexdump on an unencrypted disk image, and compare to what comes with an encrypted one).
From the point of view of security, this seems to be reasonable: it would otherwise be possible to directly tamper with the disk image, without having the fact noticed by the legitimate owner of that disk image.
But of course, the password is then needed to fetch even the "meta- data".

I agree ... but it's still illogical.

The scripts I am working on need to determine if a disk image file is encrypted so it can inform the user that it doesn't handle (burn, convert, &c.) encrypted files. Ever. No passwords needed. Doing that ought to be simple ... but it's not.

Perhaps hdiutil's imageinfo verb should have a '-encrypted' option that ALWAYS returns ONLY the encryption status. This would solve my problem.

_______________________________________________
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/archives/applescript-users

This email sent to email@hidden
References: 
 >Ejecting An Image Disk (From: Luther Fuller <email@hidden>)
 >Re: Ejecting An Image Disk (From: Axel Luttgens <email@hidden>)
 >Re: Ejecting An Image Disk (From: Luther Fuller <email@hidden>)
 >Re: Ejecting An Image Disk (From: Axel Luttgens <email@hidden>)

  • Prev by Date: Re: Ejecting An Image Disk
  • Next by Date: Sturm, Lewis is out of the office.
  • Previous by thread: Re: Ejecting An Image Disk
  • Next by thread: Extracting Text from PDF
  • Index(es):
    • Date
    • Thread