• Home
  • Raw
  • Download

Lines Matching refs:arch

27 import arch
32 ARCH_64 = arch.Arch.load_from_json(
41 self.arch = ARCH_64
42 self.compiler = compiler.PolicyCompiler(self.arch)
49 self.arch, kill_action=bpf.KillProcess())
61 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
64 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
109 block.simulate(self.arch.arch_nr,
110 self.arch.syscalls['read'],
118 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
121 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
124 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
127 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
130 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
133 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
136 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
139 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
142 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
152 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
155 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
158 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
161 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
164 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
167 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
170 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
173 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
176 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
181 if self.arch.bits == 32:
211 long_block.simulate(self.arch.arch_nr,
212 self.arch.syscalls['read'],
216 self.arch.arch_nr, self.arch.syscalls['read'],
224 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'], 0,
227 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'], 0,
230 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'], 1,
233 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'], 1,
241 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
249 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
252 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
255 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
263 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
271 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
279 block.simulate(self.arch.arch_nr, self.arch.syscalls['read'],
291 block.simulate(self.arch.arch_nr,
292 self.arch.syscalls['read'], prot)[1],
296 block.simulate(self.arch.arch_nr,
297 self.arch.syscalls['read'], prot)[1],
305 self.arch = ARCH_64
306 self.compiler = compiler.PolicyCompiler(self.arch)
338 bpf.simulate(program.instructions, self.arch.arch_nr,
339 self.arch.syscalls['read'], 0)[0],
340 bpf.simulate(program.instructions, self.arch.arch_nr,
341 self.arch.syscalls['close'], 0)[0],
364 bpf.simulate(program.instructions, self.arch.arch_nr,
365 self.arch.syscalls['read'], 0)[0],
366 bpf.simulate(program.instructions, self.arch.arch_nr,
367 self.arch.syscalls['close'], 0)[0],
370 bpf.simulate(program.instructions, self.arch.arch_nr,
371 self.arch.syscalls['read'], 0)[1], 'ALLOW')
373 bpf.simulate(program.instructions, self.arch.arch_nr,
374 self.arch.syscalls['close'], 0)[1], 'ALLOW')
389 bpf.simulate(program.instructions, self.arch.arch_nr,
390 self.arch.syscalls['read'], 0)[1], 'KILL_THREAD')
399 random.sample(self.arch.syscalls.keys(), num_entries),
416 for name, number in self.arch.syscalls.items():
420 bpf.simulate(program.instructions, self.arch.arch_nr,
438 syscalls = dict(random.sample(self.arch.syscalls.items(), num_entries))
451 for name, number in self.arch.syscalls.items():
455 bpf.simulate(program.instructions, self.arch.arch_nr,
456 self.arch.syscalls[name], number)[1],
459 bpf.simulate(program.instructions, self.arch.arch_nr,
460 self.arch.syscalls[name], number + 1)[1],
474 for name in random.sample(self.arch.syscalls.keys(), num_entries):
490 self.arch.arch_nr, self.arch.syscalls[name],
493 bpf.simulate(program.instructions, self.arch.arch_nr,
494 self.arch.syscalls[name], 1025)[1],