3 POINTER-BASED INDIRECT
EVICTION CACHE
(PIE-CACHE)
We observed in IE-Cache that the actual conflict hap-
pens at tag-store of cache. Because of the direct
mapping between tag-store and data-store, data-store
also needs to relocate along with tag on conflict at
tag-store level. We find that the relocation of tag-
store only is sufficient in IE-Cache to achieve security
against conflict-based cache side-channel attacks. On
relocation of tag-store, if data remains at same place
in data-store, this will not depict an observable timing
effect. This is because the both tag and data remains
in cache after relocation of tag only.
In order to alleviate the high energy consumption
issue of IE-Cache without degrading the security, the
insight is to reduce the number of bytes needed to
be relocated by introducing the novel pointer-based
mapping between tag-store and data-store, we call
this proposed cache as Pointer-based Indirect Eviction
Cache (PIE-Cache). This allows to relocate tag with-
out moving data lines as pointer defines the respective
line in data-store. This replaces relocation of 64 bytes
cache line with only few bytes pointer in tag-store.
The number of pointer bytes depends on the data-
store size Reduction of such number of bytes in re-
location impacts the energy consumption. We exper-
imentally evaluated the impact of energy consump-
tion in Section 5 for varied cache sizes over Micro-
benchmark.
PIE-Cache threat model is identical to IE-Cache,
which we now make explicit. The attacker has user-
level privileges only. The attacker can measure mem-
ory access latency using hardware timers and also
via other methods like threads as counters. We also
consider that the memory de-duplication feature is
not enabled, which is a fair assumption as it is of-
ten disabled in real environment for security rea-
sons(Mukhtar et al., 2019). This also eliminates
the shared memory cache-based side-channel attacks
such as Flush+Reload and its variants.
Structurally, PIE-Cache is similar to IE-Cache. It
also contains skews with one cache way and each
cache way is indexed by cryptographic based index-
ing function. The indexing process uses the multi-
indexing and relocation of cache lines in the same
way as IE-Cache discussed in Section 2. PIE-Cache
implements random replacement policy to select the
cache line for relocation on each indexing level. The
main difference of PIE-Cache compared to IE-Cache
is the mapping mechanism between tag-store and
data-store. Each entry of PIE-Cache tag-store is intro-
duced with pointer that identifies the mapping to the
entry in data-store. Pointer in each tag-store points to
a unique entry in the data-store.
On cache hit, PIE-Cache behaves in the same way
as IE-Cache On cache miss, indexing mechanism of
PIE-Cache is same as IE-Cache but relocation behav-
ior is different. Assuming that the indexing mech-
anism has finalized the cache line (or candidate) at
each level. Then, candidate at each lower level of in-
dexing will be relocated to location of higher level
candidate along with the pointers. The last level can-
didate, which is selected for eviction, will be evicted
but its pointer will be assigned to the tag entry where
incoming memory address is being placed.
We explain the operation of eviction process in de-
tail using the example in Figure 1. The example uses
a small 3 ways cache with 8 cache lines per way. Let-
ters A-Z indicate the memory addresses stored in the
tag entry and numbers P1 − P24 denote the pointers
to data line. Figure 2 shows the eviction process to
place a memory block (Y ) in cache with a two level-
of-indexing (Mukhtar et al., 2020). In the first level,
indexing function using Y selects a tag-store’s entry
(or tag line) from each way (let us say, Y selects Q, A
and K). Then, one tag line is selected for relocation at
random, let us say Q is selected. In second level-of-
indexing, Q is given to indexing function to find line
in tag-store where it can be relocated, let us say these
lines are P and Z. Again, one cache line is selected at
random, say Z. As this is the last level-of-indexing, Z
is evicted. Afterwards, series of relocation are made
to accommodate the incoming memory address. Q
will relocate to Z’s position and similarly Y to Q loca-
tion. The pointer of each tag entry is also relocated to
each new line. The pointer associated with the evicted
cache line is assigned to the tag entry belonging to Y .
Final state of cache after eviction process would con-
tain Y with pointer P4 at the location of Q and Q with
P1 at location of Z.
3.1 Security Perspective
With the addition of pointers the security perspec-
tive remains unchanged in PIE-Cache compared to
IE-Cache. 1) It increases the size of eviction set,
which increases the effort of the attacker for profil-
ing the eviction set. 2) It adds conflicting members in
the eviction set that relocate within the cache instead
of eviction, we call these members as non-evicting
members of an eviction set. As these do not evict,
non-evicting members cannot be observed via mem-
ory access latency.
Novel Design for IE-Cache to Mitigate Conflict-based Cache-side Channel Attacks with Reduced Energy Consumption
677