How To Disable Tag Filters on Apple’s Wiki/Blog Server
The wiki/blog server in Mac OS X Server is a boon for collaboration between groups with simple needs. It provides easy posting of text, images and other files on wikis and blogs. However, it has a few drawbacks. To improve security on the blogs and wikis, Apple set up filters to allow only a limited set of simple HTML tags in the user-generated content – the rest are automatically removed. For private servers, where the users are authenticated and trusted, this is needlessly limiting. Here’s how to disable that feature.
It is very simple to do: you just need to comment out two lines of this file:
/usr/share/wikid/lib/python/apple_wlt/ContentFilters.py
Before you make any changes, create a backup copy of the file in case something goes wrong or you change your mind later. In Mac OS X Server 10.5.4, you need to comment out lines 9 and 21 of ContentFilters.py. They are the two lines that import and reference the “WhitelistContentFilter.py” file and it’s functions.
...
#import WhitelistContentFilter
...
#WhitelistContentFilter.WhitelistContentFilter(supportPath + 'whitelist.plist'),
...
The
Note that the above is not the official way of managing whitelists. I would only recommend it if your blog and wiki is access controlled so that only trusted users can edit content. If your blog and/or wiki is open to public access, you create a severe security hole by disabling content filtering. Note also, that future updates from Apple may over-write these changes.
The official way to edit the “whitelist” of allowed tags is to add this file to your system:

November 19th, 2010 at 01:24
commentssss
November 23rd, 2010 at 11:49
I have question… i am trying to do this on my xserve. i go in and modify the contentfilters.py file thru finder and it tells me i don’t have permission to save (saving as adminitrator) I change the permissions in finder and still tells me same thing.
help! i need to get this working.
Thanks,
Chad
November 23rd, 2010 at 14:00
Hi Chad, open Terminal, and do:
cd /usr/share/wikid/lib/python/apple_wlt/
sudo nano ContentFilters.py
Enter your (administrative) password when prompted. Use CTRL-W to write your changes, and CTRL-X to exit the editor, as per the indications at the bottom of the screen.
December 8th, 2010 at 15:16
That worked. Thanks!!
February 2nd, 2011 at 09:05
Many thanks for that! How on earth did you figure it out?
Now I’m wondering if there’s some similar process to disable the changing of doublequotes ” to &qoute; it’s breaking any javascripts entered through the webeditor of the wiki…