Existing users, log in.  New users, create a free account.  Lost password?


MacFixIt Logo
 
Contact Us | About MacFixIt | Who's Online  

Page 1 of 2 1 2 >
Topic Options
#129905 - 09/25/03 10:49 AM Unsanity condemns Aladdin's use of KEXTs for AVR
Mango Offline
Writer

Registered: 08/23/00
Posts: 165
Loc: Canada
http://www.unsanity.org/archives/000253.php

In reply to:

September 25, 2003

Aladdin and Kexts

I have recently came across just-released StuffIt Deluxe 8. Among other cosmetic enhancements, it includes a "new" (or rather, "new for OSX", since the feature existed back in Mac OS Classic versions of StuffIt) feature called "Archive Via Rename" that allows you to compress or expand files or folders quickly just by appending or removing an archive file extension (.sit, .sitx, .zip, etc).

Whereas the feature is a real life-saver for many people, and undoubtfully a convenient feature, I could not agree with the technology decision used to implement the feature in the Finder: it is a Kernel Extension.

Just how stupid is that? For the ones of you who would like the scoop right now, this is a quick round-up: APE, mach_inject, InputManager and similar techniques operate on a process level -- they can only access memory allocated to a particular process, and if things go very bad, that process will crash. Kernel Extensions load directly into the kernel, therefore they got access to everything in memory, including the sacred private kernel memory space. This means, if Kernel Extension goes haywire, you get a Kernel Panic (hello Bluetooth adapter drivers that got supposedly fixed with 10.2.8!). So in the first case, you get an application dying; in the second case you'll have to reboot your Mac.

Kernel Extensions are mainly used for device drivers -- these beasts have to have direct access to the kernel; some tools like Little Snitch also install their own kexts to trap on fundamental processes of the system (network operations in this particular case). But using a Kernel Extension to tweak Finder.app is not just plain silly, it is dangerous and stupid - Aladdin risks the stability of your whole system just so their single feature only affecting Finder.app could work. Moreover, if you launch the StuffIt AVR Preference Pane and turn off the feature, the Kernel Extension will stay there, silent, and ready to strike if anything goes wrong.

In real world, there are half a dozen solutions that do not involve making a Kernel Extension: above-mentioned APE, a QuickTime component, a Contextual Menu Module. Aladdin just picked the most outrageous out there - the approach can very well be compred to killing a mosquitoe with a nuke blast. Sure it works, but the impact is just slightly bigger than needed.

Let's just hope Aladdin has awesome programmers and that the above-ranted Kernel Extension is perfect and has no bugs.

Posted by slava at September 25, 2003 04:20 AM




Top
#129906 - 09/25/03 01:45 PM Re: Unsanity condemns Aladdin's use of KEXTs for A [Re: Mango]
Aladdin Support Offline
MacJournalist

Registered: 05/17/01
Posts: 957
Loc: California
Mango-

There are certainly some valid points to this letter. The best information that I can offer in regards to the points slava raises are:

1) Most of the AVR kext was written by a former file system engineer for Apple who has extensive experience writing file system code and extensions.

and

2) The kext itself is very light-weight. It only overrides a single function (rename), and only when the file extensions are supported by AVR. And when we do override rename, the actual work is done by StuffItAVRDaemon which is a separate running application. If something goes wrong, it will go wrong in the application causing no harm to the kernel.

Certainly having AVR operate as a kext is not the 'perfect' solution. It is what we have for now, and its possible that in the future in will change to some other method. For what its worth, we have seen a very low (percentage wise) number of contacts regarding trouble with AVR under OS X.

--
Josh Stender
Aladdin Systems Technical Support


Top
#129907 - 09/25/03 01:56 PM Re: Unsanity condemns Aladdin's use of KEXTs for A [Re: Aladdin Support]
Mango Offline
Writer

Registered: 08/23/00
Posts: 165
Loc: Canada
Josh,

Thanks for the reply. It should help clear up some anxiety about Aladdin's AVR kext.

Top
#129908 - 09/26/03 12:20 PM Re: Unsanity condemns Aladdin's use of KEXTs for A [Re: Aladdin Support]
Bryan Pietrzak Offline


Registered: 01/20/01
Posts: 7
I hate this. I really do.

I refuse to buy software that patches my operating system. The haxies are bad enough, but now kernel extensions. This really sucks.

I don't care how good your ex-file system engineer is. This is OS 9 all over again. I thought we left this behind us? Badly written patches, incompatible patches (with other software and with OS upgrades), and so on. Why are we bringing this wonderful "user experience" to Mac OS X? Why can't it be left on Mac OS 9?

Someone needs to create a web site that documents software that patches so consumers can make informed choices as to what to buy install. I for one will never buy StuffIt Deluxe based on this activity.

Developers need to ask themselves, just because I can patch, is it the right thing to do?

Bryan

Top
#129909 - 09/26/03 02:51 PM Re: Unsanity condemns Aladdin's use of KEXTs for A [Re: Bryan Pietrzak]
Anonymous
Unregistered


> I refuse to buy software that patches my operating system.

then don't.

> Someone needs to create a web site that documents software that patches so consumers can make informed choices as to what to buy install. I for one will never buy StuffIt Deluxe based on this activity.

You obviously have lots of free time, maybe you should do it? I would personally use it to find neat and interesting patches that i would otherwise not know about.

Top
#129910 - 09/27/03 05:53 PM Re: Unsanity condemns Aladdin's use of KEXTs for A
themexican Offline
New User

Registered: 11/29/01
Posts: 8
Installing a ktext file with a program as buggy as stuffit is just plain obnoxious.

---
Another issue. On my G5, stuffit doesn't properly set the execution flags on many unstuffed applications. Consequently many many applications unstuffed with stuffit will not run.

I don't know if this happens with other machines, but it is pervasive on the G5. If you own a G5 don't install 8.0 until there is an update.
_________________________
I am kind to my friends, cruel to my enemies.

Top
#129911 - 09/27/03 06:41 PM Re: Unsanity condemns Aladdin's use of KEXTs for A [Re: themexican]
Robo-X Offline
MacReporter

Registered: 01/20/01
Posts: 485
Loc: Germany
Yes it's a bug and it happens on all machines running OS X which of course mean all Stuffit 8.

There is a bug where decompressing a .sit file will change the flag of executable files. The workaround is to use .sitx which I don't see as a workaround for already .sit stuffed files.

//Rob

Top
#129912 - 09/27/03 07:13 PM Re: Unsanity condemns Aladdin's use of KEXTs for A [Re: Robo-X]
noldo66 Offline
MacJournalist

Registered: 01/29/02
Posts: 791
Loc: Tierra de Pancho Villa
Robo-X,

This exists only in ".sit" formats since executable permissions are NOT preserved on compression in this format, hence we used to automatically assume and assign these executable permissions upon expansion. We made the change because of a concern Apple voiced in their comments regarding the future release of Panther. We plan to address a workaround, like an Expander preference that can be set, in a future dot release.

Top
#129913 - 09/28/03 09:39 AM Re: Unsanity condemns Aladdin's use of KEXTs for A [Re: Bryan Pietrzak]
Anonymous
Unregistered


The solution to your concerns is simple and obvious. After installing SD 8.0, but before restarting simply remove the KEXT. You will not have this one feature but everything else should continue to work.

I agree that this is not the best way to implement a feature but I'd bet over time that Aladdin will implement this feature in a better manner. They do have a good track record.

Actually, we should send a little noise to Apple since there is no way for an application to easily hook into one of the built-in apps. An API to the Finder would be awesome. If Apple implemented a callback function allowing a third party to overide default actions think of the wonderful things that could be accomplished.

If Aladdin could request that the Finder call their daemon to rename a file then the problem would be solved. Aladdin could process the request, if they wanted, or allow the Finder to do its default thing. That's the way it should be.

My two cents.

Top
#129914 - 09/28/03 09:49 AM Re: Unsanity condemns Aladdin's use of KEXTs for A [Re: noldo66]
Robo-X Offline
MacReporter

Registered: 01/20/01
Posts: 485
Loc: Germany
Yes I know but what should I do when I have lots of already stuffed .sit files? I can't expand them with Stuffit Deluxe 8 because they won't work anymore.

//Rob

Top
Page 1 of 2 1 2 >



VersionTracker: Software Updates and Downloads | iPhone Atlas: iPhone Help, News, Tutorials, and Tips