From d3404524010f9dffc623e5f67ca54c6e6dc3f5a9 Mon Sep 17 00:00:00 2001 From: yoloyyh <1764163852@qq.com> Date: Tue, 19 Nov 2024 20:40:29 +0800 Subject: [PATCH] fix posthook --- .../main/java/com/security/smith/asm/SmithMethodVisitor.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/rasp/jvm/JVMProbe/src/main/java/com/security/smith/asm/SmithMethodVisitor.java b/rasp/jvm/JVMProbe/src/main/java/com/security/smith/asm/SmithMethodVisitor.java index 549f99fbd..90472cd32 100644 --- a/rasp/jvm/JVMProbe/src/main/java/com/security/smith/asm/SmithMethodVisitor.java +++ b/rasp/jvm/JVMProbe/src/main/java/com/security/smith/asm/SmithMethodVisitor.java @@ -360,8 +360,10 @@ public void visitMaxs(final int maxStack, final int maxLocals) { if (exceptionHook == null || exceptionHook == "") { - if (xHook == null || xHook == "") { + if (postHook == null || postHook == "") { xHook = "trace"; + } else { + xHook = postHook; } Type[] types = Type.getArgumentTypes(methodDesc);