Skip to content

Commit

Permalink
Further updates to the binja plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
thomasdullien committed Nov 5, 2018
1 parent 3d4a5d5 commit 79a6118
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions pybindings/binary_ninja_plugin/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

from binaryninja import PluginCommand

import sys
sys.path.append('/home/thomasdullien/.binaryninja/plugins/fss')
from modules import main

plugin = main.Plugin()
Expand Down
4 changes: 2 additions & 2 deletions pybindings/binary_ninja_plugin/modules/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,9 +151,9 @@ def add_report_from_result(self, results, report, address, minimal_match = 100):
for r in results:
m = self.metadata.get(r[1], r[2]) # file name, function name
if not m or len(m) == 0:
line = "- {:d}/128 - {:f} - {:x}:0x{:x}".format(r[0], max(float(r[0]) / 128.0 - 0.5, 0.0)*2, r[1], r[2])
line = "- {:f} - {:x}:0x{:x}".format(max(float(r[0]) / 128.0 - 0.5, 0.0)*2, r[1], r[2])
else:
line = "- {:d}/128 - {:f} - {:x}:0x{:x} {} '{}'".format(r[0], max(float(r[0]) / 128.0 - 0.5, 0.0)*2, r[1], r[2], m[0], m[1])
line = "- {:f} - {:x}:0x{:x} {} '{}'".format(max(float(r[0]) / 128.0 - 0.5, 0.0)*2, r[1], r[2], m[0], m[1])
report += line + "\n"
return report

Expand Down

0 comments on commit 79a6118

Please sign in to comment.