From bb20865187f95c5dc3b89dfa8884c00638461463 Mon Sep 17 00:00:00 2001 From: Tamas Koczka Date: Sun, 17 Sep 2023 01:20:27 +0000 Subject: [PATCH] kernelCTF: GHA: fix exploit output in summary --- kernelctf/repro/init/init.sh | 2 +- kernelctf/repro_summary.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/kernelctf/repro/init/init.sh b/kernelctf/repro/init/init.sh index 740cf240..ad9b578d 100755 --- a/kernelctf/repro/init/init.sh +++ b/kernelctf/repro/init/init.sh @@ -19,5 +19,5 @@ if [[ " $* " == *" kaslr_leak=1 "* ]]; then CMD="$CMD $KASLR_BASE" fi -echo "running exploit, cmd=$CMD" +echo "running exploit, cmd='$CMD', ::EXPLOIT OUTPUT FROM HERE::" su user -c "$CMD" \ No newline at end of file diff --git a/kernelctf/repro_summary.py b/kernelctf/repro_summary.py index bb0b045b..7a820abf 100755 --- a/kernelctf/repro_summary.py +++ b/kernelctf/repro_summary.py @@ -52,7 +52,7 @@ def getLastLine(pattern): if repro_error: result += f"Error during reproduction: `{repro_error}`.\n\n" - expl_out = split('su user -c /tmp/exp/exploit') + expl_out = split('::EXPLOIT OUTPUT FROM HERE::') m = re.search(r"exploit.*?: (segfault at.*)", expl_out) if m: