scanelf(1)

NAME

scanelf - user-space utility to scan elf files

SYNTAX

scanelf [options] dir1 dir2 dirN...

DESCRIPTION
scanelf is a user-space utility to scan and list ELF types, as well as thier respctive PaX flags and filenames.

OPTIONS

-p, --path
    Scan all directories in PATH environment

-l, --ldpath
    Scan all directories in /etc/ld.so.conf

-R, --recursive
    Scan directories recursively

-m, --mount
    Don't recursively cross mount points

-y, --symlink
    Don't scan symlinks

-x, --pax
    Print PaX markings

-e, --header
    Print GNU_STACK markings

-t, --textrel
    Print TEXTREL information

-r, --rpath
    Print RPATH information

-n, --needed
    Print NEEDED information

-i, --interp
    Print INTERP information

-b, --bind
    Print BIND information

-S, --soname
    Print SONAME information

-s, --symbol <arg>
    Find a specified symbol

-N, --lib <arg>
    Find a specified library

-g, --gmatch
    Use strncmp to match libraries. (use with -N)

-T, --textrels <arg>
    Find a specified symbol Locate cause of TEXTREL

-a, --all
    Print all scanned info (-x -e -t -r -n -i -b)

-q, --quiet
    Only output 'bad' things.

-v, --verbose
    Be verbose (can be specified more than once)

-F, --format <arg>
    The format modifiers mainly correspond to the getopt counterparts. This option implies -a internally. Use specified format for output.
      %F    FILENAME
      %x    PaX-Flags
      %e    STACK/RELRO/LOAD
      %t    TEXTREL
      %r    RPATH
      %b    BINDINGS
      %n    NEEDED
      %i    INTERP
      %s    symbol
      %N    library
      %T    TEXTRELs
      %o    Elf Type
      %p    filename (with search path removed)
      %f    base filename

Prefix each modifier with '%' (verbose) or '#' (silent)

-f, --from <arg>
    Read input stream from a filename

-o, --file <arg>
    Write output stream to a filename

-B, --nobanner
    Don't display the header

-h, --help
    Print this help and exit

-V, --version
    Print version and exit

FILES

/etc/ld.so.conf

ENVIRONMENT VARIABLES

PATH
    When the -p option is used the environment variable PATH will be used.

EXAMPLES

To run this program the standard way type:

scanelf -p # Would print everything in your normal PATH.

scanelf -l -p -a -R  # Would print everything in library path and PATHs recursively.

scanelf -ltq # Would search every elf in your library paths for quality assurance problems with text relocations. use -p on native pie systems.

Alternativly you can run it like:

scanelf /bin /usr/bin /lib /sbin/insmod

REPORTING BUGS
Please include as much information as possible (using any available debugging options) and send bug reports to pax-utils <solar@gentoo.org> or <vapier@gentoo.org>

SEE ALSO
chpax(1), paxctl(1), pspax(1), readelf(1),

AUTHORS
scanelf was written by <solar@gentoo.org> and <vapier@gentoo.org>