From 54d140e24e354b2ed6f8083cae5eaf35db2336af Mon Sep 17 00:00:00 2001 From: Josselin Date: Thu, 8 Nov 2018 11:15:36 +0100 Subject: [PATCH] Update deletegall heuristic --- slither/detectors/statements/controlled_delegatecall.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/slither/detectors/statements/controlled_delegatecall.py b/slither/detectors/statements/controlled_delegatecall.py index d12eef59b..625f95561 100644 --- a/slither/detectors/statements/controlled_delegatecall.py +++ b/slither/detectors/statements/controlled_delegatecall.py @@ -7,7 +7,7 @@ class ControlledDelegateCall(AbstractDetector): """ ARGUMENT = 'controlled-delegatecall' - HELP = 'Controlled delegatecall function id' + HELP = 'Controlled delegatecall destination' IMPACT = DetectorClassification.HIGH CONFIDENCE = DetectorClassification.MEDIUM @@ -18,7 +18,7 @@ class ControlledDelegateCall(AbstractDetector): for node in function.nodes: for ir in node.irs: if isinstance(ir, LowLevelCall) and ir.function_name in ['delegatecall', 'codecall']: - if is_tainted(self.slither, ir.arguments[0]) and is_tainted(self.slither, ir.destination): + if is_tainted(self.slither, ir.destination): ret.append(node) return ret