Example 2: Aligned .so file with a RELRO segment (Compliant)
In plain words
This example shows a compliant .so file: the GNU_RELRO segment ends exactly on a 16 KB page boundary, so the alignment check passes.
- Check formula: (VirtAddr + MemSiz) % 0x4000 == 0.
- Example result: (0xdfaf0 + 0x00510) % 0x4000 = 0xE0000 % 0x4000 == 0.
- A remainder of 0 means RELRO protection ends cleanly at the 0xE0000 page boundary.
- Writable data starting at 0xE0000 is left unaffected.
From the official text
In this example, the end of the GNURELRO segment falls on a 16 KB page boundary: Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align LOAD 0x000000 0x0000000000000000 0x0000000000000000 0x0cfaf0 0x0cfaf0 R E 0x4000 LOAD 0x0cfaf0 0x00000000000dfaf0 0x00000000000dfaf0 0x01510 0x03510 RW 0x4000 GNURELRO 0x0cfaf0 …
Read the full official text ↗ Open in the StoreRules library Ask whether your app complies
Change history
- · added
Developers' cases about this clause
No cases yet.