Automatic account creation is now enabled. Captcha authentication required for account creation and editing unless you are trusted here.

Protected Files

From WiX Wiki at MindCapers

Jump to: navigation, search

One of the ways to get an idea of what's protected on Win2k/XP/Server 2003 is to run this program below, listing what's protected on the OS you run it on. It doesn't work on Vista because the protected resource implementation is different. Otherwise you generally have to get knowledgeable about what's part of the OS (or is in a separate redist like MDAC). This is occasionally useful with a bit of interpretation.

 
#include "stdafx.h"
#include <windows.h>
#include <stdio.h>
#include <sfc.h>
 
PROTECTED_FILE_DATA aFile = {0};
FILE *stream;
 
int main(int argc, char* argv[])
{
   BOOL res = true;
   long i=0;
 
   stream = fopen( "sfcfiles.txt", "w" );
   while (res)
   {	
      res = SfcGetNextProtectedFile (NULL, &aFile) ;
      if (res)
         fprintf(stream, "%S\n", aFile.FileName);
   }
   fclose (stream);
   return 0;
}
 

Anything that is protected by Windows in one version should have an official installer or merge module for other Windows versions. By using the official installer, Microsoft can patch the product if there's a bug in it. Don't expose your users to security problems by breaking the detection logic.

Personal tools