Skip to content

wy-chung/bounds-check-using-capability

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 

Repository files navigation

Using capability to implement memory bounds checking

Wuyang Chung, [email protected]

Sep. 4, 2023

You can see the video of this presentation on YouTube.

Generally speaking there are two ways to do memory bounds checking, the object-based approach and the pointer-based approach. Each has its advantages and disadvantages. In this article I propose a capability-based approach to do memory bounds checking.

The table below shows the comparison of these approaches.

image

Below is the format of the pointer for capability-based approach.

image

The advantages of capability-based approach are:

  • The pointer is smaller than the fat pointer based approach
  • The overhead to get the object metadata is very low
  • When doing memcpy, there is no need to propagate the metadata for the pointers in the buffer since the metadata are in a spearate table
  • It can detect temporal safety violations by using capability revocation
  • It supports principle of intentional use
  • It supports principle of exclusive thread local data

About

Using capability to implement memory bounds checking

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published