That's not a security feature though... We established that. Fair enough on the other points.
That's not a security feature though... We established that. Fair enough on the other points.
Only having 16 possible tags doesn't impact the deterministic protections we provide. One of the tag values is reserved for free data, internal metadata, etc. and can also be used as a form of 16 byte guard page. For heap allocation, we also dynamically omit the most recent adjacent non-free tags and the previous non-free tag for the current slot. There are 15 possible random values but 3 are dynamically omitted.
An attack often needs to use multiple invalid memory accesses where each one would have a 1/15 chance of success from probabilistic MTE alone. MTE gets combined with other probabilistic memory allocator protections. Our main memory allocator also has slot randomization and quarantine randomization.
A future revision of MTE could be easily be increased to 8 bits and it paves the path to having much larger memory tagging in the future too.
However, you need some form of code execution beforehand already for this attack, and more importantly it doesn't affect any of the deterministic guarantees of MTE. And those are the main appeal to GrapheneOS in the first place, preventing things like use-after-free by tagging the memory such that it simply can't be accessed anymore. So it's very much a security feature.
It literally was. MTE is a padlock with 16 combinations.
[0] https://github.com/GrapheneOS/hardened_malloc/blob/7481c8857...