MCPcopy
hub / github.com/RUB-NDS/PRET / verify_write

Method verify_write

printer.py:759–768  ·  view source on GitHub ↗
(self, path, name, data, cmd)

Source from the content-addressed store, hash-verified

757
758 # check for remote files (write)
759 def verify_write(self, path, name, data, cmd):
760 # 1st method: GET
761 opt1 = data in self.get(path + name, len(data))[1]
762 # 2nd method: EXISTS
763 opt2 = self.file_exists(path + name) != c.NONEXISTENT
764 # 3rd method: DIRLIST
765 opt3 = name in self.dirlist(path, False)
766 # show fuzzing results
767 output().fuzzed(path + name, cmd, (opt1, opt2, opt3))
768 return opt1
769
770 # check for remote files (blind)
771 def verify_blind(self, path, name):

Callers 1

fuzz_writeMethod · 0.95

Calls 5

outputClass · 0.90
fuzzedMethod · 0.80
getMethod · 0.45
file_existsMethod · 0.45
dirlistMethod · 0.45

Tested by

no test coverage detected