US20220350609A1 - Protection Against Timing-based Security Attacks on Re-order Buffers - Google Patents

Protection Against Timing-based Security Attacks on Re-order Buffers Download PDF

Info

Publication number
US20220350609A1
US20220350609A1 US17/866,868 US202217866868A US2022350609A1 US 20220350609 A1 US20220350609 A1 US 20220350609A1 US 202217866868 A US202217866868 A US 202217866868A US 2022350609 A1 US2022350609 A1 US 2022350609A1
Authority
US
United States
Prior art keywords
buffer
order
instructions
controller
processor
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
US17/866,868
Inventor
Steven Jeffrey Wallach
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Micron Technology Inc
Original Assignee
Micron Technology Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Micron Technology Inc filed Critical Micron Technology Inc
Priority to US17/866,868 priority Critical patent/US20220350609A1/en
Assigned to MICRON TECHNOLOGY, INC. reassignment MICRON TECHNOLOGY, INC. ASSIGNMENT OF ASSIGNORS INTEREST (SEE DOCUMENT FOR DETAILS). Assignors: WALLACH, STEVEN JEFFREY
Publication of US20220350609A1 publication Critical patent/US20220350609A1/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/38Concurrent instruction execution, e.g. pipeline or look ahead
    • G06F9/3854Instruction completion, e.g. retiring, committing or graduating
    • G06F9/3856Reordering of instructions, e.g. using queues or age tags
    • G06F9/3855
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/70Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer
    • G06F21/71Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer to assure secure computing or processing of information
    • G06F21/75Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer to assure secure computing or processing of information by inhibiting the analysis of circuitry or operation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/50Monitoring users, programs or devices to maintain the integrity of platforms, e.g. of processors, firmware or operating systems
    • G06F21/55Detecting local intrusion or implementing counter-measures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/50Monitoring users, programs or devices to maintain the integrity of platforms, e.g. of processors, firmware or operating systems
    • G06F21/52Monitoring users, programs or devices to maintain the integrity of platforms, e.g. of processors, firmware or operating systems during program execution, e.g. stack integrity ; Preventing unwanted data erasure; Buffer overflow
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/70Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer
    • G06F21/71Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer to assure secure computing or processing of information
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/38Concurrent instruction execution, e.g. pipeline or look ahead
    • G06F9/3802Instruction prefetching
    • G06F9/3814Implementation provisions of instruction buffers, e.g. prefetch buffer; banks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/38Concurrent instruction execution, e.g. pipeline or look ahead
    • G06F9/3836Instruction issuing, e.g. dynamic instruction scheduling or out of order instruction execution
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2205/00Indexing scheme relating to group G06F5/00; Methods or arrangements for data conversion without changing the order or content of the data handled
    • G06F2205/06Indexing scheme relating to groups G06F5/06 - G06F5/16
    • G06F2205/063Dynamically variable buffer size

Definitions

  • At least some embodiments disclosed herein relate generally to computer architecture and more specifically, but not limited to, techniques to protect against security attacks on re-order buffers.
  • Instructions are typically programmed to be executed sequentially.
  • a program order of instructions is the order in which the instructions are programmed for execution in a processor.
  • Out-of-order execution have been implemented in some processors to improve the utilization of the processing power of the processors and increase the overall speed of executing a program having a sequence of instructions.
  • the operand when the processor is about to process an instruction that is configured to operate on an operand, the operand may be in the process of being loaded from a cache, or a main memory, or a storage device. However, the operand of the next instruction in the program order may be ready for processing in the processor. Thus, the processor may execute the next instruction, instead of pausing the execution of instructions to wait for the operand that is being loaded from the cache, the main memory, or the storage device.
  • a “data order” of instructions is the order in which the data or operands of the instructions become available in the processor for processing.
  • the data order is typically different from the program order in contemporary processor design.
  • a processor can be configured to execute instructions according to the data order of the instructions, instead of the program order of the instructions.
  • a re-order buffer can be used to temporally hold the execution results of instructions that are executed out of their program order.
  • the instructions can be executed in the data order of the instructions.
  • the results stored in the re-order buffer can be moved out of the re-order buffer in the program order of the respective instructions, as if the results were generated by executing the instructions according to the program order.
  • a sequence of 3 instructions can be a first instruction to load an operand A into a first register (e.g., “load A, r1”), a second instruction to load another operand B into a second register (e.g., “load B, r2”), and a third instruction to add a number to the second register (e.g., “add #1, r2”).
  • the instructions can be executed in the order of “load B, r2”, “add #1, r2”, and “load A, r1”, which is different from the program order of “load A, r1”, “load B, r2”, and “add #1, r2”.
  • Implementations of out-of-order execution may have security vulnerability.
  • security vulnerabilities in computer processors include Meltdown and Spectre that were made public in 2018.
  • security vulnerabilities may allow data to be cached from a privileged security boundary, resulting in a race condition that could be timed to leak privileged information.
  • An example of data in a privileged security boundary is data located in the operating system kernel.
  • FIG. 1 shows a buffer controller configured to protect against timing-based security attacks on a re-order buffer according to one embodiment.
  • FIG. 2 shows an out-of-order execution controlled by a buffer capacity controller according to one embodiment.
  • FIG. 3 shows a method to protect against timing-based security attacks on re-order buffers according to one embodiment.
  • FIG. 4 show a computing system in which the method of FIG. 3 can be implemented.
  • the present disclosure includes techniques for protection against timing-based security attacks on re-order buffers.
  • a timing-based security attack relies upon a timing pattern of results in a re-order buffer. Such an attack can be prevented and/or made difficult to implement by randomizing the timing pattern of results in re-order buffers.
  • the timing pattern of results in a re-order buffer can be dependent on the operating capacity of the re-order buffer.
  • the actual/operating capacity of the re-order buffer usable to re-order results of instructions that are executed out of their program order can be changed randomly from time to time such that the timing pattern changes from time to time.
  • Such a capacity adjustment can be performed randomly in time, or periodically, to introduce randomness in the timing of the results in the re-order buffer.
  • FIG. 1 shows a buffer controller ( 115 ) configured to protect against timing-based security attacks on a re-order buffer ( 113 ) according to one embodiment.
  • the buffer controller ( 115 ) can be implemented in a processor of a computer system illustrated in FIG. 4 .
  • the re-order buffer ( 113 ) is configured to receive results of instructions in an order in which instructions are executed.
  • the results in the re-order buffer ( 113 ) can be moved out of the re-order buffer ( 113 ) for committing into a register file of a processor (e.g., 181 in FIG. 4 ), a cache memory of the processor, and/or a memory external to the processor, based on a “graduation order.”
  • the graduation order of the results in the re-order buffer ( 113 ) for instructions is the order in which the results of the instructions are committed and the instructions are retired for completion; and the graduation order (retirement order, or commitment order) is typically configured to be consistent with the program order of the instructions.
  • the execution result of an instruction that is to be executed early in the program order is to be graduate from the re-order buffer ( 113 ) early.
  • a result of an instruction can be moved out of the re-order buffer ( 113 ) for committing when the results of instructions programmed before the instruction in the program order are ready to be moved out of the re-order buffer ( 113 ) for committing.
  • some instructions can be executed in parallel units, threads or pipelines; and the graduation order (retirement order, or commitment order) from the re-order buffer ( 113 ) preserves sequential consistency.
  • sequential consistency requires that the result of any execution is the same as if the instructions were executed in a sequential order specified by its program.
  • Commitment or committing to a register may be referred to as writing to a register. So results may be committed to a register by a processor configured to write the results to the register.
  • the capacity of the re-order buffer ( 113 ) determines the depth of a sequence of instructions that can be executed out of order before a result can graduate from the re-order buffer ( 113 ).
  • a same set of instructions executed using re-order buffers (e.g., 113 ) of different capacities can have different timings of results buffering in the re-order buffer ( 113 ).
  • changing the capacity of the re-order buffer ( 113 ) can change the pattern of out of order of executions.
  • Randomizing the change in the capacity of the re-order buffer ( 113 ) can introduce randomness in data timing in the re-order buffer ( 113 ) and thus remove the predictability of timing in the re-order buffer ( 113 ) and defeat or prevent timing-based security attacks on the re-order buffer ( 113 ).
  • the re-order buffer ( 113 ) has a predetermined full capacity.
  • the buffer controller ( 115 ) identifies a usable capacity of the re-order buffer ( 113 ) for sorting the incoming results ( 111 ) that are provided in the order of actual execution/completion of instructions.
  • the usable capacity identified by the buffer controller ( 115 ) is reached, the out-of-order execution of instructions beyond the set of instructions for each the re-order buffer ( 113 ) can buffer their results is prevented, until some of the results in the re-order buffer graduate from the re-order buffer ( 113 ).
  • the usable capacity of the re-order buffer ( 113 ) can be a random fraction of the predetermined full capacity of the re-order buffer ( 113 ).
  • the randomness in usable capacity of the re-order buffer ( 113 ) can destroy or weaken the predictability of timing of the re-order buffer ( 113 ) and thus protect against timing-based security attack on the re-order buffer ( 113 ).
  • the re-order buffer ( 113 ) can have a dynamically allocated amount of capacity for sorting the results in execution order ( 111 ) into the results in graduation order ( 117 ).
  • the buffer controller ( 115 ) controls the dynamic allocation of the capacity for the re-order buffer ( 113 ) (e.g., based on the output of a random number generator).
  • multiple processing cores can have multiple re-order buffers (e.g., 113 ) respectively.
  • a buffer controller ( 115 ) can dynamically re-allocate a shared buffer capacity for the multiple re-order buffers (e.g., 113 ). For example, instead of evenly dividing the shared buffer capacity among the multiple re-order buffers (e.g., 113 ), the buffer controller ( 115 ) can randomize the ratios of capacity allocations among the multiple re-order buffers (e.g., 113 ) to cause randomness in timing.
  • the buffer controller ( 115 ) re-configures the usable capacity of the re-order buffer ( 113 ) periodically at a regular, predetermined time interval.
  • a usable capacity can be configured for the re-order buffer ( 113 ) for a random time period of operation; and after the random time period of operation, the usable capacity of the re-order buffer ( 113 ) can be reconfigured for another random period of operations.
  • Time periods of operation may be referred to as, e.g., a first period of time and a second period of time following the first period of time.
  • the randomness in the lengths of periods of operation at two or more constant usable capacities can also reduce or destroy the timing predictability in the re-order buffer ( 113 ).
  • FIG. 2 shows an out-of-order execution controlled by a buffer capacity controller ( 114 ) according to one embodiment.
  • the buffer controller ( 115 ) of FIG. 1 can be implemented using the buffer capacity controller ( 114 ) of FIG. 2 with a random number generator ( 116 ) to randomize out-of-order execution of instructions.
  • the random number generator ( 116 ) can be configured to prevent an attacker from detecting the sequence of outputs generated from the random number generator ( 116 ) and/or its algorithm for generating randomized outputs.
  • statistically random noises on computer buses can be used in the random number generator ( 116 ) to prevent an attacker from accurately predicting the outputs of the random number generator ( 116 ). Electrical noises in general cannot be modeled accurately.
  • instructions ( 101 ) fetched according to the program order of the instructions are buffered in the instruction buffer ( 103 ).
  • the instructions ( 101 ) can be fetched from a cache memory of a processor, from a memory of a computer system, and/or a storage device of the computer system (e.g., as illustrated in FIG. 6 ).
  • the instructions in the instruction buffer ( 103 ) can be executed in functional units ( 109 ) of the processor when the data/operands ( 107 ) of the instructions are available to the functional units.
  • some of the data operands ( 107 ) of the instructions may be loaded from a cache memory of the processor, from the memory of the computer system, and/or from the storage device of the computer system (e.g., illustrated in FIG. 6 ).
  • Other data operands ( 107 ) of the instructions can be the results of the executions of other instructions. Such results may be available in registers/register files of the processor and/or in the re-order buffer ( 113 ).
  • Loading certain data items can take a time period that is longer than the processing of one or more data-ready instructions.
  • the data/operands ( 107 ) of data-ready instructions can be used by the functional units ( 109 ) in a short time period.
  • data-ready instructions ( 105 ) in the instruction buffer ( 103 ) can be issued to functional units ( 109 ) for execution according to a data order that is different from the program order.
  • the functional units ( 109 ) generates results ( 111 ) in an order of execution/completion of instructions; and the results ( 111 ) are temporally stored in the re-order buffer ( 113 ) for their graduation.
  • a result of each respective instruction can graduate/retire/be committed from the re-order buffer ( 113 ) when the results of instructions before the respective instruction are in the re-order buffer ( 113 ) and ready for graduation, or have already graduated from the re-order buffer ( 113 ).
  • Results ( 117 ) in the graduation order which is consistent with the program order of their instructions ( 101 ), can be moved out of the re-order buffer ( 113 ) for committing into registers (register files, a cache, a main memory, and/or a storage device) ( 119 ).
  • the timing of the results ( 111 ) in the re-order buffer ( 113 ) for a given set of instructions may be predicted, determined, and/or exploited by a security attack to gain unauthorized knowledge about the execution of instructions and/or their data.
  • the buffer capacity controller ( 114 ) can inject randomness in the timing by randomizing the usable capacity of the re-order buffer ( 113 ) in sorting the results ( 111 / 117 ).
  • the buffer capacity controller ( 114 ) can include, or be coupled to, a random number generator ( 116 ).
  • the output of the random number generator ( 116 ) can be used in the buffer capacity controller ( 114 ) to determine a limit of usable portion of the re-order buffer ( 113 ) in sorting the results ( 111 / 117 ).
  • the buffer capacity controller ( 114 ) can determine an adjustment to the usable portion of the re-order buffer ( 113 ) in sorting the results ( 111 / 117 ).
  • the adjustment can be made via adding dummy results into the re-order buffer ( 113 ), or removing dummy results that have been previously added to the re-order buffer ( 113 ).
  • the dummy results added into the front or the back of the queue (or another location) in the re-order buffer ( 113 ) effectively reduces the usable portion of the re-order buffer ( 113 ) for sorting the results ( 111 / 117 ).
  • the output of the random number generator ( 116 ) can be converted to a count of dummy results to be kept in the re-order buffer ( 113 ) for a next time period of operations of the re-order buffer.
  • the count of dummy results corresponds to a fraction of the full capacity of the re-order buffer ( 113 ). If the current count of dummy results in the re-order buffer ( 113 ) is larger than the desired count converted from the output of the random number generator ( 116 ), the buffer capacity controller ( 114 ) removes one or more dummy results from the re-order buffer ( 113 ), as if the dummy results were to graduate from the re-order buffer ( 113 ).
  • the buffer capacity controller ( 114 ) adds one or more dummy results to the re-order buffer ( 113 ) (e.g., in the slots vacated by the results ( 117 ) that recently graduate from the re-order buffer ( 113 )), as if the dummy results were generated by the functional units ( 109 ) as a result of executing dummy instructions.
  • the buffer capacity controller ( 114 ) can be configured to adjust, according to the random number generator ( 116 ), one or more boundaries of the re-order buffer ( 113 ) that define the capacity of the buffer capacity controller ( 114 ).
  • the output of the random number generator ( 116 ) controls when the buffer capacity controller ( 114 ) adjusts the usable capacity of the re-order buffer ( 113 ).
  • the output of the random number generator ( 116 ) can be used to set a threshold count of cycles of operations of the re-order buffer between two successive adjustments. After the threshold count of cycles of operations following a prior adjustment, the buffer capacity controller ( 114 ) can adjust again the capacity of the re-order buffer ( 113 ).
  • Cycles of operations of the re-order buffer can be counted based on a predetermined number of instruction cycles (or clock cycles) of the processor in one embodiment.
  • a cycle of operations can be counted as being between two successive graduations of result sets ( 117 ) from the re-order buffer ( 113 ).
  • the length of the cycle may not be a constant relative to a clock cycle and/or an instruction cycle.
  • FIG. 3 shows a method to protect against timing-based security attacks on re-order buffers according to one embodiment.
  • the method of FIG. 3 can be implemented using the buffer controller ( 115 ) of FIG. 1 or the buffer capacity controller ( 114 ) of FIG. 2 .
  • a processor executes instructions in an order that is different from a program order in which the instructions are programmed.
  • the processor can execute the instructions according to a data order in which the data/operands of the instructions are ready in the processor for processing.
  • the processor buffers execution results ( 111 ) of the instructions in a re-order buffer ( 113 ).
  • the execution results ( 111 ) of instructions can enter the re-order buffer ( 113 ) in an order that is different from the program order of the instructions.
  • first instructions can be programmed to be processed earlier than second instructions; due to out-of-order execution, execution results of the second instructions can arrive in the re-order buffer ( 113 ) earlier than the results of first instructions; and in such a situation, the execution results of the second instructions can wait in the re-order buffer ( 113 ) until the results of first instructions arrive in the re-order buffer ( 113 ), such that the results of the first and second instructions can be provided from the re-order buffer ( 113 ) according to the program order of the instructions.
  • the re-order buffer ( 113 ) outputs the results of the instructions in accordance with the order in which the instructions are programmed.
  • a controller determines whether to adjust the capacity of the re-order buffer ( 113 ).
  • the controller e.g., 115 or 114
  • the controller can determine at a regular time interval whether to adjust the capacity of the re-order buffer ( 113 ).
  • the controller e.g., 115 or 114
  • the controller can determine whether to adjust the capacity of the re-order buffer ( 113 ) when some results can be moved out of the re-order buffer ( 113 ) for graduation according to the program order.
  • the controller e.g., 115 or 114
  • the controller can determine whether to adjust the capacity of the re-order buffer ( 113 ) when more than a threshold number of results can be moved out of the re-order buffer ( 113 ) for graduation according to the program order.
  • the controller e.g., 115 or 114
  • the controller can determine whether to adjust the capacity of the re-order buffer ( 113 ) when more than a threshold number of batches of results have been moved out of the re-order buffer ( 113 ) for graduation according to the program order.
  • the controller e.g., 115 or 114 decides to adjust the capacity of the re-order buffer ( 113 )
  • the controller determines an adjustment to the capacity of the re-order buffer ( 113 ) according to an output from a random number generator ( 116 ).
  • the controller e.g., 115 or 114
  • the controller can decide to increase or decrease the capacity of the re-order buffer ( 113 ) by a random amount calculated based on the output of the random number generator ( 116 ).
  • the controller e.g., 115 or 114
  • the controller can decide to increase or decrease the capacity of the re-order buffer ( 113 ) (e.g., by a predetermined amount) at a randomized time instance controlled by the random number generator ( 116 ).
  • the controller e.g., 115 or 114
  • the controller can decide to increase or decrease the capacity of the re-order buffer ( 113 ) at a random time controlled by a random amount.
  • the controller (e.g., 115 or 114 ) implements the randomized adjustment to the capacity of the re-order buffer ( 113 ).
  • the controller e.g., 115 or 114
  • the controller can adjust the number of dummy results inserted in the re-order buffer ( 113 ) to control the useful capacity of the re-order buffer ( 113 ) in sorting results.
  • the controller e.g., 115 or 114
  • the controller can adjust the boundaries of the re-order buffer ( 113 ) to control the useful capacity of the re-order buffer ( 113 ) in sorting results.
  • the controller e.g., 115 or 114
  • FIG. 4 show a computing system in which the method of FIG. 3 can be implemented.
  • the computing system of FIG. 4 can include a processor ( 181 ) having an internal cache ( 191 ), a memory device ( 187 ), an external cache ( 193 ), and a storage device ( 189 ) that is connected to the processor ( 181 ) and/or the memory ( 187 ) via an interconnect ( 185 ).
  • a processor 181
  • the computing system of FIG. 4 can include a processor ( 181 ) having an internal cache ( 191 ), a memory device ( 187 ), an external cache ( 193 ), and a storage device ( 189 ) that is connected to the processor ( 181 ) and/or the memory ( 187 ) via an interconnect ( 185 ).
  • the processor ( 181 ) can have functional units ( 109 ) to execute instructions.
  • the processor ( 181 ) can further include registers ( 153 ) to contain memory addresses, data/operands of instructions to be executed in the functional units ( 109 ), and/or execution results of the instructions.
  • the registers ( 153 ) can include a program counter for loading instructions for execution, and a memory address register.
  • the memory address stored in the memory address register can be used to load an operand of the instruction, and/or store a computing result generated from executing the instruction.
  • the processor ( 181 ) can execute instructions out of their program order and make the results of instructions available in the program order using the re-order buffer ( 113 ).
  • the processor ( 181 ) has a controller ( 151 ) that is configured to cause randomness in timing of results entering and/or leaving the re-order buffer ( 113 ).
  • the randomness can be implemented via randomized adjustments to the useful capacity of the re-order buffer ( 113 ), using any of the techniques discussed above in connection with FIGS. 1-3 .
  • the controller ( 151 ) can be configured as the buffer controller ( 115 ) of FIG. 1 , or the buffer capacity controller ( 114 ) of FIG. 2 , to randomize data timing in the re-order buffer ( 113 ) using a method of FIG. 3 .
  • the randomizing techniques discussed above can cause the usages of the re-order buffer ( 113 ) to be different for each execution of a same program.
  • One of the consequences of the use of the techniques is that for multiple executions of the same program with the same data set under exactly the same computation conditions (same number of users, same amount of physical memory, etc.) the execution time of the program can be different. In many cases, this arrangement by itself can be highly secure against timing attacks.
  • one of the more publicize security attacks was to determine a cryptographical key, based on timing.
  • timing is just one or two cycles different for execution instances, a large body of such attacks can be rendered useless on computer systems having reorder buffers configured in ways discussed in the present disclosure.
  • the processor ( 181 ) can issue instructions to the functional units ( 109 ) from the internal cache ( 191 ) (e.g., an instruction buffer ( 103 )) when the data/operands of the instruction are available in the internal cache ( 191 ), the registers ( 153 ), and/or the re-order buffer ( 113 ).
  • the processor ( 181 ) buffers the execution results of the instructions generated by the functional units ( 109 ) for graduation in accordance with the program order of the instructions.
  • the processor ( 181 ) can move the results from the re-order buffer ( 113 ) in the program order to registers ( 153 ), the internal cache ( 191 ), the external cache ( 193 ), the memory device ( 187 ), and/or the storage device ( 189 ) with a controller ( 195 ).
  • the addresses used the registers of the processor ( 181 ) are virtual memory addresses; and a memory management unit (MMU) ( 183 ) can convert the virtual memory addresses to physical memory addresses to access the external cache ( 193 ), the memory device ( 187 ), and/or the storage device ( 189 ).
  • MMU memory management unit
  • the data in the memory device ( 187 ) can be cached in the external cache ( 193 ) of the processor ( 181 ) and/or the internal cache ( 191 ) of the processor ( 181 ).
  • the data in the external cache ( 193 ) can be cached in the internal cache ( 191 ).
  • the data in the storage device ( 189 ) can be cached in the memory device ( 187 ), in the external cache ( 193 ), and/or in the internal cache ( 191 ).
  • the memory management unit (MMU) ( 183 ) controls the data movement among the internal cache ( 191 ), the external cache ( 193 ), and the memory device ( 187 ).
  • the techniques disclosed herein can be applied to at least to computer systems where processors are separated from memory and processors communicate with memory and storage devices via communication buses and/or computer networks. Further, the techniques disclosed herein can be applied to computer systems in which processing capabilities are integrated within memory/storage.
  • the processing circuits including executing units and/or registers of a typical processor, can be implemented within the integrated circuits and/or the integrated circuit packages of memory media to perform processing within a memory device.
  • a processor e.g., 181
  • the processor can be a unit integrated within memory to overcome the von Neumann bottleneck that limits computing performance as a result of a limit in throughput caused by latency in data moves between a central processing unit and memory configured separately according to the von Neumann architecture.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Hardware Design (AREA)
  • Mathematical Physics (AREA)
  • Memory System Of A Hierarchy Structure (AREA)
  • Storage Device Security (AREA)

Abstract

Methods, systems, and apparatuses related to re-order buffers and for protection from timing-based security attacks are described. A processor may have functional units configured to execute instructions out of order, a re-order buffer configured to buffer the execution results of instructions for output in order, and a controller configured to randomize data timing in the re-order buffer. For example, the controller can make random adjustments to the capacity of the re-order buffer in buffering and/or sorting execution results and thus randomize data timing in the re-order buffer.

Description

    RELATED APPLICATIONS
  • The present application is a continuation application of U.S. patent application Ser. No. 16/210,609 filed Dec. 5, 2018, the entire disclosures of which application are hereby incorporated herein by reference.
  • TECHNICAL FIELD
  • At least some embodiments disclosed herein relate generally to computer architecture and more specifically, but not limited to, techniques to protect against security attacks on re-order buffers.
  • BACKGROUND
  • Instructions are typically programmed to be executed sequentially. A program order of instructions is the order in which the instructions are programmed for execution in a processor.
  • It is possible to execute some instructions according to an alternative order and obtain the same result(s) as executing the instructions according to the program order.
  • Out-of-order execution have been implemented in some processors to improve the utilization of the processing power of the processors and increase the overall speed of executing a program having a sequence of instructions.
  • For example, when the processor is about to process an instruction that is configured to operate on an operand, the operand may be in the process of being loaded from a cache, or a main memory, or a storage device. However, the operand of the next instruction in the program order may be ready for processing in the processor. Thus, the processor may execute the next instruction, instead of pausing the execution of instructions to wait for the operand that is being loaded from the cache, the main memory, or the storage device.
  • A “data order” of instructions is the order in which the data or operands of the instructions become available in the processor for processing. The data order is typically different from the program order in contemporary processor design. A processor can be configured to execute instructions according to the data order of the instructions, instead of the program order of the instructions.
  • A re-order buffer can be used to temporally hold the execution results of instructions that are executed out of their program order. For example, the instructions can be executed in the data order of the instructions. The results stored in the re-order buffer can be moved out of the re-order buffer in the program order of the respective instructions, as if the results were generated by executing the instructions according to the program order. For example, a sequence of 3 instructions can be a first instruction to load an operand A into a first register (e.g., “load A, r1”), a second instruction to load another operand B into a second register (e.g., “load B, r2”), and a third instruction to add a number to the second register (e.g., “add #1, r2”). It is possible to execute the second instruction (e.g., “load B, r2”) out of order before the execution of the first instruction (e.g., “load A, r1”), execute the third instruction (e.g., “add #1, r2”), and then execute the first instruction (e.g., “load A, r1”). Such an alternative execution sequence can be desirable when the memory system can return the operand B before the operand A. For example, when the data becomes ready in the order of B, #1, A, the instructions can be executed in the order of “load B, r2”, “add #1, r2”, and “load A, r1”, which is different from the program order of “load A, r1”, “load B, r2”, and “add #1, r2”.
  • Implementations of out-of-order execution may have security vulnerability. Examples of such security vulnerabilities in computer processors include Meltdown and Spectre that were made public in 2018. For example, security vulnerabilities may allow data to be cached from a privileged security boundary, resulting in a race condition that could be timed to leak privileged information. An example of data in a privileged security boundary is data located in the operating system kernel.
  • BRIEF DESCRIPTION OF THE DRAWINGS
  • The embodiments are illustrated by way of example and not limitation in the figures of the accompanying drawings in which like references indicate similar elements.
  • FIG. 1 shows a buffer controller configured to protect against timing-based security attacks on a re-order buffer according to one embodiment.
  • FIG. 2 shows an out-of-order execution controlled by a buffer capacity controller according to one embodiment.
  • FIG. 3 shows a method to protect against timing-based security attacks on re-order buffers according to one embodiment.
  • FIG. 4 show a computing system in which the method of FIG. 3 can be implemented.
  • DETAILED DESCRIPTION
  • The present disclosure includes techniques for protection against timing-based security attacks on re-order buffers.
  • A timing-based security attack relies upon a timing pattern of results in a re-order buffer. Such an attack can be prevented and/or made difficult to implement by randomizing the timing pattern of results in re-order buffers.
  • For example, the timing pattern of results in a re-order buffer can be dependent on the operating capacity of the re-order buffer. The actual/operating capacity of the re-order buffer usable to re-order results of instructions that are executed out of their program order can be changed randomly from time to time such that the timing pattern changes from time to time. Such a capacity adjustment can be performed randomly in time, or periodically, to introduce randomness in the timing of the results in the re-order buffer.
  • FIG. 1 shows a buffer controller (115) configured to protect against timing-based security attacks on a re-order buffer (113) according to one embodiment. For example, the buffer controller (115) can be implemented in a processor of a computer system illustrated in FIG. 4.
  • In FIG. 1, the re-order buffer (113) is configured to receive results of instructions in an order in which instructions are executed. The results in the re-order buffer (113) can be moved out of the re-order buffer (113) for committing into a register file of a processor (e.g., 181 in FIG. 4), a cache memory of the processor, and/or a memory external to the processor, based on a “graduation order.” The graduation order of the results in the re-order buffer (113) for instructions is the order in which the results of the instructions are committed and the instructions are retired for completion; and the graduation order (retirement order, or commitment order) is typically configured to be consistent with the program order of the instructions. The execution result of an instruction that is to be executed early in the program order is to be graduate from the re-order buffer (113) early. A result of an instruction can be moved out of the re-order buffer (113) for committing when the results of instructions programmed before the instruction in the program order are ready to be moved out of the re-order buffer (113) for committing. In some instances, some instructions can be executed in parallel units, threads or pipelines; and the graduation order (retirement order, or commitment order) from the re-order buffer (113) preserves sequential consistency. In general, sequential consistency requires that the result of any execution is the same as if the instructions were executed in a sequential order specified by its program. Commitment or committing to a register may be referred to as writing to a register. So results may be committed to a register by a processor configured to write the results to the register.
  • The capacity of the re-order buffer (113) determines the depth of a sequence of instructions that can be executed out of order before a result can graduate from the re-order buffer (113). A same set of instructions executed using re-order buffers (e.g., 113) of different capacities can have different timings of results buffering in the re-order buffer (113). Thus, changing the capacity of the re-order buffer (113) can change the pattern of out of order of executions. Randomizing the change in the capacity of the re-order buffer (113) can introduce randomness in data timing in the re-order buffer (113) and thus remove the predictability of timing in the re-order buffer (113) and defeat or prevent timing-based security attacks on the re-order buffer (113).
  • In some instances, the re-order buffer (113) has a predetermined full capacity. The buffer controller (115) identifies a usable capacity of the re-order buffer (113) for sorting the incoming results (111) that are provided in the order of actual execution/completion of instructions. When the usable capacity identified by the buffer controller (115) is reached, the out-of-order execution of instructions beyond the set of instructions for each the re-order buffer (113) can buffer their results is prevented, until some of the results in the re-order buffer graduate from the re-order buffer (113).
  • The usable capacity of the re-order buffer (113) can be a random fraction of the predetermined full capacity of the re-order buffer (113). The randomness in usable capacity of the re-order buffer (113) can destroy or weaken the predictability of timing of the re-order buffer (113) and thus protect against timing-based security attack on the re-order buffer (113).
  • In some instances, the re-order buffer (113) can have a dynamically allocated amount of capacity for sorting the results in execution order (111) into the results in graduation order (117). The buffer controller (115) controls the dynamic allocation of the capacity for the re-order buffer (113) (e.g., based on the output of a random number generator).
  • In some instances, multiple processing cores can have multiple re-order buffers (e.g., 113) respectively. A buffer controller (115) can dynamically re-allocate a shared buffer capacity for the multiple re-order buffers (e.g., 113). For example, instead of evenly dividing the shared buffer capacity among the multiple re-order buffers (e.g., 113), the buffer controller (115) can randomize the ratios of capacity allocations among the multiple re-order buffers (e.g., 113) to cause randomness in timing.
  • In some instances, the buffer controller (115) re-configures the usable capacity of the re-order buffer (113) periodically at a regular, predetermined time interval. Alternatively, a usable capacity can be configured for the re-order buffer (113) for a random time period of operation; and after the random time period of operation, the usable capacity of the re-order buffer (113) can be reconfigured for another random period of operations. Time periods of operation may be referred to as, e.g., a first period of time and a second period of time following the first period of time. The randomness in the lengths of periods of operation at two or more constant usable capacities can also reduce or destroy the timing predictability in the re-order buffer (113).
  • FIG. 2 shows an out-of-order execution controlled by a buffer capacity controller (114) according to one embodiment. For example, the buffer controller (115) of FIG. 1 can be implemented using the buffer capacity controller (114) of FIG. 2 with a random number generator (116) to randomize out-of-order execution of instructions. The random number generator (116) can be configured to prevent an attacker from detecting the sequence of outputs generated from the random number generator (116) and/or its algorithm for generating randomized outputs. For example, statistically random noises on computer buses can be used in the random number generator (116) to prevent an attacker from accurately predicting the outputs of the random number generator (116). Electrical noises in general cannot be modeled accurately. Such stochastic processes are, in theory, completely unpredictable; and the theory's assertions of unpredictability are subject to experimental tests. In general, any techniques for securing a random number generator (116) against attacks can be used. Thus, the present disclosure is not limited to any specific implementations of random number generators.
  • In FIG. 2, instructions (101) fetched according to the program order of the instructions are buffered in the instruction buffer (103). The instructions (101) can be fetched from a cache memory of a processor, from a memory of a computer system, and/or a storage device of the computer system (e.g., as illustrated in FIG. 6).
  • The instructions in the instruction buffer (103) can be executed in functional units (109) of the processor when the data/operands (107) of the instructions are available to the functional units.
  • In general, some of the data operands (107) of the instructions may be loaded from a cache memory of the processor, from the memory of the computer system, and/or from the storage device of the computer system (e.g., illustrated in FIG. 6). Other data operands (107) of the instructions can be the results of the executions of other instructions. Such results may be available in registers/register files of the processor and/or in the re-order buffer (113).
  • Loading certain data items (e.g., from a cache memory, a main memory, or a storage device) can take a time period that is longer than the processing of one or more data-ready instructions. The data/operands (107) of data-ready instructions can be used by the functional units (109) in a short time period. Thus, such data-ready instructions (105) in the instruction buffer (103) can be issued to functional units (109) for execution according to a data order that is different from the program order.
  • The functional units (109) generates results (111) in an order of execution/completion of instructions; and the results (111) are temporally stored in the re-order buffer (113) for their graduation. A result of each respective instruction can graduate/retire/be committed from the re-order buffer (113) when the results of instructions before the respective instruction are in the re-order buffer (113) and ready for graduation, or have already graduated from the re-order buffer (113).
  • Results (117) in the graduation order, which is consistent with the program order of their instructions (101), can be moved out of the re-order buffer (113) for committing into registers (register files, a cache, a main memory, and/or a storage device) (119).
  • When the capacity of the re-order buffer (113) is fixed, the timing of the results (111) in the re-order buffer (113) for a given set of instructions may be predicted, determined, and/or exploited by a security attack to gain unauthorized knowledge about the execution of instructions and/or their data.
  • To destroy, reduce, or weaken the predictability of the timing of the results (111) entering the re-order buffer (113) and/or the results (117) leaving the re-order buffer (113), the buffer capacity controller (114) can inject randomness in the timing by randomizing the usable capacity of the re-order buffer (113) in sorting the results (111/117).
  • For example, the buffer capacity controller (114) can include, or be coupled to, a random number generator (116). The output of the random number generator (116) can be used in the buffer capacity controller (114) to determine a limit of usable portion of the re-order buffer (113) in sorting the results (111/117).
  • For example, when a result set graduates from the re-order buffer (113), the buffer capacity controller (114) can determine an adjustment to the usable portion of the re-order buffer (113) in sorting the results (111/117). The adjustment can be made via adding dummy results into the re-order buffer (113), or removing dummy results that have been previously added to the re-order buffer (113). The dummy results added into the front or the back of the queue (or another location) in the re-order buffer (113) effectively reduces the usable portion of the re-order buffer (113) for sorting the results (111/117).
  • For example, the output of the random number generator (116) can be converted to a count of dummy results to be kept in the re-order buffer (113) for a next time period of operations of the re-order buffer. The count of dummy results corresponds to a fraction of the full capacity of the re-order buffer (113). If the current count of dummy results in the re-order buffer (113) is larger than the desired count converted from the output of the random number generator (116), the buffer capacity controller (114) removes one or more dummy results from the re-order buffer (113), as if the dummy results were to graduate from the re-order buffer (113). If the current count of dummy results in the re-order buffer (113) is smaller than the desired count converted from the output of the random number generator (116), the buffer capacity controller (114) adds one or more dummy results to the re-order buffer (113) (e.g., in the slots vacated by the results (117) that recently graduate from the re-order buffer (113)), as if the dummy results were generated by the functional units (109) as a result of executing dummy instructions.
  • Alternatively, the buffer capacity controller (114) can be configured to adjust, according to the random number generator (116), one or more boundaries of the re-order buffer (113) that define the capacity of the buffer capacity controller (114).
  • In some instances, the output of the random number generator (116) controls when the buffer capacity controller (114) adjusts the usable capacity of the re-order buffer (113).
  • For example, the output of the random number generator (116) can be used to set a threshold count of cycles of operations of the re-order buffer between two successive adjustments. After the threshold count of cycles of operations following a prior adjustment, the buffer capacity controller (114) can adjust again the capacity of the re-order buffer (113).
  • Cycles of operations of the re-order buffer can be counted based on a predetermined number of instruction cycles (or clock cycles) of the processor in one embodiment.
  • Alternatively, a cycle of operations can be counted as being between two successive graduations of result sets (117) from the re-order buffer (113). In such a situation, the length of the cycle may not be a constant relative to a clock cycle and/or an instruction cycle.
  • FIG. 3 shows a method to protect against timing-based security attacks on re-order buffers according to one embodiment. For example, the method of FIG. 3 can be implemented using the buffer controller (115) of FIG. 1 or the buffer capacity controller (114) of FIG. 2.
  • At block 131, a processor (e.g., 181 in FIG. 4) executes instructions in an order that is different from a program order in which the instructions are programmed.
  • For example, the processor can execute the instructions according to a data order in which the data/operands of the instructions are ready in the processor for processing.
  • At block 133, the processor buffers execution results (111) of the instructions in a re-order buffer (113).
  • For example, the execution results (111) of instructions can enter the re-order buffer (113) in an order that is different from the program order of the instructions. For example, first instructions can be programmed to be processed earlier than second instructions; due to out-of-order execution, execution results of the second instructions can arrive in the re-order buffer (113) earlier than the results of first instructions; and in such a situation, the execution results of the second instructions can wait in the re-order buffer (113) until the results of first instructions arrive in the re-order buffer (113), such that the results of the first and second instructions can be provided from the re-order buffer (113) according to the program order of the instructions.
  • At block 135, the re-order buffer (113) outputs the results of the instructions in accordance with the order in which the instructions are programmed.
  • At block 137, a controller (e.g., 115 or 114) determines whether to adjust the capacity of the re-order buffer (113).
  • For example, the controller (e.g., 115 or 114) can determine at a regular time interval whether to adjust the capacity of the re-order buffer (113).
  • For example, the controller (e.g., 115 or 114) can determine whether to adjust the capacity of the re-order buffer (113) when some results can be moved out of the re-order buffer (113) for graduation according to the program order.
  • For example, the controller (e.g., 115 or 114) can determine whether to adjust the capacity of the re-order buffer (113) when more than a threshold number of results can be moved out of the re-order buffer (113) for graduation according to the program order.
  • For example, the controller (e.g., 115 or 114) can determine whether to adjust the capacity of the re-order buffer (113) when more than a threshold number of batches of results have been moved out of the re-order buffer (113) for graduation according to the program order.
  • At block 139, if the controller (e.g., 115 or 114) decides to adjust the capacity of the re-order buffer (113), the controller (e.g., 115 or 114) determines an adjustment to the capacity of the re-order buffer (113) according to an output from a random number generator (116).
  • For example, the controller (e.g., 115 or 114) can decide to increase or decrease the capacity of the re-order buffer (113) by a random amount calculated based on the output of the random number generator (116).
  • In some instances, the controller (e.g., 115 or 114) can decide to increase or decrease the capacity of the re-order buffer (113) (e.g., by a predetermined amount) at a randomized time instance controlled by the random number generator (116).
  • Optionally, the controller (e.g., 115 or 114) can decide to increase or decrease the capacity of the re-order buffer (113) at a random time controlled by a random amount.
  • At block 141, the controller (e.g., 115 or 114) implements the randomized adjustment to the capacity of the re-order buffer (113).
  • For example, the controller (e.g., 115 or 114) can adjust the number of dummy results inserted in the re-order buffer (113) to control the useful capacity of the re-order buffer (113) in sorting results.
  • For example, the controller (e.g., 115 or 114) can adjust the boundaries of the re-order buffer (113) to control the useful capacity of the re-order buffer (113) in sorting results.
  • For example, the controller (e.g., 115 or 114) can re-partition a set of memory cells configured for multiple re-order buffers (e.g., 113) to adjust their capacities, including the capacity of the re-order buffer (113).
  • FIG. 4 show a computing system in which the method of FIG. 3 can be implemented.
  • The computing system of FIG. 4 can include a processor (181) having an internal cache (191), a memory device (187), an external cache (193), and a storage device (189) that is connected to the processor (181) and/or the memory (187) via an interconnect (185).
  • For example, the processor (181) can have functional units (109) to execute instructions. The processor (181) can further include registers (153) to contain memory addresses, data/operands of instructions to be executed in the functional units (109), and/or execution results of the instructions.
  • For example, the registers (153) can include a program counter for loading instructions for execution, and a memory address register. When an instruction is being executed in the processor (181), the memory address stored in the memory address register can be used to load an operand of the instruction, and/or store a computing result generated from executing the instruction.
  • The processor (181) can execute instructions out of their program order and make the results of instructions available in the program order using the re-order buffer (113).
  • The processor (181) has a controller (151) that is configured to cause randomness in timing of results entering and/or leaving the re-order buffer (113). For example, the randomness can be implemented via randomized adjustments to the useful capacity of the re-order buffer (113), using any of the techniques discussed above in connection with FIGS. 1-3. For example, the controller (151) can be configured as the buffer controller (115) of FIG. 1, or the buffer capacity controller (114) of FIG. 2, to randomize data timing in the re-order buffer (113) using a method of FIG. 3.
  • The randomizing techniques discussed above can cause the usages of the re-order buffer (113) to be different for each execution of a same program. One of the consequences of the use of the techniques is that for multiple executions of the same program with the same data set under exactly the same computation conditions (same number of users, same amount of physical memory, etc.) the execution time of the program can be different. In many cases, this arrangement by itself can be highly secure against timing attacks.
  • For example, one of the more publicize security attacks was to determine a cryptographical key, based on timing. When the timing is just one or two cycles different for execution instances, a large body of such attacks can be rendered useless on computer systems having reorder buffers configured in ways discussed in the present disclosure.
  • For example, the processor (181) can issue instructions to the functional units (109) from the internal cache (191) (e.g., an instruction buffer (103)) when the data/operands of the instruction are available in the internal cache (191), the registers (153), and/or the re-order buffer (113). The processor (181) buffers the execution results of the instructions generated by the functional units (109) for graduation in accordance with the program order of the instructions. The processor (181) can move the results from the re-order buffer (113) in the program order to registers (153), the internal cache (191), the external cache (193), the memory device (187), and/or the storage device (189) with a controller (195).
  • In some instances, the addresses used the registers of the processor (181) are virtual memory addresses; and a memory management unit (MMU) (183) can convert the virtual memory addresses to physical memory addresses to access the external cache (193), the memory device (187), and/or the storage device (189).
  • For example, the data in the memory device (187) can be cached in the external cache (193) of the processor (181) and/or the internal cache (191) of the processor (181).
  • For example, the data in the external cache (193) can be cached in the internal cache (191).
  • For example, the data in the storage device (189) can be cached in the memory device (187), in the external cache (193), and/or in the internal cache (191).
  • In some instances, the memory management unit (MMU) (183) controls the data movement among the internal cache (191), the external cache (193), and the memory device (187).
  • The techniques disclosed herein can be applied to at least to computer systems where processors are separated from memory and processors communicate with memory and storage devices via communication buses and/or computer networks. Further, the techniques disclosed herein can be applied to computer systems in which processing capabilities are integrated within memory/storage. For example, the processing circuits, including executing units and/or registers of a typical processor, can be implemented within the integrated circuits and/or the integrated circuit packages of memory media to perform processing within a memory device. Thus, a processor (e.g., 181) as discussed above and illustrated in the drawings is not necessarily a central processing unit in the von Neumann architecture. The processor can be a unit integrated within memory to overcome the von Neumann bottleneck that limits computing performance as a result of a limit in throughput caused by latency in data moves between a central processing unit and memory configured separately according to the von Neumann architecture.
  • The description and drawings of the present disclosure are illustrative and are not to be construed as limiting. Numerous specific details are described to provide a thorough understanding. However, in certain instances, well known or conventional details are not described in order to avoid obscuring the description. References to one or an embodiment in the present disclosure are not necessarily references to the same embodiment; and, such references mean at least one.
  • In the foregoing specification, the disclosure has been described with reference to specific exemplary embodiments thereof. It will be evident that various modifications can be made thereto without departing from the broader spirit and scope as set forth in the following claims. The specification and drawings are, accordingly, to be regarded in an illustrative sense rather than a restrictive sense.

Claims (20)

What is claimed is:
1. A device, comprising:
a buffer having a full capacity;
a random number generator; and
a controller configured to adjust a currently usable capacity of the buffer as a random fraction of the full capacity based on an output of the random number generator.
2. The device of claim 1, wherein the device includes a processor having the buffer, the controller, and one or more functional units.
3. The device of claim 2, wherein the buffer is configured to store results of instructions executed in the one or more functional units out of order relative to a programmed order of the instructions.
4. The device of claim 3, wherein the processor further includes registers; and the processor is further configured to write the results from the buffer to the registers according to the programmed order of the instructions.
5. The device of claim 4, wherein the controller is configured to adjust the currently usable capacity periodically.
6. The device of claim 4, wherein the controller is configured to update the random fraction periodically according to an output of the random number generator.
7. The device of claim 4, wherein the controller is configured to update the random fraction after a random time period.
8. The device of claim 4, wherein the controller is configured to change a timing pattern in results, generated by the instructions and stored in the buffer, by adjusting the random fraction.
9. The device of claim 8, further comprising:
an instruction buffer, wherein the processor is configured to fetch the instructions into the instruction buffer in accordance the programmed order of the instructions and issue instructions from the instruction buffer to the one or more functional units out of order relative to the programmed order of the instructions.
10. A processor, comprising:
a first buffer having a full capacity;
a random number generator; and
a controller configured to adjust a currently usable capacity of the first buffer as a random fraction of the full capacity based on an output of the random number generator.
11. The processor of claim 10, further comprising:
one or more functional units; and
a second buffer;
wherein the processor is configured to fetch instructions into the second buffer in a first order, and issue the instructions from the second buffer to the one or more functional units in a second order different from the first order; and
wherein the first buffer is configured to store results of execution of the instructions by the one or more functional units as issued from the second buffer.
12. The processor of claim 11, further comprising:
registers, wherein the processor is further configured to write the results from the first buffer to the registers according to the first order.
13. The processor of claim 12, wherein the controller is configured to adjust the currently usable capacity periodically.
14. The processor of claim 12, wherein the controller is configured to update the random fraction periodically according to an output of the random number generator.
15. The processor of claim 12, wherein the controller is configured to update the random fraction after a random time period.
16. The processor of claim 12, wherein the controller is configured to change a timing pattern in results, generated by execution of the instructions and stored in the first buffer, by adjusting the random fraction.
17. A method, comprising:
generating, using a random number generator of a device, an output; and
adjusting, by a controller of the device having a first buffer and based on the output of the random number generator, a currently usable capacity of the first buffer as a random fraction of a full capacity of the first buffer.
18. The method of claim 17, further comprising:
fetching instructions into a second buffer in a first order;
issuing the instructions from the second buffer to one or more functional units of the device in a second order different from the first order; and
storing, into the first buffer, results of execution of the instructions by the one or more functional units as issued from the second buffer.
19. The method of claim 18, further comprising:
writing the results from the first buffer to registers of the device according to the first order.
20. The method of claim 19, further comprising:
updating the random fraction periodically using the random number generator.
US17/866,868 2018-12-05 2022-07-18 Protection Against Timing-based Security Attacks on Re-order Buffers Pending US20220350609A1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US17/866,868 US20220350609A1 (en) 2018-12-05 2022-07-18 Protection Against Timing-based Security Attacks on Re-order Buffers

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
US16/210,609 US11403107B2 (en) 2018-12-05 2018-12-05 Protection against timing-based security attacks by randomly adjusting reorder buffer capacity
US17/866,868 US20220350609A1 (en) 2018-12-05 2022-07-18 Protection Against Timing-based Security Attacks on Re-order Buffers

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
US16/210,609 Continuation US11403107B2 (en) 2018-12-05 2018-12-05 Protection against timing-based security attacks by randomly adjusting reorder buffer capacity

Publications (1)

Publication Number Publication Date
US20220350609A1 true US20220350609A1 (en) 2022-11-03

Family

ID=70970925

Family Applications (2)

Application Number Title Priority Date Filing Date
US16/210,609 Active 2039-07-05 US11403107B2 (en) 2018-12-05 2018-12-05 Protection against timing-based security attacks by randomly adjusting reorder buffer capacity
US17/866,868 Pending US20220350609A1 (en) 2018-12-05 2022-07-18 Protection Against Timing-based Security Attacks on Re-order Buffers

Family Applications Before (1)

Application Number Title Priority Date Filing Date
US16/210,609 Active 2039-07-05 US11403107B2 (en) 2018-12-05 2018-12-05 Protection against timing-based security attacks by randomly adjusting reorder buffer capacity

Country Status (5)

Country Link
US (2) US11403107B2 (en)
EP (1) EP3891635A4 (en)
KR (1) KR20210088005A (en)
CN (1) CN113196267A (en)
WO (1) WO2020117666A1 (en)

Family Cites Families (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5727177A (en) * 1996-03-29 1998-03-10 Advanced Micro Devices, Inc. Reorder buffer circuit accommodating special instructions operating on odd-width results
US6757831B1 (en) 1999-08-18 2004-06-29 Sun Microsystems, Inc. Logic block used to check instruction buffer configuration
GB0023698D0 (en) * 2000-09-27 2000-11-08 Univ Bristol Instruction issue in a processor
US7310706B1 (en) 2001-06-01 2007-12-18 Mips Technologies, Inc. Random cache line refill
US7788670B2 (en) * 2004-10-26 2010-08-31 Intel Corporation Performance-based workload scheduling in multi-core architectures
US8566565B2 (en) * 2008-07-10 2013-10-22 Via Technologies, Inc. Microprocessor with multiple operating modes dynamically configurable by a device driver based on currently running applications
US20110225654A1 (en) 2008-08-25 2011-09-15 Mao-Huai Weng Write-Proof Protection Method of a Storage Device
US8219994B2 (en) * 2008-10-23 2012-07-10 Globalfoundries Inc. Work balancing scheduler for processor cores and methods thereof
US9141809B2 (en) 2012-07-23 2015-09-22 Qualcomm Incorporated Method and apparatus for deterring a timing-based glitch attack during a secure boot process
US10747907B2 (en) 2014-12-16 2020-08-18 Cryptography Research, Inc. Buffer access for side-channel attack resistance
DE102016120558A1 (en) * 2016-10-27 2018-05-03 Infineon Technologies Ag DATA PROCESSING DEVICE AND METHOD FOR CRYPTOGRAPHIC PROCESSING OF DATA
CN108491694A (en) * 2018-03-26 2018-09-04 湖南大学 A kind of method of dynamic randomization defence Cache attacks
US20200034929A1 (en) * 2018-07-26 2020-01-30 Nasdaq, Inc. In-Order Processing of Transactions

Also Published As

Publication number Publication date
WO2020117666A1 (en) 2020-06-11
CN113196267A (en) 2021-07-30
EP3891635A4 (en) 2022-09-14
EP3891635A1 (en) 2021-10-13
KR20210088005A (en) 2021-07-13
US11403107B2 (en) 2022-08-02
US20200183699A1 (en) 2020-06-11

Similar Documents

Publication Publication Date Title
Qureshi New attacks and defense for encrypted-address cache
EP3757850B1 (en) Low memory overhead heap management for memory tagging
US9678894B2 (en) Cache-less split tracker architecture for replay protection trees
US11354240B2 (en) Selective execution of cache line flush operations
US10671530B1 (en) High-speed and memory-efficient flow cache for network flow processors
CN108228237B (en) Apparatus and method for storage stream detection and processing
Wang et al. Cooperative path-oram for effective memory bandwidth sharing in server settings
US11226906B2 (en) Devices and methods for secured processors
US11030030B2 (en) Enhanced address space layout randomization
US20180165097A1 (en) Dispatch of processor read results
Ojha et al. TimeCache: using time to eliminate cache side channels when sharing software
Cho et al. Smokebomb: effective mitigation against cache side-channel attacks on the arm architecture
JP2013016187A (en) Cache locking without interference from normal allocations
US20220350609A1 (en) Protection Against Timing-based Security Attacks on Re-order Buffers
Zhang et al. RAGuard: An Efficient and User-Transparent Hardware Mechanism against ROP Attacks
Lee et al. GhostLeg: Selective Memory Coalescing for Secure GPU Architecture
Wang et al. Lightweight timing channel protection for shared DRAM controller
Zhang et al. LAK: A Low-Overhead Lock-and-Key Based Schema for GPU Memory Safety
Vuong et al. An MLP-aware leakage-free memory controller
Ojha et al. Timing Cache Accesses to Eliminate Side Channels in Shared Software
Levchenko et al. Solutions to Problem of CAM Overflow in the Parallel Dataflow Computing System “Buran”
Wang et al. Leveraging DRAM Refresh to Protect the Memory Timing Channel of Cloud Chip Multi-processors
Maas et al. A high-performance oblivious RAM controller on the convey HC-2ex heterogeneous computing platform
Jin et al. Memory interface design for 3D stencil kernels on a massively parallel memory system
Kelemework INTERFACE: An Indirect, Partitioned, Random, Fully-Associative Cache to Avoid Shared Last-Level Cache Attacks

Legal Events

Date Code Title Description
AS Assignment

Owner name: MICRON TECHNOLOGY, INC., IDAHO

Free format text: ASSIGNMENT OF ASSIGNORS INTEREST;ASSIGNOR:WALLACH, STEVEN JEFFREY;REEL/FRAME:060682/0976

Effective date: 20181205

STPP Information on status: patent application and granting procedure in general

Free format text: DOCKETED NEW CASE - READY FOR EXAMINATION