The Silenced Flash Plugin
(For IE (Flash v7))


This page is heavily outdated and should be used for reference information only. The latest player from Adobe is now v9. Get it here.

So.. You want your flash plugin to be silenced for good? Great! Finally we can get rid of those good-for-nothin' ads who desperately try to draw our attention with flashing images and crazy sounds! (okay okay then.. we can't yet do anything about the flashing part)

Now, for some unknown and mysterious reason Macromedia chose to leave the sound-enabled option to the developers of a flash movie, without even considering the fact that quite a few of us would like that control in our own hands!

After numerous times being bombarded with crazy music from a flash movie, I finally grew tired of it and so altered it to never say another peep again.
This new silenced version is a very simple hack done on the original flash plugin from Macromedia.

If you just want the new plugin, fetch it here:

Note! This is only for Internet Explorer based browsers!
Silenced plugin: silenced.v7.flash.ocx (Version 7.0.19.0) (Fetched 353 times)
Original plugin: original.v7.flash.ocx (Version 7.0.19.0) (Fetched 370 times)

How to install it?

This is quite simple:

  1. Make sure you don't have any flash-enhanced webpages open.
  2. Locate your existing flash plugin. On a default XP installation it resides in C:\WINDOWS\system32\Macromed\Flash
  3. Rename the file "flash.ocx" to something like "old.flash.ocx".
  4. Copy the above downloaded silenced.v7.flash.ocx into the directory.
  5. Rename "silenced.v7.flash.ocx" to "flash.ocx".
  6. Open up your browser, and go fetch a web-site with a flash-movie that contains sounds... (www.movies.com)
  7. You'r all done.

What todo if I want to do the hack myself?

The hack was done by analyzing the file through a disassembler called Ida. These are the steps:

Fire up IDA, and load flash.ocx.

A quick review of the import table tells us the plugin is using the Microsoft Multimedia system's waveOut* functions for playback.
A quick peek at the MMS API tells us that a prior call to waveOutOpen, which must returne true, must have occured before we can use the rest of the waveOut* functions.

If we were to change the result of waveOutOpen so that it would fail, we would have succeeded.

This is how we do it:
Locate the entries where the plugin calls the MMSystem WaveOutOpen function.
  This should yield two results:

  1. .text:10073AB5
  2. .text:10093E19

Through the MSDN documentation we learn that the waveOutOpen is defined as:

MMRESULT waveOutOpen(
  LPHWAVEOUT phwo,
  UINT_PTR uDeviceID,
  LPWAVEFORMATEX pwfx,
  DWORD_PTR dwCallback,
  DWORD_PTR dwCallbackInstance,
  DWORD fdwOpen
);

According to the documentation, a result of MMSYSERR_NOERROR (which is zero) is returned upon success. Our mission is to change that!
Further investigation reveals that when the waveOutOpen function is parsed an illegal Device ID, it will fail.. yeah!

Analyzing the parameters the flash plugin parses to the WaveOut function, we find that the plugin's only interest is opening a wave capable playback device. According to the MSDN documentation, this is accomplished by setting the Device ID parameter to 'WAVE_MAPPER' which is equal to -1.

At and a few steps before location .text:10073AB5 we find:

.text:10073AB2 push 0FFFFFFFFh
.text:10073AB4 push eax
.text:10073AB5 call ds:waveOutOpen

In hex that's:

6A FF 50 FF 15 B8-34 0B 10

Changing the first FF to FB results in the device ID parameter for the waveOutOpen function to be -2, which should result in failure.

So, fire up your favorite hex-editor, open up "flash.ocx" and locate file-offset 73AB5. There you should find the above hex string. Change the first FF to FB.
Now, go find file-offset 93E19. Again the above hex string should match. Change the first FF to FB here as well.

Save the new file as something like "silenced.flash.ocx"

In Ida, after analyzing the new "silenced.flash.ocx" file, the result is:

.text:10073AB2 push 0FFFFFFFBh
.text:10073AB4 push eax
.text:10073AB5 call ds:waveOutOpen

And for .text:10093E19:

.text:10093E16 push 0FFFFFFFBh
.text:10093E18 push esi
.text:10093E19 call ds:waveOutOpen

We have now successfully altered the UINT_PTR uDeviceID from the WAVE_MAPPER parameter into a -2. As you might have noticed, the parameter specificly states that it is a unsigned integer. Thus the -2 becomes wave device 4,294,967,294 (4 giga). So, if you have 4 billion wave cappeable devices in your system, this hack will result in audio emerging from that device.

Now for the exiting part; The test :)

  1. Close down all your IE browser sessions that has flash content in them.
  2. Locate your flash.ocx file (you should know where to find it by now)
  3. Rename the "flash.ocx" to "old.flash.ocx".
  4. Rename (or copy) the new "silenced.flash.ocx" to "flash.ocx"
  5. Fire up you IE browser, and go to www.movies.com (who for a _very_ long time has used a crappy sound-enabled flash movie)

aaahhhh silence.. what a bliss!

So what now?

Well.. Perhaps you have a version of the flash plugin which I haven't? Hack it and send it to me (or send it raw, and I'll do it)...
You have created a little tool for automatic on/off for all known versions of the flash plugin? Great! I want it! Please send it to me.. I'm too lazy to do it myself :(

Hope ya all enjoy it,
Philip S.


Copyright © Philip Soeberg 2004.
Last update @ 27 May 2004
Hits: 2511