We have an .mp4 video hosted on a web site. I can play back the video from the production version of the web site, but not the test version of the site.
The production web site has the .mp4 MIME type as video/mpeg
, which apparently is incorrect — see here. Whereas the test server has the MIME type set correctly — video/mp4
— but media player says it can't play the file. (And changing the MIME type to match the production web site doesn't fix the issue.)
Which would seem to indicate the MIME type is not the problem.
According to this Microsoft Knowledge Base article, the .mp4 file format is not supported, even in Media Player 12 … unless you install a codec. But, as noted, playback does work from the production site … and, if I right-click on the video and download it to my desktop, I can play it back from my desktop as well.
Which would seem to indicate that the codec (or lack thereof) is not the problem.
… but I can play the video (from the test web site) it if I install a codec pack.
Needless to say, I'm confused. Can anyone shed any light?
Windows 7 (Enterprise) x64
Media Player 12
Windows Server 2008 R2 / IIS 7.5
Best Answer
In the event someone has a similar issue ...
As it turns out the problem was related to digital certificates on the server(s).
On the production box, the certificate name matches the DNS name. On the test boxes, it did not. (The test servers each host a number of test web sites.) So you'd get a certificate ("name mismatch") warning. BUT after dismissing the warning you could still download static content of other types -- we have PDFs and images (in various formats) that all worked fine -- it was just Media Player that, for whatever reason, wouldn't work.
Our server admins had assured me that once you dismissed the certificate warning, the certificate name mismatch should no longer be a problem. And that seemed reasonable to me and in line with what I knew, otherwise I'd have mentioned that in my original post.
But when I tried accessing the MP4 file with Fiddler running, I got a second certificate mismatch error popup (from Fiddler) ... and then after I said "ignore this error and continue" the video did in fact play.
So my best guess is:
It seems to me that several things went wrong here.
But the certificate was about due for renewal ... so when it was renewed we had the site name added as an "alias" (Subject Alternative Name aka "SAN") on the cert. So we no longer get the certificate name mismatch warnings on the test site(s) ... and the video plays just fine.