IP Library Granted Patent US 9,256,552
Granted Patent B2
US 9,256,552 · App. 13/683,455 · Granted Feb 9, 2016

Selective access to executable memory

Inventor: Joe Epstein (Pleasanton, CA)
Assignee: CISCO TECHNOLOGY, INC.
G06F12/1416G06F12/145
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 9,256,552
App. No.
13/683,455
Granted
Feb 9, 2016
Kind
B2
Abstract

In an embodiment, a data processing method comprises, in a computer executing a supervisor program: the supervisor program establishing a plurality of different memory access permissions comprising any combination of read, write, and execute permissions for one or more different regions of memory of a first domain; setting the memory access permissions of a first set of the regions of memory to execute only; in response to a request from a process to read or write a particular region of memory in the first set, performing one or more responsive actions that prevent the process from reading or modifying one or more instructions or one or more embedded immediate values of the particular region of memory. Embodiments provide selective access to executable memory.

Claims (40)

1. A computer-implemented method comprising:

in a computer executing a supervisor program:

the supervisor program establishing a plurality of different memory access permissions comprising any combination of read, write, and execute permissions for one or more different regions of memory of a first domain;

setting the memory access permissions of a first set of the regions of memory to execute only; and

in response to a request from a process to read or write a particular region of memory in the first set:

throwing a read fault for the particular region of memory;

performing one or more responsive actions that prevent the process from reading or modifying one or more instructions or one or more embedded immediate values of the particular region of memory;

after performing the one or more responsive actions, setting the memory access permissions of the particular region of memory to readable-writeable or read-only and removing the execute-only permission;

permitting the process to read or write the particular region of memory.

2. The method of claim 1 , further comprising marking one or more of the regions of memory in the first set as inaccessible by hardware.

3. The method of claim 1 , wherein the one or more responsive actions comprise any one or more of deleting the one or more instructions, replacing the one or more instructions with filler values, deleting the one or more embedded immediate values, and replacing the one or more embedded immediate values with filler values.

4. The method of claim 1 , further comprising, in response to receiving a request from the process or a different process to execute the particular region of memory; performing one or more other responsive actions that restore execution access to, or content of, the one or more instructions or the one or more embedded immediate values of the particular region of memory; allowing the process or the different process to execute the particular region of memory.

5. The method of claim 1 , further comprising determining that a dirty bit in a page table entry for the particular region of memory is set and, in response, clearing the dirty bit.

6. The method of claim 1 , further comprising injecting a page flush operation.

7. The method of claim 1 wherein the different regions of memory are established for use in one or more of: to emulate hardware memory, share memory between domains or otherwise communicate, or hide memory of one or more other domains from the first domain.

8. The method of claim 1 wherein the supervisor program is a hypervisor.

9. The method of claim 8 wherein the hypervisor is Xen.

10. The method of claim 9 wherein the computer comprises an Intel central processing unit.

11. The method of claim 9 wherein the computer comprises one or more extended page tables.

12. The method of claim 1 , further comprising determining one or more responsive actions to perform based on the identity of the process that is requesting to read or write the particular region of memory in the first set.

13. One or more non-transitory computer-readable media storing one or more sequence of instructions which when executed cause one or more computing device to perform:

executing a supervisor program in a computer:

the supervisor program establishing a plurality of different memory access permissions comprising any combination of read, write, and execute permissions for one or more different regions of memory of a first domain;

setting the memory access permissions of a first set of the regions of memory to execute only; and

in response to a request from a process to read or write a particular region of memory in the first set:

throwing a read fault for the particular region of memory;

performing one or more responsive actions that prevent the process from reading or modifying one or more instructions or one or more embedded immediate values of the particular region of memory;

after performing the one or more responsive actions, setting the memory access permissions of the particular region of memory to readable-writeable or read-only and removing the execute-only permission;

permitting the process to read or write the particular region of memory.

14. The non-transitory computer-readable media in claim 13 , further comprising instructions for marking one or more of the regions of memory in the first set as inaccessible by hardware.

15. The non-transitory computer-readable media in claim 13 , wherein the one or more responsive actions comprise any one or more of deleting the one or more instructions, replacing the one or more instructions with filler values, deleting the one or more embedded immediate values, and replacing the one or more embedded immediate values with filler values.

16. The non-transitory computer-readable media of claim 13 , further comprising instructions which when executed cause performing: in response to receiving a request from the process or a different process to execute the particular region of memory; performing one or more other responsive actions that restore execution access to, or content of, the one or more instructions or the one or more embedded immediate values of the particular region of memory; allowing the process or the different process to execute the particular region of memory.

17. The non-transitory computer-readable media of claim 13 , further comprising instructions for determining that a dirty bit in a page table entry for the particular region of memory is set and, in response, clearing the dirty bit.

18. The non-transitory computer-readable media of claim 13 , further comprising instructions for injecting a page flush operation.

19. The non-transitory computer-readable media of claim 13 , wherein the different regions of memory are established for use in one or more of: to emulate hardware memory, share memory between domains or otherwise communicate, or hide memory of one or more other domains from the first domain.

20. The non-transitory computer-readable media of claim 13 , wherein the supervisor program is a hypervisor.

21. The non-transitory computer-readable media of claim 20 , wherein the hypervisor is a Xen.

22. The non-transitory computer-readable media of claim 21 , wherein the computer comprises an Intel central processing unit.

23. The non-transitory computer-readable media of claim 21 , wherein the computer comprises one or more extended page tables.

24. The non-transitory computer-readable media of claim 13 , further comprising instructions for determining one or more responsive actions to perform based on the identity of the process that is requesting to read or write the particular region of memory in the first set.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Nov 21, 2012
From: EPSTEIN, JOE
To: CISCO TECHNOLOGY, INC.
Reel/Frame 029337/0753 →
Continuity (2)
Provisional Application 61562095 · Nov 21, 2011
Related Publication 20130132690A1 · May 23, 2013