Microsoft Knowledge Base Email Alertz

Certain characters in a file name may be converted to underscores when a user downloads a file by using Windows Internet Explorer 7

Search KbAlertz

Advanced Search

Receive Microsoft Knowledge Base articles by E-Mail?

Every night we scan the Microsoft Knowledge Base. If technologies you're interested in are updated, we'll send you an e-mail. You only get one e-mail a day, and only when new articles are added.

Click here to create a
FREE account
Already have an account?
[Click here to Login]











Microsoft Knowledge Base Article

This article contents is Microsoft Copyrighted material.
©2005-©2007 Microsoft Corporation. All rights reserved. Terms of Use | Trademarks

Article ID: 949197 - Last Review: September 28, 2011 - Revision: 3.0

Certain characters in a file name may be converted to underscores when a user downloads a file by using Windows Internet Explorer 7

SYMPTOMS

When a user visits a Web site that you own, and the user downloads a file by using Windows Internet Explorer 7, the user may find that certain characters in the file name are converted to underscore characters (_) after they download the file.

This problem occurs when any of the following characters are in the file name.
Collapse this tableExpand this table
CharacterName
<Left angle bracket
>Right angle bracket
\Backslash
"Quotation mark
/Slash mark
:Colon
|Vertical bar
?Question mark
*Asterisk
Space

CAUSE

This problem occurs because the Wininet.dll file resolves certain file stream issues when users download files by using Internet Explorer 7.

RESOLUTION

To resolve this problem, do not use "Content-Disposition: Attachment; filename=" HTTP header.

MORE INFORMATION

If a file name in this header contains a certain special characters, the cache code calls the CreateFileA() method on that name. If you use the NTFS file system, an alternative stream is created. Then, the WinInet.dll file writes only to the alternative stream.

When a cache entry is committed, the file name is included in the cache entry. Because the CreateFileA() method on the named stream works, the WinInet.dll file does not generate an error. Instead, it uses a random name. Therefore, when the cache entry is retrieved, and the caller tries to open the file, the open operation fails because WinInet.dll file tries to open the FileName file. Instead, the WinInet.dll file must open the FileName:$DATA file.

Therefore, you cannot cache or download content when the Content-Disposition file name token contains a file name that uses one of the special characters that are listed in the "Symptoms" section. The new version of the WinInet.dll file resolves this problem by checking for these characters and replacing them with an underscore character.

APPLIES TO
  • Windows Internet Explorer 9
  • Windows Internet Explorer 7
Keywords: 
kbexpertiseinter kbtshoot kbprb KB949197
       

Community Feedback System

Very often, it takes hours to solve a problem. Very often, you've looked high and low, and have tried a lot of solutions. When you finally found it, chances are, it was because someone else helped you. Here's your chance to give back. Use our community feedback tool to let others know what worked for you and what didn't.

Please also understand that the community feedback system is not warranted to be correct, it's simply a system that we've built to let people try and help each other. If something in a feedback response doesn't make sense to you, or you're not comfortable making changes that the feedback talks about (like registry edits), please consult a professional.

Thank you for using kbAlertz.com Feedback System.

-- Scott Cate