Difference between revisions of "Truxton Top Level Object"

From truxwiki.com
Jump to navigation Jump to search
Line 3: Line 3:
 
=Methods=
 
=Methods=
 
==<code>blackboxlocation(source_code_file_id: int, source_code_line_number: int) -> None</code>==
 
==<code>blackboxlocation(source_code_file_id: int, source_code_line_number: int) -> None</code>==
Sets a debugging location in the black box.
+
Sets a debugging location in the [[Black Box|black box]].
 
You must create a value to represent the name of your source code file.
 
You must create a value to represent the name of your source code file.
 
When parsing the <code>DebugDump.xml</code>, you can translate that value back to the filename.
 
When parsing the <code>DebugDump.xml</code>, you can translate that value back to the filename.
  
 
==<code>blackboxvalue(slot: int, value: int, source_code_file_id: int, source_code_line_number: int) -> None</code>==
 
==<code>blackboxvalue(slot: int, value: int, source_code_file_id: int, source_code_line_number: int) -> None</code>==
Sets a debugging value in the black box.
+
Sets a debugging value in the [[Black Box|black box]].
 
You have 20 debugging slots to store values.
 
You have 20 debugging slots to store values.
 
<code>slot</code> can have a value between 0 and 19.
 
<code>slot</code> can have a value between 0 and 19.
Line 17: Line 17:
  
 
==<code>dumpblackbox(process_id: int) -> None</code>==
 
==<code>dumpblackbox(process_id: int) -> None</code>==
Dumps the black box of the given process.
+
Dumps the [[Black Box|black box]] of the given process.
 
If the process has a black box, it will be written as XML to a file in the log file folder.
 
If the process has a black box, it will be written as XML to a file in the log file folder.
 
The name of the file will be a timestamp followed by the process id then 'DebugDump.xml' example: 20221231_145509_Process_1234_DebugDump.xml
 
The name of the file will be a timestamp followed by the process id then 'DebugDump.xml' example: 20221231_145509_Process_1234_DebugDump.xml

Revision as of 05:13, 14 September 2022

This is the object that is created when you import truxton

Methods

blackboxlocation(source_code_file_id: int, source_code_line_number: int) -> None

Sets a debugging location in the black box. You must create a value to represent the name of your source code file. When parsing the DebugDump.xml, you can translate that value back to the filename.

blackboxvalue(slot: int, value: int, source_code_file_id: int, source_code_line_number: int) -> None

Sets a debugging value in the black box. You have 20 debugging slots to store values. slot can have a value between 0 and 19. When parsing the DebugDump.xml, you can translate that value back to the filename.

create() -> TruxtonObject

It will return a Truxton Object which is basically a connection to Truxton.

dumpblackbox(process_id: int) -> None

Dumps the black box of the given process. If the process has a black box, it will be written as XML to a file in the log file folder. The name of the file will be a timestamp followed by the process id then 'DebugDump.xml' example: 20221231_145509_Process_1234_DebugDump.xml

etl() -> TruxtonETL

This creates an ETL object to participate in exploitation.

options() -> TruxtonOptions

This creates an Options object to retrieve configuration variables.

Attributes

There are hundreds of attributes to the object.

version: str

A string containing the version of Truxton this supports.

Defined Constants

The same constants used for file types and other purposes are present in the Truxton top level object.