diff options
| author | Brian Potchik <brian@vector35.com> | 2025-03-21 11:00:15 -0400 |
|---|---|---|
| committer | Brian Potchik <brian@vector35.com> | 2025-03-21 11:00:15 -0400 |
| commit | f9b8762d49ef16bf2dd7b814d6f1ef06594b2951 (patch) | |
| tree | 1b6182e93d9560cc710ec82829edda7b00df8c54 /binaryninjaapi.h | |
| parent | 4bb16e8329cd13efa76ecbf79e03525cf19e7b62 (diff) | |
Add some workflow machine control commands to the C++ API.
Diffstat (limited to 'binaryninjaapi.h')
| -rw-r--r-- | binaryninjaapi.h | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/binaryninjaapi.h b/binaryninjaapi.h index 5fc2f5a6..c83e8ee8 100644 --- a/binaryninjaapi.h +++ b/binaryninjaapi.h @@ -10077,10 +10077,33 @@ namespace BinaryNinja { Ref<BinaryView> m_view; Ref<Function> m_function; + bool PostRequest(const std::string& command); + public: WorkflowMachine(Ref<BinaryView> view); WorkflowMachine(Ref<Function> function); + /*! Start the workflow WorkflowMachine + Starts the workflow machine for the given BinaryView or Function. + \return true if the command is accepted, false otherwise. + */ + bool Run(); + + /*! Halt the workflow machine + + Halts analysis at a resumable point. + \return true if the command is accepted, false otherwise. + */ + bool Halt(); + + /*! Reset the workflow machine + + Resets the workflow machine to its initial state. + \return true if the command is accepted, false otherwise. + */ + bool Reset(); + + /*! Enable the workflow machine Re-enables the workflow machine if it is in the Suspend state. @@ -10096,6 +10119,19 @@ namespace BinaryNinja { */ bool Disable(); + /*! Step the workflow machine + + Steps the workflow machine through a single activity. + \return true if the command is accepted, false otherwise. + */ + bool Step(); + + /*! Get the current state of the workflow machine + + Returns the current state of the workflow machine. + \return The current state of the workflow machine + */ + std::string GetState(); std::optional<bool> QueryOverride(const std::string& activity); bool SetOverride(const std::string& activity, bool enable); |
