KUNAI Static Analyzer
Kunai is a library for doing static binary analysis of Dalvik.
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | List of all members
KUNAI::DEX::Dex Class Reference

Abstraction of a DEX object, the class offers the analyst a parser, a disassembler and an analysis object. More...

#include <dex.hpp>

Public Member Functions

 Dex (std::string &dex_file_path)
 Constructor of the Dex object, we obtain a path to the DEX file to analyze.
 
 ~Dex ()
 Destructor of the Dex object, release any memory or files here in case it is needed.
 
bool get_parsing_correct () const
 Was parsing process correct?
 
Parserget_parser ()
 get a pointer to the DEX parser with all the headers
 
DexDisassemblerget_dex_disassembler ()
 Get the disassembler of the DEX file.
 
Analysisget_analysis (bool create_xrefs)
 Get the analysis object this needs the disassembly and the parser, the dex will be disassembled in case this function is called.
 

Static Public Member Functions

static std::unique_ptr< Dexparse_dex_file (std::string &dex_file_path)
 Parse a given dex file, return a Dex object as a unique pointer.
 
static std::unique_ptr< Dexparse_dex_file (char *dex_file_path)
 
static std::unique_ptr< Dexparse_dex_file (const char *dex_file_path)
 

Detailed Description

Abstraction of a DEX object, the class offers the analyst a parser, a disassembler and an analysis object.

Constructor & Destructor Documentation

◆ Dex()

KUNAI::DEX::Dex::Dex ( std::string &  dex_file_path)
inline

Constructor of the Dex object, we obtain a path to the DEX file to analyze.

Parameters
dex_file_pathpath to a dex file

Member Function Documentation

◆ get_analysis()

Analysis * KUNAI::DEX::Dex::get_analysis ( bool  create_xrefs)

Get the analysis object this needs the disassembly and the parser, the dex will be disassembled in case this function is called.

Parameters
create_xrefscreate all the xrefs for the class, this can take a long time
Returns
pointer to Analysis object or nullptr in case of error

◆ get_dex_disassembler()

DexDisassembler * KUNAI::DEX::Dex::get_dex_disassembler ( )
inline

Get the disassembler of the DEX file.

Returns
pointer to DexDisassembler

◆ get_parser()

Parser * KUNAI::DEX::Dex::get_parser ( )
inline

get a pointer to the DEX parser with all the headers

Returns
dex parser

◆ get_parsing_correct()

bool KUNAI::DEX::Dex::get_parsing_correct ( ) const
inline

Was parsing process correct?

Returns
boolean with result

◆ parse_dex_file()

static std::unique_ptr< Dex > KUNAI::DEX::Dex::parse_dex_file ( std::string &  dex_file_path)
static

Parse a given dex file, return a Dex object as a unique pointer.

Parameters
dex_file_pathpath to a dex file
Returns
unique pointer with Dex object

The documentation for this class was generated from the following file: