IP Library Granted Patent US 10,445,494
Granted Patent B2
US 10,445,494 · App. 15/658,699 · Granted Oct 15, 2019

Attack protection for valid gadget control transfers

Inventors: Vedvyas Shanbhogue (Austin, TX); Ravi L. Sahita (Portland, OR); Yuriy Bulygin (Beaverton, OR); Xiaoning Li (Santa Clara, CA); Jason W. Brandt (Austin, TX)
Assignee: Intel Corporation
G06F21/52G06F9/30021G06F9/30054G06F9/30076G06F9/30134G06F9/3861G06F9/4484
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 10,445,494
App. No.
15/658,699
Granted
Oct 15, 2019
Kind
B2
Abstract

In one embodiment, a processor comprises: a first register to store a first bound value for a stack to be stored in a memory; a second register to store a second bound value for the stack; a checker logic to determine, prior to an exit point at a conclusion of a function to be executed on the processor, whether a value of a stack pointer is within a range between the first bound value and the second bound value; and a logic to prevent a return to a caller of the function if the stack pointer value is not within the range. Other embodiments are described and claimed.

Claims (34)

1. At least one non-transitory computer readable medium including instructions that when executed enable a system to:

during execution of a process on a processor of the system and prior to a call to a function, store a first value in a first register of a plurality of registers of the processor, the first value comprising a random value;

responsive to a control transfer termination (CTT) instruction encountered after a control transfer operation that returns from the function, determine whether a current value of the first register equals the first value;

if so, continue execution of the process, and otherwise raise a violation; and

set a page to an execute only status, the page including the instructions to store the random value in the first register via immediate parameters.

2. The at least one non-transitory computer readable medium of claim 1 , further comprising instructions that when executed enable the system to, during execution of the function, store the first value of the first register to a storage, use the first register to store a first function value and, prior to a termination of the function, to restore the first value from the storage to the first register.

3. The at least one non-transitory computer readable medium of claim 1 , wherein to raise the violation comprises a fault to indicate presence of a malware attack in which the function is at least one of improperly entered or improperly exited.

4. The at least one non-transitory computer readable medium of claim 1 , further comprising instructions that when executed enable the system, responsive to the violation, to perform one or more of termination of the process, shutdown of the system, and shutdown of a guest that caused the violation.

5. The at least one non-transitory computer readable medium of claim 1 , wherein the processor comprises an interlock register, the interlock register corresponding to the first register.

6. The at least one non-transitory computer readable medium of claim 1 , wherein to raise the violation comprises insertion of a CTT fault micro-operation into a pipeline of the processor.

7. The at least one non-transitory computer readable medium of claim 1 , further comprising instructions that when executed enable the system to save a value of the first register to a stack before the call to the function.

8. The at least one non-transitory computer readable medium of claim 7 , further comprising instructions that when executed enable the system to restore the value of the first register from the stack to the first register upon the continued process execution.

9. The at least one non-transitory computer readable medium of claim 1 , further comprising instructions that when executed enable the system to update an extended page table entry associated with the page to the execute only status, wherein an entry associated with the page in a first page table is set to a read execute status.

10. An apparatus comprising:

a decode circuit to decode instructions;

an execution circuit to execute at least some of the decoded instructions;

a hardware stack to store return addresses;

a plurality of registers; and

wherein the execution circuit is to:

during execution of a process and prior to a call to a function, store a first value in a first register of the plurality of registers, the first value comprising a random value;

responsive to a control transfer termination (CTT) instruction encountered after a control transfer operation that returns from the function, determine whether a current value of the first register equals the first value;

if so, continue execution of the process, and otherwise raise a violation, and

set a page to an execute only status, the page including at least one instruction to store the random value in the first register via immediate parameters.

11. The apparatus of claim 10 , wherein the execution circuit comprises a pseudorandom number generator to generate the random value.

12. The apparatus of claim 10 , wherein the first register comprises an interlock register.

13. The apparatus of claim 10 , wherein the execution circuit comprises a comparison logic to compare the current value and the first value.

14. The apparatus of claim 10 , wherein the execution circuit, during execution of the function, is to obtain the first value from the hardware stack and restore the first value to the first register.

15. A method comprising:

during execution of a process on a processor of a system and prior to a call to a function, storing a first value in a first register of a plurality of registers of the processor, the first value comprising a random value;

responsive to a control transfer termination (CTT) instruction encountered after a control transfer operation that returns from the function, determining whether a current value of the first register equals the first value;

if so, continuing execution of the process, and otherwise raising a violation; and

setting a page to an execute only status, the page including at least one instruction to store the random value in the first register via immediate parameters.

16. The method of claim 15 , wherein raising the violation comprises inserting a CTT fault micro-operation into a pipeline of the processor.

17. The method of claim 15 , further comprising updating an extended page table entry associated with the page to the execute only status, wherein an entry associated with the page in a first page table is set to a read execute status.

Continuity (2)
Division 14518507 · Oct 20, 2014
Related Publication 20170329961A1 · Nov 16, 2017
Cited By (1)
US 12,229,453