Skip to main content

walk_library_list

Function walk_library_list 

Source
pub fn walk_library_list<P: PhysicalMemoryProvider>(
    reader: &ObjectReader<P>,
    task_addr: u64,
    pid: u32,
    process_name: &str,
) -> Result<Vec<SharedLibraryInfo>>
Expand description

Walk the VMA list for a single process and enumerate shared libraries.

Reads task_struct.mm → mm_struct.mmap and follows the vm_area_struct singly-linked list via vm_next. For each file-backed VMA, reads the file path from vm_file → f_path → dentry → d_name, filters for .so mappings, deduplicates by path, and classifies each library.

Returns an empty Vec if the process is a kernel thread (mm == NULL).