arbiter
arbiter copied to clipboard
A bug in CheckpointHook causes false negatives
I think the globals
in self.state.globals.get('globals', None)
should be sym_vars
. This can make CheckpointHook discard some sym_vars and give false negatives. Could you have a check if there are similar problems?
class CheckpointHook(DefaultHook):
def run(self, **kwargs):
assert 'arg_num' in kwargs['kwargs']
arg_num = kwargs['kwargs']['arg_num']
if self.state.globals.get('globals', None) is None:
self.state.globals['sym_vars'] = []
if arg_num == 0:
sym_var = claripy.BVS('ret', self.state.arch.bits)
self.state.globals['sym_vars'].append(sym_var)
return sym_var
This looks certainly like a typo. Great catch! Could you create a PR ?