Place a file in a password protected disk image or volume?

Posted:
Tue Jun 14, 2016 6:40 pm
by gold7181
After wowing a large Apple user group with a presentation on Hazel, I received this follow-up question which I don't know the answer to:
Can you make a rule that can place a file in a password protected disk image or volume?
Is there a way for Hazel call up/remember this password every time it’s needed?
Re: Place a file in a password protected disk image or volum

Posted:
Wed Jun 15, 2016 12:09 pm
by Mr_Noodle
You'd need a script to do that unless the volume is already mounted and unlocked.
Re: Place a file in a password protected disk image or volum

Posted:
Wed Jun 15, 2016 3:45 pm
by gold7181
Mr_Noodle wrote:You'd need a script to do that unless the volume is already mounted and unlocked.
Any hints on where I might find a template or example of a script which does that?
(the requirement to be able to do so is the only obstacle preventing my colleague from purchasing Hazel)
Re: Place a file in a password protected disk image or volum

Posted:
Wed Jun 15, 2016 6:55 pm
by Mr_Noodle
If they want the volume mounted, you can either look into using the automounter in OS X, or use the "mount" command to do it manually (for diskimages, you'd want to use the hdiutil command).
Beyond that, it's outside the support I can give. You can try searching the forums to see if someone has done a similar script otherwise you'll have to search the internet at large for scripts to do this.
Re: Place a file in a password protected disk image or volum

Posted:
Sun Jun 19, 2016 9:57 am
by rob_london
gold7181 wrote:Mr_Noodle wrote:You'd need a script to do that unless the volume is already mounted and unlocked.
Any hints on where I might find a template or example of a script which does that?
(the requirement to be able to do so is the only obstacle preventing my colleague from purchasing Hazel)
I encountered the same problem of accessing encrypted disk images and found the solution in the script described here:
http://techanic.net/2012/10/14/programm ... _os_x.html