Are Microsoft ActiveX controls dangerous?

Well, yes and no...

Microsoft's ActiveX refers to portable, executable COM (Component Object Model) controls for Windows which are both flexible and powerful. Perhaps a bit too powerful, some would say. They run natively on a local machine rather than in a protected environment (sandbox); they can be accepted or rejected, but they cannot be assigned specific restrictions; and they always run with the same privileges as the user. They are, in short, a security gamble.

The chief difficulty is the all-or-nothing nature of the controls. If one is accepted, it simply runs, doing whatever useful task or destructive act it was designed to perform. Users are confronted with a poor, go/no go choice based solely on their willingness to trust the control's author to have done a decent job of making it safe.

An ActiveX control can indeed be signed with a relatively secure crypto scheme in which users can place a fair amount of trust that the author indicated is in fact the original one, and that the code has not been modified since it was signed.

So far so good; the problem here is that any trusted source is perfectly capable of writing appallingly bad code. While an attacker would likely be discouraged from trying to crack the signature and modify the control, a more efficient use of his time would be to look for signed controls which, in their vanilla form, contain flaws which can be exploited.

Thus an apparently safe control from the eminently trustworthy XYZ Software Corp can be applied in a malicious fashion by a clever attacker, often by use of a script which the original author had not imagined, and the hapless end user has no way of guarding against it.

The controls can be executed remotely via e-mail or a Web page. The user's only defence against malicious use is to reject all of them, or to gamble and accept only those from trusted sources. One can, of course, accept even unsigned controls if one wishes; and here we have to point out that an unsigned control is no more likely to be dangerous than a signed one is to be safe.

But at least with a signed control you know whose customer service hotline to ring up and cry to if it wipes your hard disk.

Microsoft, naturally, gushes about all the 'features' these controls make available to users. To the more cynical among us, 'feature' is mere code for 'security hole'.

With this in mind the Computer Emergency Response Team (CERT) at Carnegie Mellon University held an ActiveX workshop this Summer to shed some light on the issues, the final report from which has just been published.

It contains detailed advice for systems administrators in setting up security options, for developers in avoiding common stuff-ups which render the controls full of exploitable holes, and a section towards the end patiently explaining to Harry Homeowner how to manage ActiveX permissions on his magical mystical Windows box with minimal risk.

It's profitable reading; we recommend it. ®

Sponsored: Network DDoS protection