[Webkit-unassigned] [Bug 24905] Plugin handling via mime type detection differs depending on plugin location

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon May 4 00:24:00 PDT 2009


https://bugs.webkit.org/show_bug.cgi?id=24905


mrowe at apple.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |mrowe at apple.com




------- Comment #6 from mrowe at apple.com  2009-05-04 00:23 PDT -------
I found that in order to reproduce this bug I had to move the Flash plug-in in
to ~/Library/Internet Plug-ins as well.

What's happening here is that CNN checks for Flash by doing
navigator.mimeTypes['application/x-shockwave-flash'].enabledPlugin.name.indexOf('Shockwave
Flash') != -1.  In cases where it fails
navigator.mimeTypes['application/x-shockwave-flash'].enabledPlugin is returning
the ClickToFlash plug-in info object that has a name of ClickToFlash.  When it
passes, it's the plug-in info object for the real Flash plug-in.

The return value of navigator.mimeTypes appears to be determined by iterating
through navigator.plugins and returning the first object that has the given
MIME type.  The order of navigator.plugins on Mac OS X is retrieved from
-[WebPluginDatabase plugins], where it returns the result of -allValues on an
NSMutableDictionary object.   This means that the order of navigator.plugins is
dependent on the hash algorithm used by NSDictionary when hashing the NSString
of the path to the plug-in, which is used as the key to the dictionary.

It seems to me that we should be making an effort to return the plug-in from
navigator.mimeTypes that will be used to handle the given MIME type.  On the
Mac, this would mean having it respect the WebKit vs Netscape plug-in
preference that we employ when instantiating plug-ins, as well as the version
checking logic.  Doing so would cause CNN video to consistently fail when
ClickToFlash was in use, so I think they'll need to fix their plug-in either
way.


-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list