Loading...
Searching...
No Matches
C++ Core API

Classes available to C++ Core Plugins. More...

Detailed Description

Classes available to C++ Core Plugins.

Topics

 Architectures
 Classes related to interacting with, hooking, and implementing Architectures .
 
 Basic Blocks
 Documentation for interacting with basic blocks .
 
 BinaryView
 Classes related to interacting with and implementing custom BinaryViews .
 
 CallingConvention
 
 
 Confidence
 
 
 DataBuffer
 
 
 DataRenderer
 
 
 Database
 
 
 DebugInfo
 
 
 Demangle
 
 
 DownloadProvider
 
 
 FileAccessor
 
 
 FileMetadata
 
 Flowgraph
 
 
 Function
 
 
 FunctionRecognizer
 
 
 High Level IL
 
 
 Interaction
 
 
 LinearDisassembly
 
 
 Logging
 
 
 Low Level IL
 
 
 MainThread
 
 
 Medium Level IL
 
 
 Metadata
 
 NameList
 
 
 Platform
 
 
 Plugin
 
 
 Plugin Manager
 
 
 RefCount
 
 
 Scripting Provider
 
 
 Secrets Provider
 
 
 Settings
 
 
 TempFile
 
 
 Transform
 
 
 TypeParser
 
 
 TypePrinter
 
 
 Types
 
 
 Undo
 
 
 Update
 
 
 Websocket Provider
 
 
 Workflows
 
 

Classes

class  BinaryNinja::User
 
class  BinaryNinja::ReportCollection
 
class  BinaryNinja::DisassemblyTextRenderer
 
class  BinaryNinja::Component
 Components are objects that can contain Functions and other Components. More...
 

Functions

std::string BinaryNinja::EscapeString (const std::string &s)
 
std::string BinaryNinja::UnescapeString (const std::string &s)
 
bool BinaryNinja::PreprocessSource (const std::string &source, const std::string &fileName, std::string &output, std::string &errors, const std::vector< std::string > &includeDirs=std::vector< std::string >())
 
void BinaryNinja::DisablePlugins ()
 
bool BinaryNinja::IsPluginsEnabled ()
 
bool BinaryNinja::InitPlugins (bool allowUserPlugins=true)
 
void BinaryNinja::InitCorePlugins ()
 
void BinaryNinja::InitUserPlugins ()
 
void BinaryNinja::InitRepoPlugins ()
 
std::string BinaryNinja::GetBundledPluginDirectory ()
 
void BinaryNinja::SetBundledPluginDirectory (const std::string &path)
 
std::string BinaryNinja::GetUserDirectory ()
 
std::string BinaryNinja::GetSettingsFileName ()
 
std::string BinaryNinja::GetRepositoriesDirectory ()
 
std::string BinaryNinja::GetInstallDirectory ()
 
std::string BinaryNinja::GetUserPluginDirectory ()
 
std::string BinaryNinja::GetPathRelativeToBundledPluginDirectory (const std::string &path)
 
std::string BinaryNinja::GetPathRelativeToUserPluginDirectory (const std::string &path)
 
std::string BinaryNinja::GetPathRelativeToUserDirectory (const std::string &path)
 
bool BinaryNinja::ExecuteWorkerProcess (const std::string &path, const std::vector< std::string > &args, const DataBuffer &input, std::string &output, std::string &errors, bool stdoutIsText=false, bool stderrIsText=true)
 
std::string BinaryNinja::GetVersionString ()
 
std::string BinaryNinja::GetLicensedUserEmail ()
 
std::string BinaryNinja::GetProduct ()
 
std::string BinaryNinja::GetProductType ()
 
std::string BinaryNinja::GetSerialNumber ()
 
int BinaryNinja::GetLicenseCount ()
 
bool BinaryNinja::IsUIEnabled ()
 
uint32_t BinaryNinja::GetBuildId ()
 
bool BinaryNinja::AreAutoUpdatesEnabled ()
 
void BinaryNinja::SetAutoUpdatesEnabled (bool enabled)
 
uint64_t BinaryNinja::GetTimeSinceLastUpdateCheck ()
 
void BinaryNinja::UpdatesChecked ()
 
std::string BinaryNinja::GetActiveUpdateChannel ()
 
void BinaryNinja::SetActiveUpdateChannel (const std::string &channel)
 
void BinaryNinja::SetCurrentPluginLoadOrder (BNPluginLoadOrder order)
 
void BinaryNinja::AddRequiredPluginDependency (const std::string &name)
 
void BinaryNinja::AddOptionalPluginDependency (const std::string &name)
 
template<typename T >
std::string BinaryNinja::CoreEnumName ()
 
template<typename T >
std::optional< std::string > BinaryNinja::CoreEnumToString (T value)
 
template<typename T >
std::optional< T > BinaryNinja::CoreEnumFromString (const std::string &value)
 
std::optional< size_t > BinaryNinja::FuzzyMatchSingle (const std::string &target, const std::string &query)
 

Class Documentation

◆ BinaryNinja::User

class BinaryNinja::User

Public Member Functions

 User (BNUser *user)
 
std::string GetName ()
 
std::string GetEmail ()
 
std::string GetId ()
 
- Public Member Functions inherited from BinaryNinja::CoreRefCountObject< BNUser, BNNewUserReference, BNFreeUser >
 CoreRefCountObject ()
 
virtual ~CoreRefCountObject ()
 
BNUserGetObject () const
 
void AddRef ()
 
void Release ()
 
void AddRefForRegistration ()
 
void ReleaseForRegistration ()
 
void AddRefForCallback ()
 
void ReleaseForCallback ()
 

Additional Inherited Members

- Static Public Member Functions inherited from BinaryNinja::CoreRefCountObject< BNUser, BNNewUserReference, BNFreeUser >
static BNUserGetObject (CoreRefCountObject *obj)
 
static BNUserGetObject (const CoreRefCountObject *obj)
 
- Public Attributes inherited from BinaryNinja::CoreRefCountObject< BNUser, BNNewUserReference, BNFreeUser >
std::atomic< int > m_refs
 
bool m_registeredRef
 
BNUserm_object
 

Constructor & Destructor Documentation

◆ User()

User::User ( BNUser * user)

Member Function Documentation

◆ GetName()

string User::GetName ( )

◆ GetEmail()

string User::GetEmail ( )

◆ GetId()

string User::GetId ( )

◆ BinaryNinja::ReportCollection

class BinaryNinja::ReportCollection

Public Member Functions

 ReportCollection ()
 
 ReportCollection (BNReportCollection *reports)
 
size_t GetCount () const
 
BNReportType GetType (size_t i) const
 
Ref< BinaryViewGetView (size_t i) const
 
std::string GetTitle (size_t i) const
 
std::string GetContents (size_t i) const
 
std::string GetPlainText (size_t i) const
 
Ref< FlowGraphGetFlowGraph (size_t i) const
 
void AddPlainTextReport (Ref< BinaryView > view, const std::string &title, const std::string &contents)
 
void AddMarkdownReport (Ref< BinaryView > view, const std::string &title, const std::string &contents, const std::string &plainText="")
 
void AddHTMLReport (Ref< BinaryView > view, const std::string &title, const std::string &contents, const std::string &plainText="")
 
void AddGraphReport (Ref< BinaryView > view, const std::string &title, Ref< FlowGraph > graph)
 
void UpdateFlowGraph (size_t i, Ref< FlowGraph > graph)
 
- Public Member Functions inherited from BinaryNinja::CoreRefCountObject< BNReportCollection, BNNewReportCollectionReference, BNFreeReportCollection >
 CoreRefCountObject ()
 
virtual ~CoreRefCountObject ()
 
BNReportCollectionGetObject () const
 
void AddRef ()
 
void Release ()
 
void AddRefForRegistration ()
 
void ReleaseForRegistration ()
 
void AddRefForCallback ()
 
void ReleaseForCallback ()
 

Additional Inherited Members

- Static Public Member Functions inherited from BinaryNinja::CoreRefCountObject< BNReportCollection, BNNewReportCollectionReference, BNFreeReportCollection >
static BNReportCollectionGetObject (CoreRefCountObject *obj)
 
static BNReportCollectionGetObject (const CoreRefCountObject *obj)
 
- Public Attributes inherited from BinaryNinja::CoreRefCountObject< BNReportCollection, BNNewReportCollectionReference, BNFreeReportCollection >
std::atomic< int > m_refs
 
bool m_registeredRef
 
BNReportCollectionm_object
 

Constructor & Destructor Documentation

◆ ReportCollection() [1/2]

ReportCollection::ReportCollection ( )

◆ ReportCollection() [2/2]

ReportCollection::ReportCollection ( BNReportCollection * reports)

Member Function Documentation

◆ GetCount()

size_t ReportCollection::GetCount ( ) const

◆ GetType()

BNReportType ReportCollection::GetType ( size_t i) const

◆ GetView()

Ref< BinaryView > ReportCollection::GetView ( size_t i) const

◆ GetTitle()

string ReportCollection::GetTitle ( size_t i) const

◆ GetContents()

string ReportCollection::GetContents ( size_t i) const

◆ GetPlainText()

string ReportCollection::GetPlainText ( size_t i) const

◆ GetFlowGraph()

Ref< FlowGraph > ReportCollection::GetFlowGraph ( size_t i) const

◆ AddPlainTextReport()

void ReportCollection::AddPlainTextReport ( Ref< BinaryView > view,
const std::string & title,
const std::string & contents )

◆ AddMarkdownReport()

void ReportCollection::AddMarkdownReport ( Ref< BinaryView > view,
const std::string & title,
const std::string & contents,
const std::string & plainText = "" )

◆ AddHTMLReport()

void ReportCollection::AddHTMLReport ( Ref< BinaryView > view,
const std::string & title,
const std::string & contents,
const std::string & plainText = "" )

◆ AddGraphReport()

void ReportCollection::AddGraphReport ( Ref< BinaryView > view,
const std::string & title,
Ref< FlowGraph > graph )

◆ UpdateFlowGraph()

void ReportCollection::UpdateFlowGraph ( size_t i,
Ref< FlowGraph > graph )

◆ BinaryNinja::DisassemblyTextRenderer

class BinaryNinja::DisassemblyTextRenderer

Public Member Functions

 DisassemblyTextRenderer (Function *func, DisassemblySettings *settings=nullptr)
 
 DisassemblyTextRenderer (LowLevelILFunction *func, DisassemblySettings *settings=nullptr)
 
 DisassemblyTextRenderer (MediumLevelILFunction *func, DisassemblySettings *settings=nullptr)
 
 DisassemblyTextRenderer (HighLevelILFunction *func, DisassemblySettings *settings=nullptr)
 
 DisassemblyTextRenderer (BNDisassemblyTextRenderer *renderer)
 
Ref< FunctionGetFunction () const
 
Ref< LowLevelILFunctionGetLowLevelILFunction () const
 
Ref< MediumLevelILFunctionGetMediumLevelILFunction () const
 
Ref< HighLevelILFunctionGetHighLevelILFunction () const
 
Ref< BasicBlockGetBasicBlock () const
 
Ref< ArchitectureGetArchitecture () const
 
Ref< DisassemblySettingsGetSettings () const
 
void SetBasicBlock (BasicBlock *block)
 
void SetArchitecture (Architecture *arch)
 
void SetSettings (DisassemblySettings *settings)
 
virtual bool IsIL () const
 
virtual bool HasDataFlow () const
 
virtual void GetInstructionAnnotations (std::vector< InstructionTextToken > &tokens, uint64_t addr)
 
virtual bool GetInstructionText (uint64_t addr, size_t &len, std::vector< DisassemblyTextLine > &lines)
 
std::vector< DisassemblyTextLinePostProcessInstructionTextLines (uint64_t addr, size_t len, const std::vector< DisassemblyTextLine > &lines, const std::string &indentSpaces="")
 
virtual bool GetDisassemblyText (uint64_t addr, size_t &len, std::vector< DisassemblyTextLine > &lines)
 
void ResetDeduplicatedComments ()
 
bool AddSymbolToken (std::vector< InstructionTextToken > &tokens, uint64_t addr, size_t size, size_t operand)
 
void AddStackVariableReferenceTokens (std::vector< InstructionTextToken > &tokens, const StackVariableReference &ref)
 
void AddIntegerToken (std::vector< InstructionTextToken > &tokens, const InstructionTextToken &token, Architecture *arch, uint64_t addr)
 
void WrapComment (DisassemblyTextLine &line, std::vector< DisassemblyTextLine > &lines, const std::string &comment, bool hasAutoAnnotations, const std::string &leadingSpaces=" ", const std::string &indentSpaces="")
 
- Public Member Functions inherited from BinaryNinja::CoreRefCountObject< BNDisassemblyTextRenderer, BNNewDisassemblyTextRendererReference, BNFreeDisassemblyTextRenderer >
 CoreRefCountObject ()
 
virtual ~CoreRefCountObject ()
 
BNDisassemblyTextRendererGetObject () const
 
void AddRef ()
 
void Release ()
 
void AddRefForRegistration ()
 
void ReleaseForRegistration ()
 
void AddRefForCallback ()
 
void ReleaseForCallback ()
 

Static Public Member Functions

static BNSymbolDisplayResult AddSymbolTokenStatic (std::vector< InstructionTextToken > &tokens, uint64_t addr, size_t size, size_t operand, BinaryView *data, size_t maxSymbolWidth, Function *func, uint8_t confidence=255, BNSymbolDisplayType symbolDisplay=DisplaySymbolOnly, BNOperatorPrecedence precedence=TopLevelOperatorPrecedence, uint64_t instrAddr=-1, uint64_t exprIndex=-1)
 
static bool IsIntegerToken (BNInstructionTextTokenType type)
 
static std::string GetDisplayStringForInteger (Ref< BinaryView > binaryView, BNIntegerDisplayType type, uint64_t value, size_t inputWidth, bool isSigned=true)
 
static std::string GetStringLiteralPrefix (BNStringType type)
 
- Static Public Member Functions inherited from BinaryNinja::CoreRefCountObject< BNDisassemblyTextRenderer, BNNewDisassemblyTextRendererReference, BNFreeDisassemblyTextRenderer >
static BNDisassemblyTextRendererGetObject (CoreRefCountObject *obj)
 
static BNDisassemblyTextRendererGetObject (const CoreRefCountObject *obj)
 

Additional Inherited Members

- Public Attributes inherited from BinaryNinja::CoreRefCountObject< BNDisassemblyTextRenderer, BNNewDisassemblyTextRendererReference, BNFreeDisassemblyTextRenderer >
std::atomic< int > m_refs
 
bool m_registeredRef
 
BNDisassemblyTextRendererm_object
 

Constructor & Destructor Documentation

◆ DisassemblyTextRenderer() [1/5]

DisassemblyTextRenderer::DisassemblyTextRenderer ( Function * func,
DisassemblySettings * settings = nullptr )

◆ DisassemblyTextRenderer() [2/5]

DisassemblyTextRenderer::DisassemblyTextRenderer ( LowLevelILFunction * func,
DisassemblySettings * settings = nullptr )

◆ DisassemblyTextRenderer() [3/5]

DisassemblyTextRenderer::DisassemblyTextRenderer ( MediumLevelILFunction * func,
DisassemblySettings * settings = nullptr )

◆ DisassemblyTextRenderer() [4/5]

DisassemblyTextRenderer::DisassemblyTextRenderer ( HighLevelILFunction * func,
DisassemblySettings * settings = nullptr )

◆ DisassemblyTextRenderer() [5/5]

DisassemblyTextRenderer::DisassemblyTextRenderer ( BNDisassemblyTextRenderer * renderer)

Member Function Documentation

◆ GetFunction()

Ref< Function > DisassemblyTextRenderer::GetFunction ( ) const

◆ GetLowLevelILFunction()

Ref< LowLevelILFunction > DisassemblyTextRenderer::GetLowLevelILFunction ( ) const

◆ GetMediumLevelILFunction()

Ref< MediumLevelILFunction > DisassemblyTextRenderer::GetMediumLevelILFunction ( ) const

◆ GetHighLevelILFunction()

Ref< HighLevelILFunction > DisassemblyTextRenderer::GetHighLevelILFunction ( ) const

◆ GetBasicBlock()

Ref< BasicBlock > DisassemblyTextRenderer::GetBasicBlock ( ) const

◆ GetArchitecture()

Ref< Architecture > DisassemblyTextRenderer::GetArchitecture ( ) const

◆ GetSettings()

Ref< DisassemblySettings > DisassemblyTextRenderer::GetSettings ( ) const

◆ SetBasicBlock()

void DisassemblyTextRenderer::SetBasicBlock ( BasicBlock * block)

◆ SetArchitecture()

void DisassemblyTextRenderer::SetArchitecture ( Architecture * arch)

◆ SetSettings()

void DisassemblyTextRenderer::SetSettings ( DisassemblySettings * settings)

◆ IsIL()

bool DisassemblyTextRenderer::IsIL ( ) const
virtual

◆ HasDataFlow()

bool DisassemblyTextRenderer::HasDataFlow ( ) const
virtual

◆ GetInstructionAnnotations()

void DisassemblyTextRenderer::GetInstructionAnnotations ( std::vector< InstructionTextToken > & tokens,
uint64_t addr )
virtual

◆ GetInstructionText()

bool DisassemblyTextRenderer::GetInstructionText ( uint64_t addr,
size_t & len,
std::vector< DisassemblyTextLine > & lines )
virtual

◆ PostProcessInstructionTextLines()

vector< DisassemblyTextLine > DisassemblyTextRenderer::PostProcessInstructionTextLines ( uint64_t addr,
size_t len,
const std::vector< DisassemblyTextLine > & lines,
const std::string & indentSpaces = "" )

◆ GetDisassemblyText()

bool DisassemblyTextRenderer::GetDisassemblyText ( uint64_t addr,
size_t & len,
std::vector< DisassemblyTextLine > & lines )
virtual

◆ ResetDeduplicatedComments()

void DisassemblyTextRenderer::ResetDeduplicatedComments ( )

◆ AddSymbolToken()

bool DisassemblyTextRenderer::AddSymbolToken ( std::vector< InstructionTextToken > & tokens,
uint64_t addr,
size_t size,
size_t operand )

◆ AddSymbolTokenStatic()

BNSymbolDisplayResult DisassemblyTextRenderer::AddSymbolTokenStatic ( std::vector< InstructionTextToken > & tokens,
uint64_t addr,
size_t size,
size_t operand,
BinaryView * data,
size_t maxSymbolWidth,
Function * func,
uint8_t confidence = 255,
BNSymbolDisplayType symbolDisplay = DisplaySymbolOnly,
BNOperatorPrecedence precedence = TopLevelOperatorPrecedence,
uint64_t instrAddr = -1,
uint64_t exprIndex = -1 )
static

◆ AddStackVariableReferenceTokens()

void DisassemblyTextRenderer::AddStackVariableReferenceTokens ( std::vector< InstructionTextToken > & tokens,
const StackVariableReference & ref )

◆ IsIntegerToken()

bool DisassemblyTextRenderer::IsIntegerToken ( BNInstructionTextTokenType type)
static

◆ AddIntegerToken()

void DisassemblyTextRenderer::AddIntegerToken ( std::vector< InstructionTextToken > & tokens,
const InstructionTextToken & token,
Architecture * arch,
uint64_t addr )

◆ WrapComment()

void DisassemblyTextRenderer::WrapComment ( DisassemblyTextLine & line,
std::vector< DisassemblyTextLine > & lines,
const std::string & comment,
bool hasAutoAnnotations,
const std::string & leadingSpaces = "  ",
const std::string & indentSpaces = "" )

◆ GetDisplayStringForInteger()

string DisassemblyTextRenderer::GetDisplayStringForInteger ( Ref< BinaryView > binaryView,
BNIntegerDisplayType type,
uint64_t value,
size_t inputWidth,
bool isSigned = true )
static

◆ GetStringLiteralPrefix()

string DisassemblyTextRenderer::GetStringLiteralPrefix ( BNStringType type)
static

◆ BinaryNinja::Component

class BinaryNinja::Component

Components are objects that can contain Functions and other Components.

Note
Components should not be instantiated directly. Instead use BinaryView::CreateComponent()

They can be queried for information about the functions contained within them.

Components have a Guid, which persistent across saves and loads of the database, and should be used for retrieving components when such is required and a reference to the Component cannot be held.

Public Member Functions

 Component (BNComponent *type)
 
std::string GetGuid ()
 Get the unique identifier for this component.
 
bool operator== (const Component &other) const
 
bool operator!= (const Component &other) const
 
Ref< BinaryViewGetView ()
 
std::string GetDisplayName ()
 The displayed name for the component.
 
std::string GetName ()
 The original name for the component.
 
void SetName (const std::string &name)
 Set the name for the component.
 
Ref< ComponentGetParent ()
 Get the parent component.
 
bool AddFunction (Ref< Function > func)
 Add a function to this component.
 
bool AddComponent (Ref< Component > component)
 Move a component to this component.
 
bool AddDataVariable (DataVariable dataVariable)
 
bool RemoveComponent (Ref< Component > component)
 Remove a Component from this Component, moving it to the root component.
 
bool RemoveFunction (Ref< Function > func)
 Remove a function.
 
bool RemoveDataVariable (DataVariable dataVariable)
 
std::vector< Ref< Type > > GetReferencedTypes ()
 Get a list of types referenced by the functions in this Component.
 
std::vector< Ref< Component > > GetContainedComponents ()
 Get a list of components contained by this component.
 
std::vector< Ref< Function > > GetContainedFunctions ()
 Get a list of functions contained within this Component.
 
std::vector< DataVariableGetContainedDataVariables ()
 Get a list of datavariables added to this component.
 
std::vector< DataVariableGetReferencedDataVariables ()
 Get a list of DataVariables referenced by the functions in this Component.
 
- Public Member Functions inherited from BinaryNinja::CoreRefCountObject< BNComponent, BNNewComponentReference, BNFreeComponent >
 CoreRefCountObject ()
 
virtual ~CoreRefCountObject ()
 
BNComponentGetObject () const
 
void AddRef ()
 
void Release ()
 
void AddRefForRegistration ()
 
void ReleaseForRegistration ()
 
void AddRefForCallback ()
 
void ReleaseForCallback ()
 

Additional Inherited Members

- Static Public Member Functions inherited from BinaryNinja::CoreRefCountObject< BNComponent, BNNewComponentReference, BNFreeComponent >
static BNComponentGetObject (CoreRefCountObject *obj)
 
static BNComponentGetObject (const CoreRefCountObject *obj)
 
- Public Attributes inherited from BinaryNinja::CoreRefCountObject< BNComponent, BNNewComponentReference, BNFreeComponent >
std::atomic< int > m_refs
 
bool m_registeredRef
 
BNComponentm_object
 

Constructor & Destructor Documentation

◆ Component()

Component::Component ( BNComponent * type)

Member Function Documentation

◆ GetGuid()

std::string Component::GetGuid ( )

Get the unique identifier for this component.

Returns
Component GUID

◆ operator==()

bool Component::operator== ( const Component & other) const

◆ operator!=()

bool Component::operator!= ( const Component & other) const

◆ GetView()

Ref< BinaryView > Component::GetView ( )

◆ GetDisplayName()

std::string Component::GetDisplayName ( )

The displayed name for the component.

Thread Safe:
No

This can differ from the GetOriginalName() value if the parent component also contains other components with the same name.

Subsequent duplicates will return the original name with " (1)", " (2)" and so on appended.

This name can change whenever a different duplicate is removed.

Note
For looking up Components, utilizing Guid is highly recommended, as it will *always* map to this component, and as Guid lookups are faster by nature.
Returns
Component name

◆ GetName()

std::string Component::GetName ( )

The original name for the component.

Thread Safe:
No

This may differ from Component::GetName() whenever the parent contains Components with the same original name.

This function will always return the value originally set for this Component.

Returns
Component name

◆ SetName()

void Component::SetName ( const std::string & name)

Set the name for the component.

Thread Safe:
No
See also
GetName(), GetOriginalName()
Parameters
nameNew component name.

◆ GetParent()

Ref< Component > Component::GetParent ( )

Get the parent component.

If it's a top level component, it will return the "root" Component.

Thread Safe:
Yes
Returns
Parent Component

◆ AddFunction()

bool Component::AddFunction ( Ref< Function > func)

Add a function to this component.

Thread Safe:
Yes
Parameters
funcFunction to add.
Returns
True if the function was successfully added.

◆ AddComponent()

bool Component::AddComponent ( Ref< Component > component)

Move a component to this component.

Thread Safe:
Yes
Parameters
componentComponent to add.
Returns
True if the component was successfully added.

◆ AddDataVariable()

bool Component::AddDataVariable ( DataVariable dataVariable)

◆ RemoveComponent()

bool Component::RemoveComponent ( Ref< Component > component)

Remove a Component from this Component, moving it to the root component.

Thread Safe:
Yes

This will not remove a component from the tree entirely.

See also
BinaryView::GetRootComponent(), BinaryView::RemoveComponent()
Parameters
componentComponent to remove
Returns
True if the component was successfully removed

◆ RemoveFunction()

bool Component::RemoveFunction ( Ref< Function > func)

Remove a function.

Thread Safe:
Yes
Parameters
funcFunction to remove
Returns
True if the function was successfully removed.

◆ RemoveDataVariable()

bool Component::RemoveDataVariable ( DataVariable dataVariable)

◆ GetReferencedTypes()

std::vector< Ref< Type > > Component::GetReferencedTypes ( )

Get a list of types referenced by the functions in this Component.

Thread Safe:
Yes
Returns
vector of Type objects

◆ GetContainedComponents()

std::vector< Ref< Component > > Component::GetContainedComponents ( )

Get a list of components contained by this component.

Thread Safe:
Yes
Returns
vector of Component objects

◆ GetContainedFunctions()

std::vector< Ref< Function > > Component::GetContainedFunctions ( )

Get a list of functions contained within this Component.

Thread Safe:
Yes
Returns
vector of Function objects

◆ GetContainedDataVariables()

std::vector< DataVariable > Component::GetContainedDataVariables ( )

Get a list of datavariables added to this component.

Thread Safe:
Yes
Returns
list of DataVariables

◆ GetReferencedDataVariables()

std::vector< DataVariable > Component::GetReferencedDataVariables ( )

Get a list of DataVariables referenced by the functions in this Component.

Thread Safe:
Yes
Returns
vector of DataVariable objects

Function Documentation

◆ EscapeString()

std::string BinaryNinja::EscapeString ( const std::string & s)

◆ UnescapeString()

std::string BinaryNinja::UnescapeString ( const std::string & s)

◆ PreprocessSource()

bool BinaryNinja::PreprocessSource ( const std::string & source,
const std::string & fileName,
std::string & output,
std::string & errors,
const std::vector< std::string > & includeDirs = std::vector< std::string >() )

◆ DisablePlugins()

void BinaryNinja::DisablePlugins ( )

◆ IsPluginsEnabled()

bool BinaryNinja::IsPluginsEnabled ( )

◆ InitPlugins()

bool BinaryNinja::InitPlugins ( bool allowUserPlugins = true)

◆ InitCorePlugins()

void BinaryNinja::InitCorePlugins ( )
Deprecated
Use `InitPlugins()`

◆ InitUserPlugins()

void BinaryNinja::InitUserPlugins ( )
Deprecated
Use `InitPlugins()`

◆ InitRepoPlugins()

void BinaryNinja::InitRepoPlugins ( )

◆ GetBundledPluginDirectory()

string BinaryNinja::GetBundledPluginDirectory ( )

◆ SetBundledPluginDirectory()

void BinaryNinja::SetBundledPluginDirectory ( const std::string & path)

◆ GetUserDirectory()

string BinaryNinja::GetUserDirectory ( void )

◆ GetSettingsFileName()

string BinaryNinja::GetSettingsFileName ( )

◆ GetRepositoriesDirectory()

string BinaryNinja::GetRepositoriesDirectory ( )

◆ GetInstallDirectory()

string BinaryNinja::GetInstallDirectory ( )

◆ GetUserPluginDirectory()

string BinaryNinja::GetUserPluginDirectory ( )

◆ GetPathRelativeToBundledPluginDirectory()

std::string BinaryNinja::GetPathRelativeToBundledPluginDirectory ( const std::string & path)

◆ GetPathRelativeToUserPluginDirectory()

std::string BinaryNinja::GetPathRelativeToUserPluginDirectory ( const std::string & path)

◆ GetPathRelativeToUserDirectory()

std::string BinaryNinja::GetPathRelativeToUserDirectory ( const std::string & path)

◆ ExecuteWorkerProcess()

bool BinaryNinja::ExecuteWorkerProcess ( const std::string & path,
const std::vector< std::string > & args,
const DataBuffer & input,
std::string & output,
std::string & errors,
bool stdoutIsText = false,
bool stderrIsText = true )

◆ GetVersionString()

string BinaryNinja::GetVersionString ( )

◆ GetLicensedUserEmail()

string BinaryNinja::GetLicensedUserEmail ( )

◆ GetProduct()

string BinaryNinja::GetProduct ( )

◆ GetProductType()

string BinaryNinja::GetProductType ( )

◆ GetSerialNumber()

string BinaryNinja::GetSerialNumber ( )

◆ GetLicenseCount()

int BinaryNinja::GetLicenseCount ( )

◆ IsUIEnabled()

bool BinaryNinja::IsUIEnabled ( )

◆ GetBuildId()

uint32_t BinaryNinja::GetBuildId ( )

◆ AreAutoUpdatesEnabled()

bool BinaryNinja::AreAutoUpdatesEnabled ( )

◆ SetAutoUpdatesEnabled()

void BinaryNinja::SetAutoUpdatesEnabled ( bool enabled)

◆ GetTimeSinceLastUpdateCheck()

uint64_t BinaryNinja::GetTimeSinceLastUpdateCheck ( )

◆ UpdatesChecked()

void BinaryNinja::UpdatesChecked ( )

◆ GetActiveUpdateChannel()

string BinaryNinja::GetActiveUpdateChannel ( )

◆ SetActiveUpdateChannel()

void BinaryNinja::SetActiveUpdateChannel ( const std::string & channel)

◆ SetCurrentPluginLoadOrder()

void BinaryNinja::SetCurrentPluginLoadOrder ( BNPluginLoadOrder order)

◆ AddRequiredPluginDependency()

void BinaryNinja::AddRequiredPluginDependency ( const std::string & name)

◆ AddOptionalPluginDependency()

void BinaryNinja::AddOptionalPluginDependency ( const std::string & name)

◆ CoreEnumName()

template<typename T >
std::string BinaryNinja::CoreEnumName ( )

◆ CoreEnumToString()

template<typename T >
std::optional< std::string > BinaryNinja::CoreEnumToString ( T value)

◆ CoreEnumFromString()

template<typename T >
std::optional< T > BinaryNinja::CoreEnumFromString ( const std::string & value)

◆ FuzzyMatchSingle()

std::optional< size_t > BinaryNinja::FuzzyMatchSingle ( const std::string & target,
const std::string & query )