Discussion:
[AbRT PATCH] abrt-gdb-exploitable: print current instruction
Denys Vlasenko
2013-09-01 18:09:30 UTC
Permalink
I've seen strange BZ created by abrt where "exploitable" element
looked bogus. It claimed that the crash was jumping to bogus address
yet crashing insn was a benign reg-to-reg move.

This patch makes analyzer to record what it thinks current insn is.

Signed-off-by: Denys Vlasenko <dvlasenk-H+wXaHxf7aLQT0dZR+***@public.gmane.org>
---
src/plugins/abrt-gdb-exploitable | 2 ++
1 file changed, 2 insertions(+)

diff --git a/src/plugins/abrt-gdb-exploitable b/src/plugins/abrt-gdb-exploitable
index 950797b..abc1fa4 100755
--- a/src/plugins/abrt-gdb-exploitable
+++ b/src/plugins/abrt-gdb-exploitable
@@ -705,6 +705,8 @@ class AbrtExploitable(gdb.Command):
f = open(args[1], 'w')
f.write(_("Likely crash reason: ") + si.exploitable_desc + "\n")
f.write(_("Exploitable rating (0-9 scale): ") + str(si.exploitable_rating) + "\n")
+ if si.current_instruction:
+ f.write(_("Current instruction: ") + si.current_instruction + "\n")
else:
sys.stderr.write(_("Exploitability analysis came up empty\n"))
--
1.8.1.4
Richard Marko
2013-09-09 13:49:20 UTC
Permalink
Pushed, thanks!
Post by Denys Vlasenko
I've seen strange BZ created by abrt where "exploitable" element
looked bogus. It claimed that the crash was jumping to bogus address
yet crashing insn was a benign reg-to-reg move.
This patch makes analyzer to record what it thinks current insn is.
---
src/plugins/abrt-gdb-exploitable | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/plugins/abrt-gdb-exploitable b/src/plugins/abrt-gdb-exploitable
index 950797b..abc1fa4 100755
--- a/src/plugins/abrt-gdb-exploitable
+++ b/src/plugins/abrt-gdb-exploitable
f = open(args[1], 'w')
f.write(_("Likely crash reason: ") + si.exploitable_desc + "\n")
f.write(_("Exploitable rating (0-9 scale): ") + str(si.exploitable_rating) + "\n")
+ f.write(_("Current instruction: ") + si.current_instruction + "\n")
sys.stderr.write(_("Exploitability analysis came up empty\n"))
--
Richard Marko
Loading...