Heimdall

Getting started:

  • Overview
  • Installation
  • Basic Usage
  • Heimdall Core
  • Future Plans for Heimdall
  • Contributing

API Reference:

  • heimdall package
  • heimdall.core package
  • heimdall.cli package
  • heimdall.os_related.base_os package
  • heimdall.os_related.macos package
  • heimdall.os_related.linux package
    • Submodules
    • heimdall.os_related.linux.filesystem module
    • heimdall.os_related.linux.linux_client module
    • heimdall.os_related.linux.processes module
    • Module contents
  • heimdall.os_related.windows package
  • heimdall.utils package
Heimdall
  • heimdall package
  • heimdall.os_related package
  • heimdall.os_related.linux package
  • View page source

heimdall.os_related.linux package

Submodules

heimdall.os_related.linux.filesystem module

class heimdall.os_related.linux.filesystem.LinuxFileSystem[source]

Bases: object

Provides utilities for interacting with the Linux file system, specifically for dentry operations.

static dentry_full_path(dentry: Symbol) → str[source]

Return the full path of a dentry by traversing its parent hierarchy.

Parameters:

dentry (Symbol) – The dentry for which to retrieve the full path.

Returns:

The full path of the dentry.

Return type:

str

static dentry_traversal(dentry: Symbol) → Iterator[Any][source]

Traverse the dentry hierarchy starting from a given dentry.

Parameters:

dentry (Symbol) – The dentry from which to start traversal.

Yields:

Symbol – Each dentry in the hierarchy from the given dentry up to the root.

heimdall.os_related.linux.linux_client module

class heimdall.os_related.linux.linux_client.LinuxClient(vmi: libvmi.Libvmi, profile: Path)[source]

Bases: HeimdallClient

__init__(vmi: libvmi.Libvmi, profile: Path)[source]

Initialize LinuxClient.

property kslide: int

Return kernel slide value.

property processes: LinuxProcesses

Return Linux processes.

heimdall.os_related.linux.processes module

class heimdall.os_related.linux.processes.LinuxProcess(ks: Any, ctx: Context)[source]

Bases: Process

Represents a Linux process, providing access to process attributes such as name, PID, and path.

property name: str

The name of the process.

Returns:

The name of the process.

Return type:

str

property path: str

The file path associated with the process executable.

Returns:

The full path of the executable file, or the process name if path retrieval fails.

Return type:

str

property pid: int

The process ID (PID).

Returns:

The process ID.

Return type:

int

class heimdall.os_related.linux.processes.LinuxProcesses(heimdall_client: HeimdallClient)[source]

Bases: Processes

Manages Linux processes, allowing listing of all processes in the system.

__init__(heimdall_client: HeimdallClient)[source]

Initialize the LinuxProcesses manager with a Heimdall client.

Parameters:

heimdall_client (HeimdallClient) – The client used for interacting with the system kernel.

list() → list[LinuxProcess][source]

List all processes.

Returns:

A list of all Linux processes.

Return type:

list of LinuxProcess

Module contents

Previous Next

© Copyright 2024, Netanel Cohen.

Built with Sphinx using a theme provided by Read the Docs.