Page MenuHomeFreeBSD

elfctl: prefix disable flags with "no"

Authored by emaste on Jan 13 2021, 6:15 PM.
Referenced Files
Unknown Object (File)
Thu, Nov 23, 10:20 AM
Unknown Object (File)
Wed, Nov 8, 3:09 PM
Unknown Object (File)
Wed, Nov 8, 3:29 AM
Unknown Object (File)
Oct 15 2023, 9:27 PM
Unknown Object (File)
Oct 13 2023, 8:19 PM
Unknown Object (File)
Oct 13 2023, 4:58 PM
Unknown Object (File)
Oct 10 2023, 6:27 PM
Unknown Object (File)
Oct 7 2023, 2:22 AM



Some ELF feature flags indicate a request to opt-out of some feature, for example NT_FREEBSD_FCTL_ASLR_DISABLE indicates that ASLR should be disabled for the tagged binary. Using "aslr" as the short name for the flag is confusing as it seems to indicate a request for ASLR to be enabled. Rename "noaslr," and similar for other opt-out flags.

Example output with the change:

File '/usr/bin/true' features:
noaslr 'Disable ASLR' is unset.
noprotmax 'Disable implicit PROT_MAX' is unset.
nostackgap 'Disable stack gap' is unset.
wxneeded 'Requires W+X mappings' is unset.
la48 'amd64: Limit user VA to 48bit' is unset.
noaslrstkgap 'Disable ASLR stack gap' is unset.

Discussed with manu and bapt who approve.

Diff Detail

rG FreeBSD src repository
Lint Not Applicable
Tests Not Applicable