TextEdit bug with com.apple.quarantine extended attribute



I was having fun and games with the "This file has been downloaded from the Internet" message appearing even for files that I had created myself. I've finally been irked enough to track it down to a bug in TextEdit.

In Lion 10.7.4 open a Terminal shell. Then do:

$ cd ~/Documents
$ echo "fred" > test.txt
$ xattr test.txt

There is no output as no extended attributes are set. Now double-click test.txt in the Finder to open it using TextEdit and enter a few characters (e.g. add "bloggs" to the second line). No need to save. Go back to the console:

$ xattr test.txt
com.apple.TextEncoding
com.apple.quarantine

Oops!

Go back to TextEdit, save the changes and com.apple.quarantine is gone (but TextEncoding remains as it (probably) should do.)

Go back again to TextEdit, type a few more characters and Quit (so that 'versions' retains a copy), and com.apple.quarantine is back.

Mostly this is an invisible problem however some of my AppleScript droplets complain with the message "This file has been downloaded from the Internet... etc"

--
Bruce Horrocks
Surrey
England
(bruce at scorecrow dot com)
.



Relevant Pages

  • Re: Saving text files with Textedit
    ... The Unix command line tools in Terminal mostly deal with ASCII text ... and avoid the use of non-English characters. ... The best encoding format to pick is probably of the normally hidden ... Was this an old file you were modifying in TextEdit? ...
    (comp.sys.mac.misc)
  • Re: Saving text files with Textedit
    ... Easiest option in this situation is not to use TextEdit. ... and avoid the use of non-English characters. ... The best encoding format to pick is probably of the normally hidden ... there is a third standard: ...
    (comp.sys.mac.misc)
  • Re: Entering Hebrew Text in Word 2004 for Mac
    ... typed the phrase שָׁלוֹם into TextEdit and saved it as an RTF document. ... However, TextEdit, also has an option to save a document into whatever Apple ... with the diacriticals in the right place! ... I found that I’m able to copy/paste these characters easily ...
    (microsoft.public.mac.office.word)
  • Re: Diacritics in Office 2004
    ... characters in TextEdit and copying them in Word, ... Sound familiar? ...
    (microsoft.public.mac.office)
  • Re: Turkish Characters
    ... Applications like TextEdit support Unicode. ... > Unicode Character Palette I can insert most of the Turkish characters. ... That entirely depends on what font you are using. ...
    (microsoft.public.mac.office)