Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

About Manifest file

Tags:

manifest

Recently, I encountered a very strange issue, this issue only happens in Windows XP SP3 and Vista. Here are my steps:

  1. Create two new folders in desktop (assume folder names are A and B)
  2. Copy Microsoft GraphEdit (graphedt.exe) application to A folder, then create a empty graphedt.exe.manifest file as well. Run graphedt.exe, you will see a error message, the graphedt.exe can’t run due to the wrong manifest.
  3. Copy Microsoft GraphEdit (graphedt.exe) application to B folder, run graphedt.exe and close it, then create a empty graphedt.exe.manifest file, run graphedt.exe again, you will see the manifest file can’t apply to graphedt.exe. But if you change the last modified time of graphed.exe, the manifest will work again.

It seems Windows will remember the status the first time the EXE uses a manifest file, but also Windows will reset the old remembered status if you change the EXE size or last modified date.

like image 710
Yigang Wu Avatar asked Jan 06 '09 08:01

Yigang Wu


People also ask

What is the manifest file used for?

The manifest is a special file that can contain information about the files packaged in a JAR file. By tailoring this "meta" information that the manifest contains, you enable the JAR file to serve a variety of purposes.

Where is the manifest file?

The file is located at WorkspaceName>/temp/<AppName>/build/luaandroid/dist. The manifest file provides essential information about your app to the Android operating system, and Google Play store. The Android manifest file helps to declare the permissions that an app must have to access data from other apps.

What is a manifest file and how do you open it?

A MANIFEST file is an XML document that describes the manifest, or package contents, of a Windows software application. It is used by various Windows technologies for configuring and deploying software, including ClickOnce and the Common Language Runtime (CLR). MANIFEST files are often seen with the compound ".exe.

What is manifest file in PC?

An application manifest (also known as a side-by-side application manifest, or a fusion manifest) is an XML file that describes and identifies the shared and private side-by-side assemblies that an application should bind to at run time. These should be the same assembly versions that were used to test the application.


1 Answers

[I'm the current SxS maintainer at Microsoft]

Good investigation Yigang. You're describing the behavior on Vista, not on XP SP3.

Probing for the existence of a manifest every time an app is run would be a performance issue, since usually apps either have a manifest or don't, and that state doesn't change much. For this reason, on Vista, the first time an application is run, we cache a bit describing "this application has an associated manifest" or "this application does not have a manifest". When you ran graphedt.exe the first time, Windows cached the absence of a manifest, and will subsequently not look for one. To reset the cache, update the last modified time on the executable.

like image 186
Eugene Talagrand Avatar answered Oct 18 '22 22:10

Eugene Talagrand