ascend-secure-processor / oram

Hardware implementation of ORAM
22 stars 1 forks source link

This REAMDE describes the code structure for Tiny ORAM.


Introduction

Tiny ORAM is partitioned into a frontend and a backend as this leads to a more modular design. At a system level, the major components connect like this:

User design <= Memory interface =>
Frontend <= Position-based ORAM interface =>
Backend <= Memory interface =>
DRAM controller

The 'Memory interface' is: (op, address, data) where op = read/write.

The 'Position-based ORAM interface' is: (op, address, data, currentPos, NewPos) where op = read/write/some additional low-level commands.

The frontend manages the block-to-position mapping, and translates a frontend access into one or multiple backend accesses. A Unified frontend is currently available, which manages the position map (PosMap) recursively. The Unified frontend hides most of the recursion overhead when the access pattern has good locality, using a PosMap-Lookaside-Buffer (PLB). A basic (non-recursive) frontend is under development.

The backend is based on Path ORAM by Stefanov et. al [1]; i.e., structures external memory as a binary tree and reads random paths in the tree to retrieve blocks requested by the frontend. The backend also manages the stash and evicts blocks back to the tree. Tiny ORAM currently supports two backend protocols. One is the original Path ORAM in [1]. The other is RAW Path ORAM, a variant of Path ORAM proposed in [2]. RAW Path ORAM simplifies integrity verification, and reduces the number of encryption and hash units required. (Note: we refer to 'RAW Path ORAM' as 'REW Path ORAM' in the code for legacy reasons. This will be corrected in future releases.)

To choose between different configurations, users only need to change the parameters passed to TinyORAMCore: EnableREW ==> Path ORAM vs. RAW Path ORAM EnableIV ==> whether or not to enable integrity verification (EnableIV = 1 only works when EnableREW = 1)


Code structure

Tiny ORAM                           (TinyORAMCore.v, top module)

    Frontend                        (choose between Basic or Unified)

        Basic frontend                  (under development)

        Unified frontend                (frontend/UORAMController.v)

            PosMap+PLB              (frontend/PosMapPLB.v)

            DataPath                (frontend/UORAMDataPath.v)

            Integrity Verification          (integrity/*.v)

    Backend                         (choose between Path ORAM or RAW Path ORAM)

        Path ORAM Backend               (backend/PathORAMBackend.v)

            Symmetric Encryption            (encryption/basic/*.v)

        RAW Path ORAM Backend               (backend/PathORAMBackend.v)

            Symmetric Encryption            (encryption/rew/*.v)

        Shared across both backend designs

            Address Generator           (addr/*.v)

            Stash                   (stash/*.v)

    User-level parameters                   (include/PathORAM.vh)

Conventions


Citations

[1] Emil Stefanov, Marten van Dijk, Elaine Shi, Christopher Fletcher, Ling Ren, Xiangyao Yu, and Srinivas Devadas. 2013. Path ORAM: an extremely simple oblivious RAM protocol. In Proceedings of the 2013 ACM SIGSAC conference on Computer & communications security (CCS).

[2] Ling Ren, Christopher Fletcher, Albert Kwon, Marten van Dijk, and Srinivas Devadas. 2017. Design and implementation of the Ascend secure processor. IEEE Transactions on Dependable and Secure Computing (TDSC)