Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 231799e6 authored by Eric Biggers's avatar Eric Biggers
Browse files

locksettings: use ArrayUtils.zeroize()

Since direct uses of Arrays.fill() can potentially be optimized out by
the compiler and also do not immediately clean the data cache, use
ArrayUtils.zeroize() instead which is more reliable.

Flag this fix, to comply with trunk-stable policies.  As usual for
flags, the flag is temporary and will be removed soon.

This CL is just a straightforward replacement of existing zeroization
code.  Later CLs will add missing zeroization in some places and
allocate arrays as non-movable as needed.

Bug: 320392352
Test: atest FrameworksServicesTests:com.android.server.locksettings
Flag: android.security.secure_array_zeroization
Change-Id: I9b9830ada97bc0a8cb0b661fd9bea0e54f925d2d
parent 81036dbf
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment