Chat with us, powered by LiveChat
Registry | Part 3

Registry | Part 3

Brief History of REGEDIT (and REGEDT32)

A primary tool for editing the registry appeared with Windows 3.1, named publisher of the registration information (Registration info editor, the English version), Regedit.exe, the main purpose of this program was to change groups of files and records of OLE components.

With the introduction of Windows NT, the Win32 API newly introduced the concept of access permissions for the registry keys, to manage them properly along with other new features of the register, was specifically created a new program, Regedt32.exe, definitely most comprehensive of its predecessor’s 16-bit Regedit.exe.

Registry Editor in Windows XP, aesthetically identical to its ancestor for Windows 95

A few years later, with the advent of Windows 95, Regedit.exe was renamed as the current editor of the registry and was brought to 32 bits. This, however, not implemented the section about the safety of Win32, so it remained a stand-alone product, with a production path separated from that of REGEDT32.EXE. This situation remained unchanged even with the introduction of Windows 98, since it was only a modest evolution of Windows 95, at least from the standpoint of safety. The new user interface REGEDIT.EXE had more functional and more appealing to its analogue for Windows NT, but was able to manipulate only a subset of data types provided by Win32, and as noted above, did not allow the modification of permits access to the keys (which were, in fact, absent).

Subsequently, first with Windows NT 4.0 and later with Windows 2000, both instruments were distributed. This leaves users with the choice between a more crude, but effective, or a program with a user interface more familiar and practice (similar in every way to Windows Explorer), but that did not allow to exploit all the possibilities of the system operational. In particular, since REGEDIT.EXE unable to handle many data types of the powerful Windows NT registry and its descendants, changing a value of one data type to unknown REGEDIT.EXE could lead to corruption of the value, with heavy implications on the stability of the system.

Finally, with Windows XP, the two programs were merged into a single descendant, basically using the convenient user interface to the most sophisticated REGEDIT.EXE REGEDT32.EXE. The result is called regedit.exe, and there is a mini-program called REGEDT32.EXE who always refers to Regedit.exe.

Registry: Command line

For systems based on Windows NT there is a tool that allows you to operate on the registry from the command line. It is included in Windows XP with the name of reg.exe, and is available separately for earlier versions of the operating system from Microsoft. The command can be invoked with this syntax:

Reg.exe [QUERY | ADD | DELETE | COPY | SAVE | LOAD | UNLOAD | RESTORE | COMPARE | EXPORT | IMPORT] [parameter list]

Moreover, the application GUI REGEDIT.EXE allows to operate via the command line, only import files. REG (portions of recordings stored in text format):

REGEDIT.EXE / s file

The /s means to run in silent mode without user interaction, if omitted, the program prompts the user for confirmation. In Windows 95 and Windows 98 the / s was performed successfully even in the presence of a possible administrative block of the program. Unlike reg.exe, REGEDIT.EXE does not return an error code (ERRORLEVEL) appropriate when used to import a file, which complicates the management of errors in automated scripts and one way to determine the success of an operation import is to check later if you can export the key that he had tried to import:

regedit / s Import.reg
regedit / e TestExport.reg “Key to import”
if not exist goto TestExport.reg ImportError
of TestExport.reg
goto Exit
: ImportError
echo Error during import into the registry.
: Exit

The default action associated with the file type. REG, since Windows 98, corresponds to the requesting confirmation from the user, in Windows 95 the association was the same, except that no mail was not application, and was therefore a potential source of errors.

Location of log file

Depending on the version of Windows, the registry is stored in one or more files in known locations, but always on the same computer, the only exception, only by Windows NT on, is given by the private profile file for each user that, due to the characteristics of the remote profiles, can reside on a machine (guest profile) reachable via the network.

Strengths of the concept of registers

Compared to classic INI files, the registry offers a few advantages:

* The size and homogeneity restrictions can run scripts without the need for each application.

* Since this is a small number of files in known locations, there are requirements for good ease of backup.

One might think that an advantage lies in the fact that the register keeps the machine-level settings separated from the individual settings for users. Indeed it was for older versions of Linux dating back to the twentieth century, and since he also uses the Windows Business Unix-style operating systems (separate folders per user, containing the configuration files of all the programs used by the user), the disadvantage is falling.

One might suppose that the presence of a centralized registry and group policy favoring centralized management by the directors, but in reality the same is achievable even more simple and intuitive interface with a system file (just copy them to the home directory user’s system).

One might, finally, to think that the presence of an API that allows a remote control can be an advantage: indeed the opposite is true, because it adds another level of abstraction is pointless. With simple file remote control settings would be possible using standard protocols for the management of remote files (e.g., FTP).

Continued…

Sharing

Leave your comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.