Namespaces

Enumerations

enum ReadMemorySize
Name Value
kExact 0
kMore 1
kLess 2

This is the type of the optional argument to Process::read_memory, below.

Defined at line 35 of file ../../src/lib/zxdump/include/lib/zxdump/task.h

Records

Functions

  • std::ostream & operator<< (std::ostream & os, const Error & error)

    This prints "op: status" with the status string.

    Defined at line 42 of file ../../src/lib/zxdump/error.cc

  • std::ostream & operator<< (std::ostream & os, const FdError & fd_error)

    This prints "op: Error text" (from strerror) or just "op".

    Defined at line 47 of file ../../src/lib/zxdump/error.cc

  • fit::result<Error, LiveHandle> GetRootJob ()

    Get the live root job of the running system, e.g. for TaskHolder::Insert.

    Defined at line 18 of file ../../src/lib/zxdump/not-fuchsia.cc

  • fit::result<Error, LiveHandle> GetInfoResource ()

    Get the live info resource handle of the running system.

    Defined at line 20 of file ../../src/lib/zxdump/not-fuchsia.cc

  • uint32_t NoteAlign (size_t note_size)

    Note headers, names, and descriptions are aligned in the file.

    The alignment padding is not included in n_namesz or n_descsz.

    Note n_namesz does include the mandatory NUL terminator.

    Defined at line 23 of file ../../src/lib/zxdump/core.h

  • size_t DefaultLimit ()

    This is the default limit on ET_CORE file size (in bytes), i.e. unlimited.

    Defined at line 24 of file ../../src/lib/zxdump/include/lib/zxdump/dump.h

  • bool IsLikelyElfMapping (const zx_info_maps_t & maps)

    This can be used from a zxdump::SegmentCallback function to guess if it's

    likely worthwhile to probe this mapping for containing the beginning of an

    ELF image. If this returns true, a zxdump::ProcessDump::FindBuildIdNote

    call on the segment is recommended.

    Defined at line 44 of file ../../src/lib/zxdump/elf-search.cc

  • std::ostream & operator<< (std::ostream & os, const ElfSearchError & error)

    This prints "op at vaddr: status" with the status string.

    Defined at line 55 of file ../../src/lib/zxdump/error.cc

  • fit::result<ElfSearchError, AnyElfPhdrsBuffer> DetectElf (Process & process, const zx_info_maps_t & segment)

    Try to detect an ELF image in this segment. If one is found and its phdrs

    are accessible, return a view into them from process.read_memory (which see

    about the lifetime of the buffer). Its ELF header can be fetched with

    process.read_memory

    <Elf

    ::Ehdr>(segment.base). If none is found, this

    returns success with an empty Buffer. It only returns error when

    process.read_memory gets an error, either because the segment memory can't

    be read or because the ELF header pointed to a Phdr range (not necessarily

    all in that segment) that can't be read.

    Defined at line 57 of file ../../src/lib/zxdump/elf-search.cc

  • fit::result<ElfSearchError, ElfIdentity> DetectElfIdentity (Process & process, const zx_info_maps_t & segment, const AnyElfPhdrs & phdrs)

    Given a detected ELF image, examine its program headers and memory to find

    the build ID note and DT_SONAME string if possible. The argument span

    doesn't have to be one returned by DetectElf (i.e. by process.read_memory)

    but it can be.

    Defined at line 94 of file ../../src/lib/zxdump/elf-search.cc

  • fit::result<ElfSearchError, ElfIdentity> DetectElfIdentity (Process & process, const zx_info_maps_t & segment, const AnyElfPhdrsBuffer & phdrs_buffer)

    This overload converts the variant buffer to the variant span.

    Defined at line 117 of file ../../src/lib/zxdump/include/lib/zxdump/elf-search.h

  • fit::result<ElfSearchError, MapsInfoSpan> ElfSearch (Process & process, MapsInfoSpan maps_info)

    This uses zxdump::DetectElf to search a range of the address space for an

    ELF image. It returns subspan of the argument span that holds an ELF image.

    It returns success with an empty span if none is found. It only returns

    error if zxdump::DetectElf or zxdump::DetectElfIdentity got an error.

    Defined at line 217 of file ../../src/lib/zxdump/elf-search.cc

  • template <typename Dump>
    std::ostream & operator<< (std::ostream & osconst DumpError<Dump> & error)

    This does either that or `os

    <

    <

    "op: "

    <

    <

    error.dump_error_`. If a

    particular error_value type of a Dump function is too generic for

    std::ostream::operator

    <

    <

    to be specialized as desired for it, then

    this can be explicitly specialized for the Dump type.

    Defined at line 386 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

Variables

const std::string_view kArchiveMagic

Defined at line 15 of file ../../src/lib/zxdump/job-archive.h

const size_t kMinimumElf

Defined at line 18 of file ../../src/lib/zxdump/core.h

const std::string_view kProcessInfoNoteName

Defined at line 31 of file ../../src/lib/zxdump/core.h

const std::string_view kProcessPropertyNoteName

Defined at line 32 of file ../../src/lib/zxdump/core.h

const std::string_view kThreadInfoNoteName

Defined at line 42 of file ../../src/lib/zxdump/core.h

const std::string_view kThreadPropertyNoteName

Defined at line 43 of file ../../src/lib/zxdump/core.h

const std::string_view kThreadStateNoteName

Defined at line 47 of file ../../src/lib/zxdump/core.h

const std::string_view kDateNoteName

Defined at line 53 of file ../../src/lib/zxdump/core.h

const std::string_view kSystemNoteName

Defined at line 56 of file ../../src/lib/zxdump/core.h

const std::string_view kKernelInfoNoteName

Defined at line 62 of file ../../src/lib/zxdump/core.h

const std::string_view kRemarkNotePrefix

Defined at line 67 of file ../../src/lib/zxdump/core.h

const __size_t kMinimumArchive

Defined at line 78 of file ../../src/lib/zxdump/job-archive.h

const std::string_view kJobInfoName

Defined at line 85 of file ../../src/lib/zxdump/job-archive.h

const std::string_view kJobPropertyName

Defined at line 88 of file ../../src/lib/zxdump/job-archive.h

const bool kIsSpan

Defined at line 286 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 286 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 286 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 286 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 286 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 286 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 286 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 286 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 286 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 286 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 286 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 287 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 289 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 289 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 289 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 289 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 289 of file ../../src/lib/zxdump/include/lib/zxdump/types.h

const bool kIsSpan

Defined at line 289 of file ../../src/lib/zxdump/include/lib/zxdump/types.h