Quarantined apps / drives

There is a security layer built into Mac OS called quarantine. This encapsulates downloaded or untrusted applications and normally shows an extra button to the user to confirm that he wants to run the software, which could possibly harm the Computer. Even though sometimes this mechanism fails.

 I want to open an application on my harddrive

This should solve the quarantine problem for a single application on the main drive:

xattr -r -d com.apple.quarantine /path/name.app

I want to disable the quarantine for a whole directory

xattr -r -d com.apple.quarantine /directory/

I want to be able to start an application from within a mounted disk image (e.g. dmg archive)

Unmount the archive and execute this code with the dmg:

xattr -d com.apple.quarantine /path/file.dmg

Mount the drive again and you should be able to run the application again.

Hint: With the command “mount” you can see which drive is mounted quarantined. Links: http://forums.macrumors.com/showthread.php?t=1557566

Alternative

Copy the Application into the Application directory on your main drive and execute this with the application:

xattr -r -d com.apple.quarantine ~/Applications/app_name.app

I want to disable the confirm to run Button completely

http://hints.macworld.com/article.php?story=20091208050655947

Links

http://derflounder.wordpress.com/2012/11/20/clearing-the-quarantine-extended-attribute-from-downloaded-applications/

  

Quarantined applications Mac OS X 10.8 Mountain Lion

If you have installed an application via a downloaded disk image or a zip file there is the possibility that this application does’t start anymore (or never did). There is a so called “sandbox” feature in the Mac OS X software since 10.6 (I guess it’s 10.6) which should help to identify malicious software which you have downloaded from the Internet. The visible part of it are the prompt-boxes when you start a downloaded application for the first time. But it seems that this mechanism fails sometimes and causes the application not to start. In the “Console” there appear the error messages like:

exec of /<directory-path>/<app-name>.app/Contents/MacOS/<app executable> 
denied since it was quarantined by <another application on your system> 
and created without user consent

If you double-click the application will appear in the dock but disappears immediately. There are a few workarounds. Two of these are:

  • Move the application into the application folder. (I guess the system “thinks” the applications in this directory are clean. )
  • Use the “Terminal” to change the “quarantinedflag of the application:
    xattr -dr com.apple.quarantine /<directory-path>/<app-name>.app/

    This seems not to work with applications which are located in a disk image (even if it’s a read-and-write disk image). Copy it to another location.

Update: Also see this post.

  

Set Default Configurations for Printers (CUPS Printing System)

If you own a color laser printer it may be usefull to set the default value for color-settings to grayscale in order to print faster and use less color toner. However there are no options to set the default values for the printer in the standard Mac OS X configurations. Mac OS X uses the CUPS printing system to provide printing services. The configurations of this system is accessible through a web interface. I recommand to use the Safari browser because you have to authenticate as system admin and it seems Safari supports this better than other browsers. The following steps show what to do:

  1. Launch Safari
  2. type http://localhost:631 in the address bar and hit return
  3. In newer versions of Mac OS X (for sure in 10.8 may be in 10.7 too) the web interface is turned of by default. Therefore a message, which says that appears. In order to activate the web interface open the “Terminal” program in the “Utilities” Folder of the “Applications” folder and type
    cupsctl WebInterface=yes

    and hit return. You can close Terminal again.

  4. Reload the web-page in Safari
  5. Click on the “Administration”-Tab on top
  6. Click on the “Manage Printer”-Button and chose your printer
  7. Select “Set Default Options” from the right drop-down menu
  8. Set your default options and hit the “Set Default Options”-Button.
  9. Now you need to input the security information of a admin account on your Computer. The right username is the same as what is your home directory is named (In older versions of Mac OS X existed e short version of the username, which may differ from the home-folder-name. Use the short-username instead.) Enter the according password
  10. You may need to restart the programs, e.g. Preview, to let the changes take effect. The best would be to reboot the computer, to be sure everything worked.

Successfully tested in Mac OS X 10.8 Mountain Lion.

  

Show User Library Directory in Mac OS X 10.7 Lion & Mountain Lion 10.8

In both the Lion versions of Mac OS X the User Library directory is hidden by default. Here are the commands to use in “Terminal” to make the directory visible or hide it again:

Show the User Library directory.

chflags nohidden ~/Library/

Hide the User Library directory:

chflags hidden ~/Library

Changes will take effect imidiately.

There is an easy method to access the Library directory without showing it permanantly: Use the “Go To Directory” option in the “Go To” menu of the Finder and paste this:

~/Library