IDA Domain Python API
ida_domain.Database Class Reference

Inherits object.

Public Member Functions

def __init__ (self)
 
def open (self, *args)
 
def is_open (self)
 
def close (self, save)
 
def set_current_ea (self, ea)
 
def get_current_ea (self)
 

Properties

 thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
 
 segments = property(_ida_domain.Database_segments_get, doc=)
 
 functions = property(_ida_domain.Database_functions_get, doc=)
 
 basic_blocks = property(_ida_domain.Database_basic_blocks_get, doc=)
 
 instructions = property(_ida_domain.Database_instructions_get, doc=)
 
 comments = property(_ida_domain.Database_comments_get, doc=)
 
 strings = property(_ida_domain.Database_strings_get, doc=)
 
 names = property(_ida_domain.Database_names_get, doc=)
 
 types = property(_ida_domain.Database_types_get, doc=)
 
 bytes = property(_ida_domain.Database_bytes_get, doc=)
 
 signature_files = property(_ida_domain.Database_signature_files_get, doc=)
 
 xrefs = property(_ida_domain.Database_xrefs_get, doc=)
 
 maximum_ea = property(_get_maximum_ea, doc=)
 
 minimum_ea = property(_get_minimum_ea, doc=)
 
 entry_point = property(_get_entry_point, doc=)
 
 metadata = property(_get_metadata, doc=)
 

Detailed Description

Provides access and control over the loaded IDA database.

Constructor & Destructor Documentation

◆ __init__()

def ida_domain.Database.__init__ (   self)
__init__(self) -> Database
Constructs a new interface to the IDA database.

When running inside IDA, this refers to the currently open database. Use open() to load a new database when using IDA as a library.

Member Function Documentation

◆ close()

def ida_domain.Database.close (   self,
  save 
)
close(self, save)
Closes the currently open database.

:param save: If true, saves changes before closing; otherwise, discards them.

◆ get_current_ea()

def ida_domain.Database.get_current_ea (   self)
get_current_ea(self) -> ea_t
Get the current effective address (equivalent to the "screen EA" in IDA GUI).

:return: The current effective address.

◆ is_open()

def ida_domain.Database.is_open (   self)
is_open(self) -> bool
Checks if the database is loaded.

:return: True if a database is open, false otherwise.

◆ open()

def ida_domain.Database.open (   self,
args 
)
open(self, db_path, db_args=IdaCommandBuilder()) -> bool
Opens a database from the specified file path.

:param db_path: Path to the input file.
:param db_args: Command builder responsible for passing arguments to IDA kernel.
:return: True if the database was successfully opened, false otherwise.

◆ set_current_ea()

def ida_domain.Database.set_current_ea (   self,
  ea 
)
set_current_ea(self, ea) -> bool
Sets the current effective address (equivalent to the "screen EA" in IDA GUI).

:param ea: 
:return: True if the address was successfully set, false otherwise.

Property Documentation

◆ basic_blocks

ida_domain.Database.basic_blocks = property(_ida_domain.Database_basic_blocks_get, doc=)
static

◆ bytes

ida_domain.Database.bytes = property(_ida_domain.Database_bytes_get, doc=)
static

◆ comments

ida_domain.Database.comments = property(_ida_domain.Database_comments_get, doc=)
static

◆ entry_point

ida_domain.Database.entry_point = property(_get_entry_point, doc=)
static

◆ functions

ida_domain.Database.functions = property(_ida_domain.Database_functions_get, doc=)
static

◆ instructions

ida_domain.Database.instructions = property(_ida_domain.Database_instructions_get, doc=)
static

◆ maximum_ea

ida_domain.Database.maximum_ea = property(_get_maximum_ea, doc=)
static

◆ metadata

ida_domain.Database.metadata = property(_get_metadata, doc=)
static

◆ minimum_ea

ida_domain.Database.minimum_ea = property(_get_minimum_ea, doc=)
static

◆ names

ida_domain.Database.names = property(_ida_domain.Database_names_get, doc=)
static

◆ segments

ida_domain.Database.segments = property(_ida_domain.Database_segments_get, doc=)
static

◆ signature_files

ida_domain.Database.signature_files = property(_ida_domain.Database_signature_files_get, doc=)
static

◆ strings

ida_domain.Database.strings = property(_ida_domain.Database_strings_get, doc=)
static

◆ thisown

ida_domain.Database.thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
static

◆ types

ida_domain.Database.types = property(_ida_domain.Database_types_get, doc=)
static

◆ xrefs

ida_domain.Database.xrefs = property(_ida_domain.Database_xrefs_get, doc=)
static