Most Accurate and correct way to compare two large windows 8.1 registry files (C++/C# or any anything else)

StackOverflow https://stackoverflow.com/questions/22492475

  •  17-06-2023
  •  | 
  •  

Question

I exported the entire registry of my computer and it's size is around 350 MB. After that I installed some things and exported the registry again. The file size now is around 351 MB. I want to know the difference in two files i.e. what registry keys were added. One way I can think of doing is that - write a c++ program that loads the first file in memory and stores the lines in an unordered_map. Then I read line by line - the second file and see whether each line exists in the first file or not? Now writing this code is easy. But I don't know the structure of registry files. So whether some key-value pairs could be stored in multiple lines or all are stored in single lines. I am sure someone would have encountered this problem before. Any ideas will be great. Thanks. I know that C# also has a class to read registry files. I will look at that as well.

VVV

Was it helpful?

Solution

Did you export it with regedit into a .reg file? If yes, comparing is simple. The .reg files are just text files, so you can use any diff utility.

This should be accurate, if the diff utility can handle files that big.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top