Method for Protecting Security Accounts Manager (SAM) Files Within Windows Operating Systems

Information

  • Patent Application
  • 20080076355
  • Publication Number
    20080076355
  • Date Filed
    September 27, 2006
    18 years ago
  • Date Published
    March 27, 2008
    16 years ago
Abstract
A method for protecting Security Accounts Manager (SAM) files within a Windows® operating system is disclosed. A SAM file encryption key is generated by encrypting a SAM file via a syskey utility provided within the Windows® operating system. The SAM file encryption key is then stored in a virtual floppy disk by selecting an option to store SAM file encryption key to a floppy disk under the syskey utility. A blob is generated by performing a Trusted Platform Module (TPM) Seal command against the SAM file encryption key along with a value stored in a Performance Control Register and a TPM Storage Root Key. The blob is stored in a non-volatile storage area of a computer.
Description

BRIEF DESCRIPTION OF THE DRAWINGS

The invention itself, as well as a preferred mode of use, further objects, and advantages thereof, will best be understood by reference to the following detailed description of an illustrative embodiment when read in conjunction with the accompanying drawings, wherein:



FIG. 1 is a block diagram of a computing device in which a preferred embodiment of the present invention is incorporated; and



FIG. 2 is a high-level logic flow diagram of a method for setting up a computer for protecting a Security Accounts Manager (SAM) file within a Windows® operating system, in accordance with a preferred embodiment of the present invention;



FIG. 3 is a high-level logic flow diagram of a method for performing a normal boot process after the setup process from FIG. 2 has been completed, in accordance with a preferred embodiment of the present invention; and



FIG. 4 is a high-level logic flow diagram of a method for booting a computer by using a backup key, in accordance with a preferred embodiment of the present invention.





DETAILED DESCRIPTION OF A PREFERRED EMBODIMENT

Referring now to the drawings and in particular to FIG. 1, there is depicted a block diagram of a computing device in which a preferred embodiment of the present invention is incorporated. As shown, a computing device 100 includes a processing unit 102 and a memory 104. Memory 104 includes a volatile memory (such as a random access memory) and a non-volatile memory (such as a read-only memory). Computing device 100 also contains removable storage media devices 108, such as compact discs, optical disks, magnetic tapes, etc., and non-removable storage devices 110, such as hard drives. In addition, computing device 100 may contain communication channels 112 for providing communications with other systems on a computer network 120. Computing device 100 also includes input components 114 such as a keyboard, mouse, etc., and output components 116 such as displays, speakers, printers, etc.


In accordance with a preferred embodiment of the present invention, a Trusted Platform Module (TPM) is used in conjunction with modifications to a basic input/output system (BIOS) for providing protection to an encryption key generated by the syskey utility intended to be used for the encryption of a Security Accounts Manager (SAM) file within a Windows® operating system. The TPM allows secure generation of cryptographic keys, and limits the use of those keys to either signing/verification or encryption/decryption, as it is known to those skilled in the art. There are three main components to the method of the present invention, namely, setup, boot up and recovery.


Setup Process

With reference now to FIG. 2, there is depicted a high-level logic flow diagram of a method for setting up a computer for protecting a SAM file within a Windows® operating system, in accordance with a preferred embodiment of the present invention. Starting at block 200, a Trusted Platform Module (TPM) within the computer is enabled and configured using methods that are known to those skilled in the art, as shown in block 210. In addition, a virtual floppy disk device driver that emulates the presence of a physical floppy drive is installed, as depicted in block 220. Instead of requiring the presence of a physical floppy drive, the virtual floppy disk device driver basically causes the data to be written to a system memory.


A SAM file encryption key is generated by encrypting a SAM file with a 128-bit key (16 bytes) via the syskey utility provided within the Windows® operating system, as shown in block 230. The SAM file encryption key is then written to the virtual floppy disk (instead of a physical floppy disk) by selecting the option to store the SAM file encryption key to a floppy disk in the syskey utility, as depicted in block 240.


Next, a 256-byte blob is generated based on the SAM file encryption key, as shown in block 250. The 256-byte blob of data is generated by reading the SAM file encryption key from the virtual floppy disk and by performing a TPM Seal command against the SAM file encryption key along with the value stored in the register 0 of a Platform Configuration Register (PCR) and a TPM Storage Root Key (SRK). The 256-byte blob is then passed to the BIOS for storage in a non-volatile storage area of the computer, such as a flash memory or a hard disk drive, as depicted block 260.


Because the protection of the SAM file encryption key is tied to the TPM SRK, there must be a recovery mechanism for the SAM file encryption key in case the motherboard is replaced or the TPM security chip is cleared. For such purpose, the SAM file encryption key must also be encrypted via some other mechanism. Thus, the SAM file encryption key is encrypted using an Advanced Encryption Standard (AES) key derived from the administrator password within the Windows® operating system to generate a second encrypted blob, as shown in block 270. The second encrypted blob can be stored on a removable storage media, such as a floppy disk, a universal serial bus (USB) key, etc., as depicted in block 280. The removable storage media is then removed from the computer system, as shown in block 290.


Normal Boot Process

Referring now to FIG. 3, there is shown a high-level logic flow diagram of a method of performing a system boot up after the setup process (from FIG. 2) has been completed, in accordance with a preferred embodiment of the present invention. A TPM Unseal command is performed on the 256-byte blob against the value of the register 0 within the PCR (i.e., PCR 0) to retrieve the SAM file encryption key during power on self-test (POST), as shown in block 300. This is performed when the BIOS comes out of the boot block. The BIOS holds the SAM file encryption key in the system memory until it is needed, as depicted in block 310.


When the SAM file encryption key is needed during the system boot up, the BIOS the “tricks” the Windows® operating system into thinking it is reading the SAM file encryption key from a physical floppy disk drive. To this end, an INT 13h handler is utilized to present a virtual floppy drive to the Windows® operating system, as shown in block 320. Once the BIOS knows that the computer is booting from the hard drive, the INT 13h handler then traps the read request number to the floppy disk drive, and returns the SAM file encryption key to the Windows® operating system, as depicted in block 330.


The Windows® operating system is now able to decrypt the SAM file using the encryption key returned by the BIOS, and the Windows® operating system is loaded and continues as normal, as shown in block 340. The SAM file encryption key is no longer needed by the BIOS so the SAM file encryption key should be cleared from the system memory, as depicted in block 350.


Recovery Process

With reference now to FIG. 4, there is depicted a high-level logic flow diagram of a method for performing a system boot up using the backup key, in accordance with a preferred embodiment of the present invention. Starting at block 400, an administrator, who would like to perform a system boot after a motherboard replacement, boots the computer system via Windows PE, as shown in block 410, which does not require the SAM file encryption key. From Windows PE, the second encrypted blob (i.e., copy of the SAM file encryption key that was encrypted by the administrator password in block 270 of FIG. 2) is retrieved from its storage location and passed to the BIOS for retrieval on its next boot, as depicted in block 420. A flag is also written to let the BIOS know that the second encrypted blob is associated with the administrator password and not the TPM, as shown in block 430.


On reboot, the BIOS reads the second encrypted blob, and since there is a flag indicating that the second encrypted key was encrypted with the administrator password, the BIOS prompts for the administrator password, as depicted in block 440. The administrator password is then used to decrypt the SAM file encryption key, as shown in block 450. The INT 13h handler subsequently passes the SAM file encryption key to the Windows® operating system as described in the normal boot process (blocks 320-330 of FIG. 2).


After the Windows® operating system has been loaded, the TPM recovery process is run to enable the TPM and/or generate the SRK on the motherboard as needed, as depicted in block 460. Once the new SRK has been generated, the recovery process under the Windows® operating system can either re-generate the file encryption key, or decrypt the archive version of the SAM file encryption key using the administrator password, and re-seal it to the new SRK as described above.


The flag indicating that the BIOS is using a password-encrypted version of the key (from block 430) should be cleared, as shown in block 470, so that the BIOS knows that it is using the TPM-protected version of the SAM file encryption key from this point on, so that the normal boot process can be executed during subsequent boots.


As has been described, the present invention provides an improved method for protecting a SAM file within a Windows® operating system. The present invention improves upon the current methods of protecting SAM files provided by the Windows® operating system.


It is also important to note that although the present invention has been described in the context of a fully functional computer system, those skilled in the art will appreciate that the mechanisms of the present invention are capable of being distributed as a program product in a variety of forms, and that the present invention applies equally regardless of the particular type of signal bearing media utilized to actually carry out the distribution. Examples of signal bearing media include, without limitation, recordable type media such as floppy disks or compact discs and transmission type media such as analog or digital communications links.


While the invention has been particularly shown and described with reference to a preferred embodiment, it will be understood by those skilled in the art that various changes in form and detail may be made therein without departing from the spirit and scope of the invention.

Claims
  • 1. A method for protecting a Security Accounts Manager (SAM) file within a Windows® operating system, said method comprising: generating a SAM file encryption key by encrypting a SAM file via a syskey utility provided within said Windows® operating system;storing said SAM file encryption key to a virtual floppy disk by selecting an option to store SAM file encryption key to a floppy disk under said syskey utility;generating a blob based on said SAM file encryption key by performing a Trusted Platform Module (TPM) Seal command against said SAM file encryption key along with a value stored in a Performance Control Register and a TPM Storage Root Key; andstoring said blob in a non-volatile storage device of a computer.
  • 2. The method of claim 1, wherein said method further includes providing a TPM within said computer.
  • 3. The method of claim 2, wherein said method further includes providing a virtual floppy disk device driver within said computer.
  • 4. The method of claim 1, wherein said method further includes retrieving said SAM file encryption key during Power On Self-Test by performing a TPM Unseal command on said blob against said value of stored in said Performance Control Register; andproviding said SAM file encryption key to a Basic Input/Output System during system boot up via an INT 13h handler.
  • 5. The method of claim 1, wherein said method further includes generating a backup blob by encrypting said SAM file encryption key via an Advanced Encryption Standard key derived from an administrator password; andstoring said backup blob in a removable storage medium.
  • 6. A computer usable medium having a computer program product for protecting Security Accounts Manager (SAM) files within a Windows® operating system, said computer usable medium comprising: program code means for generating a SAM file encryption key by encrypting a SAM file via a syskey utility provided within said Windows® operating system;program code means for storing said SAM file encryption key to a virtual floppy disk by selecting an option to store SAM file encryption key to a floppy disk under said syskey utility;program code means for generating a blob based on said SAM file encryption key by performing a Trusted Platform Module (TPM) Seal command against said SAM file encryption key along with a value stored in a Performance Control Register and a TPM Storage Root Key; andprogram code means for storing said blob in a non-volatile storage device of a computer.
  • 7. The computer usable medium of claim 6, wherein said computer usable medium further includes program code means for initiating a TPM within said computer.
  • 8. The computer usable medium of claim 7, wherein said computer usable medium further includes program code means for providing a virtual floppy disk device driver within said computer.
  • 9. The computer usable medium of claim 6, wherein said computer usable medium further includes program code means for retrieving said SAM file encryption key during Power On Self-Test by performing a TPM Unseal command on said blob against said value of stored in said Performance Control Register; andprogram code means for providing said SAM file encryption key to a Basic Input/Output System during system boot up via an TNT 13h handler.
  • 10. The computer usable medium of claim 6, wherein said computer usable medium further includes program code means for generating a backup blob by encrypting said SAM file encryption key via an Advanced Encryption Standard key derived from an administrator password; andprogram code means for storing said backup blob in a removable storage medium.
  • 11. A computer system capable of protecting Security Accounts Manager (SAM) files within a Windows® operating systems, said computer system comprising: means for generating a SAM file encryption key by encrypting a SAM file via a syskey utility provided within said Windows® operating system;a virtual floppy disk for storing said SAM file encryption key by selecting an option to store SAM file encryption key to a floppy disk under said syskey utility;means for generating a blob based on said SAM file encryption key by performing a Trusted Platform Module (TPM) Seal command against said SAM file encryption key along with a value stored in a Performance Control Register and a TPM Storage Root Key; anda non-volatile storage device for storing said blob.
  • 12. The computer system of claim 11, wherein said computer system further includes a TPM.
  • 13. The computer system of claim 12, wherein said computer system further includes virtual floppy disk device driver.
  • 14. The computer system of claim 11, wherein said computer system further includes means for retrieving said SAM file encryption key during Power On Self-Test by performing a TPM Unseal command on said blob against said value of stored in said Performance Control Register; andan INT 13h handler for providing said SAM file encryption key to a Basic Input/Output System during system boot up.
  • 15. The computer system of claim 6, wherein said computer system further includes an Advanced Encryption Standard key derived from an administrator password for encrypting said SAM file encryption key to generate a backup blob; anda removable storage medium for storing said backup blob.