The technical field relates generally to secure storage of information, and more specifically to detecting attempts to tamper a trusted store.
A trusted store is a storage location in which contents stored therein are secure or protected. In computing systems for example, a trusted store can be a portion of memory located in a computer. Security is typically provided by encrypting the information stored in the trusted store and/or obfuscating the location of the trusted store. It is not uncommon for licensed applications to utilize a trusted store to prevent tampering of license conditions, such as licensed operation systems, for example. Or in another example, a user can download a free trial offer of song from a network under the condition that the user will be able to listen to the song for a limited amount of time (e.g., 24 hours) without purchasing the song. The conditions limiting the user's use of the song to 24 hours are stored in a trusted store. The intent is to prevent the user, or any unauthorized person, from tampering with the conditions and thus obtaining unlimited use of the song.
A common tactic for compromising a trusted store is to replace files in the trusted store with old versions of the same files or with files from another system. Thus, in the above example, the user could simply download as many songs as desired and copy the trusted store during each download. The user could then load the original version of the trusted store each time the user wants to play a song. The system would be fooled into thinking that the 24 hour grace period is just beginning. This tactic defeats the purpose of the trusted store.
A trusted store comprises a security flag that can be verified to provide an indication of tampering of the trusted store. A security flag is indicative of the creation of the security flag and of the version of the trusted store. A security flag is created when the trusted store is created. A security flag also can be created by components writing to the trusted store. Each time a critical event occurs, the appropriate security flag is updated to indicate the occurrence thereof. Security flags also are stored in another portion of memory. At appropriate times, the security flag stored in the trusted store is compared with the corresponding security flag stored in the other portion of memory. If the security flags match (within a predetermined tolerance), it is determined that the trusted store has not been tampered with. If the security flags do not match, it is determined that the trusted store has been tampered with. If a security flag is missing from either the trusted store or the other portion of memory, it is determined that the trusted store has been tampered with.
The following description is better understood when read in conjunction with the appended drawings. For purposes of illustrating means for determining if a trusted store has been subjected to tampering, there are shown in the drawings exemplary constructions thereof; however, means for determining if a trusted store has been subjected to tampering is not limited to the specific methods and instrumentalities disclosed. In the drawings:
A security flag is stored in trusted store to aid in determining if the trusted store has been subjected to tampering. The security flag comprises a globally unique identifier (GUID) that is created when the security flag is created. The GUID uniquely identifies the system in which the security flag is being utilized. The security flag also comprises an indication of the version of the trusted store. This can be in the form of any appropriate value, for example a value determined by the date of creation of the trusted store. The security flag further comprises a counter that is incremented each time a selected event occurs.
The security flag is stored in the trusted store. The security flag is also stored in another portion of memory, such as write-once portion of a registry. A write-once portion of a registry is a portion of a registry that becomes read only after the system is booted. Thus, contents can be written into the write-once portion of the registry, but the contents of the write-once portion of the registry can not be deleted or changed. When predetermined events occur, such as the creation of a trusted store, the addition of a timer, or the addition of activation keys, for example, a security flag is created to indicate that a predetermined event has occurred. The security flag also is stored in the write-once portion of the registry. When a selected event occurs, such as activation of a license for example, the security flag from the trusted store is compared with the security flag stored in the write-once registry. If the security flags match (within tolerance), it is determined that the trusted store has not been subjected to tampering. If the security flags do not match, or if there are not two security flags to compare, it is determined that the trusted store has been subjected to tampering.
A computing system typically comprises a registry. In an exemplary embodiment, the registry 20 contains setting and other information used by an operating system. In an exemplary embodiment, the write-once registry 14 is a portion of the registry 20. The write-once registry 14 is a portion of the registry 20 that becomes read only after the system is booted or powered up. Contents can be written into the write-once registry 14, but the contents of the write-once registry 14 can not be deleted or changed. In an exemplary embodiment, the trusted store 12, the registry 20, and the write-once registry 14 are portions of a computing system running a WINDOWS® operating system.
The security flag 16 is stored in the trusted store 12. The security flag 16 can be stored in any appropriate portion of the trusted store 12. In an exemplary embodiment, the security flag 16 is stored in a header portion of the trusted store 16. The security flag 18 is stored in the registry 20. The security flag 18 can be stored in any appropriate portion of the registry 20. In an exemplary the security flag 18 is stored in the write-once registry 14. Thus, each time the security flag 18 is written into the write-once registry 14, it can not be erased. If the trusted store 12 has not been tampered with, it is envisioned that the security flag 16 will be the same as the security flag 18. But, differences can exist between the security flag 16 and the security flag 18 for reasons other than tampering. For example, the computing system can change the format of the security flag 18 when storing it in the write-once registry 14. Or, the computing system can store the security flag 18 in a different locations and types of memory than the security flag 16. Further, it is envisioned that the security flag 16 and the security flag 18 can be stored in different systems. If the trusted store 12 has not been tampered with, the security flag 16 and the security flag 18 will be indicative of the same information.
The version of the trusted store is a value indicative of the current version of the trusted store in which the security flag is stored. The version of the trusted store is created, in part, by using the date and time when the trusted store is loaded into memory. The version is created when the trusted store files are created as part of building an operating system. Each release of the trusted store will result in the version number being incremented. Each time an operating system is updated, the version of the trusted store is incremented.
In an exemplary embodiment, the counter is incremented when critical events occur, such as the creation of a new security flag. For example a new security flag is created when a new timer (e.g., a WINDOWS® timer) is added, when a new timer is created, when an activation key is added, or when the system is recovering from an in-tolerance discrepancy. The entire flag is update each time a update event occurs.
When a security flag is created it is stored in the trusted store and in the write-once registry. If the trusted store is tampered with, such as replacing files in the trusted stores with older versions of the files, the tampered with version of the trusted store will not contain the security flag. Or, the tampered with version of the trusted store will contain a different security flag, or an older security flag. In either case, a comparison of the security flag stored in the trusted store with the security flag stored in the write-once registry will indicate that tampering has occurred.
If a security flag is found in the trusted store (step 52), the security flag from the write-once registry is obtained at step 56. If no security flag is found in the write-once registry (step 58), it is determined, at step 60, that tampering has occurred. If a security flag is found in the write-once registry (step 58), the security flags obtained from the trusted store (step 50) and from the write-once registry (56) are parsed at step 62. The respective portions of each security flag are compared at step 64. If either of the security flags was encrypted, the encrypted security flag(s) is decrypted prior to comparison. If any of the respective portions do not match (step 66), it is determined at step 68 that tampering has occurred. If the respective portions of the security flags match (step 66), it is determined at step 70 that no tampering has occurred. Respective portions match if they each are indicative of the same information.
In an exemplary embodiment, when the respective portions of the security flags indicative of counters are compared, some tolerance is accepted. For example, if a failure, such as a system crash or power failure, occurs during the process of writing the security flag to the write-once registry, the next time the security flags from the trusted store and the write-once registry are compared, the counter values will be one increment different. To compensate for this type of failure, in an exemplary embodiment, if the value of the counter in the trusted store is one increment greater than the value of the counter in the write-once registry, it is considered a match. For example, if the counter value in the trusted store is equal to N and the counter value in the write-once registry is equal to N−1, it is considered a match, and it is determined that no tampering has occurred.
The means described herein for determining if the trusted store (or the write-once registry) has been subjected to tampering is applicable to various scenarios. For example tampering in the form of replacing files in the trusted store with alternate files can be detected. Deletion of the trusted store or files within the trusted store can be detected. Loading a trusted store in a different machine can be detected via the GUID. Further, the means is tolerant to limited clock skew. This means also prevents replay attacks. When an application creates a timer, a security flag is created. If someone tries to replay the trusted store in order to delete the timer, a security flag mismatch will occur, indicating that tampering has occurred.
While exemplary embodiments of means for determining if a trusted store has been subjected to tampering have been described in connection with various computing devices, the underlying concepts can be applied to any computing device or system capable of determining if a trusted store has been subjected to tampering.
With reference to
The computer 110 typically includes a variety of computer readable media. Computer readable media can be any available media that can be accessed by the computer 110 and includes both volatile and nonvolatile media, and removable and non-removable media. By way of example, and not limitation, computer readable media may comprise computer storage media and communication media. Computer storage media includes volatile and nonvolatile, removable and non-removable media implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data. Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disks (DVD) or other optical disk storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other medium which can be used to store the desired information and which can be accessed by the computer 110. Communication media typically embodies computer readable instructions, data structures, program modules or other data in a modulated data signal such as a carrier wave or other transport mechanism and includes any information delivery media. The term “modulated data signal” means a signal that has one or more of its characteristics set or changed in such a manner as to encode information in the signal. By way of example, and not limitation, communication media includes wired media such as a wired network or direct-wired connection, and wireless media such as acoustic, RF, infrared and other wireless media. Combinations of the any of the above should also be included within the scope of computer readable media.
The system memory 130 includes computer storage media in the form of volatile and/or nonvolatile memory such as read only memory (ROM) 131 and random access memory (RAM) 132. A basic input/output system 133 (BIOS), containing the basic routines that help to transfer information between elements within computer 110, such as during start-up, is typically stored in ROM 131. RAM 132 typically contains data and/or program modules that are immediately accessible to and/or presently being operated on by processing unit 120. By way of example, and not limitation,
The computer 110 may also include other removable/non-removable, volatile/nonvolatile computer storage media. By way of example only,
The drives and their associated computer storage media, discussed above and illustrated in
The computer 110 may operate in a networked environment using logical connections to one or more remote computers, such as a remote computer 180. The remote computer 180 may be a personal computer, a server, a router, a network PC, a peer device or other common network node, and typically includes many or all of the elements described above relative to the computer 110, although only a memory storage device 181 has been illustrated in
When used in a LAN networking environment, the computer 110 is connected to the LAN 171 through a network interface or adapter 170. When used in a WAN networking environment, the computer 110 typically includes a modem 172 or other means for establishing communications over the WAN 173, such as the Internet. The modem 172, which may be internal or external, may be connected to the system bus 121 via the user input interface 160 or other appropriate mechanism. In a networked environment, program modules depicted relative to the computer 110, or portions thereof, may be stored in the remote memory storage device. By way of example, and not limitation,
The various techniques described herein can be implemented in connection with hardware or software or, where appropriate, with a combination of both. Thus, the methods and apparatus for determining if a trusted store has been subjected to tampering, or certain aspects or portions thereof, can take the form of program code (i.e., instructions) embodied in tangible media, such as floppy diskettes, CD-ROMs, hard drives, or any other machine-readable storage medium, wherein, when the program code is loaded into and executed by a machine, such as a computer, the machine becomes an apparatus for determining if a trusted store has been subjected to tampering. In the case of program code execution on programmable computers, the computing device will generally include a processor, a storage medium readable by the processor (including volatile and non-volatile memory and/or storage elements), at least one input device, and at least one output device. The program(s) can be implemented in assembly or machine language, if desired. In any case, the language can be a compiled or interpreted language, and combined with hardware implementations.
The methods and apparatus for determining if a trusted store has been subjected to tampering also can be practiced via communications embodied in the form of program code that is transmitted over some transmission medium, such as over electrical wiring or cabling, through fiber optics, or via any other form of transmission, wherein, when the program code is received and loaded into and executed by a machine, such as an EPROM, a gate array, a programmable logic device (PLD), a client computer, or the like, the machine becomes an apparatus for practicing a method for determining if a trusted store has been subjected to tampering. When implemented on a general-purpose processor, the program code combines with the processor to provide a unique apparatus that operates to invoke the functionality of means for determining if a trusted store has been subjected to tampering. Additionally, any storage techniques used in connection with means for determining if a trusted store has been subjected to tampering can invariably be a combination of hardware and software.
Means for determining if a trusted store has been subjected to tampering typically includes at least some form of computer readable media. Computer readable media can be any available media that can be accessed by means for determining if a trusted store has been subjected to tampering. By way of example, and not limitation, computer readable media may comprise computer storage media and communication media. Computer storage media includes volatile and nonvolatile, removable and non-removable media implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data. Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disks (DVD) or other optical storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other medium which can be used to store the desired information and which can accessed by means for determining if a trusted store has been subjected to tampering. Communication media typically embodies computer readable instructions, data structures, program modules or other data in a modulated data signal such as a carrier wave or other transport mechanism and includes any information delivery media. The term “modulated data signal” means a signal that has one or more of its characteristics set or changed in such a manner as to encode information in the signal. By way of example, and not limitation, communication media includes wired media such as a wired network or direct-wired connection, and wireless media such as acoustic, RF, infrared and other wireless media. Combinations of the any of the above should also be included within the scope of computer readable media.
While means for determining if a trusted store has been subjected to tampering have been described in connection with the exemplary embodiments of the various figures, it is to be understood that other similar embodiments can be used or modifications and additions can be made to the described embodiments for performing the same functions of means for determining if a trusted store has been subjected to tampering without deviating therefrom. Therefore, means for determining if a trusted store has been subjected to tampering as described herein should not be limited to any single embodiment, but rather should be construed in breadth and scope in accordance with the appended claims.