Skip to content

Commit

Permalink
Set a tag icon to generated tags
Browse files Browse the repository at this point in the history
  • Loading branch information
ergrelet committed Jul 28, 2024
1 parent 4fc6171 commit 1b4b15c
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Virtualizer), in order to help reverse engineers focus on interesting code.
## Screenshot

<p align="center">
<img width="400" src="static/tags_screenshot.png">
<img width="370" src="static/tags_screenshot.png">
</p>

# Supported Targets
Expand Down
6 changes: 2 additions & 4 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ pub type CodeEntryDestRange = std::ops::Range<u64>;

const THEMIDA_SPOTTER_PLUGIN_NAME: &str = "themida-spotter-bn";
const THEMIDA_SPOTTER_TAG_NAME: &str = "Themida's obfuscated code entries";
const THEMIDA_SPOTTER_TAG_ICON: &str = "🛡";

#[derive(Debug)]
pub enum CodeEntryDescription {
Expand Down Expand Up @@ -121,10 +122,7 @@ fn search_for_code_entries_task<
let vm_entry_tag_type = view
.get_tag_type(THEMIDA_SPOTTER_TAG_NAME)
.unwrap_or_else(|| {
// Note(ergrelet): due to a bug in Binja's Rust API, `icon`
// actually sets the name of the tag.
// FIXME: Update the code to set an actual icon when the bug is fixed upstream.
view.create_tag_type(THEMIDA_SPOTTER_TAG_NAME, THEMIDA_SPOTTER_TAG_NAME)
view.create_tag_type(THEMIDA_SPOTTER_TAG_NAME, THEMIDA_SPOTTER_TAG_ICON)
});

// Create tags for each obfuscated code entry found (if any)
Expand Down
Binary file modified static/tags_screenshot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 1b4b15c

Please sign in to comment.