[Systrace] Segfault
marius aamodt eriksen
marius at monkey.org
Mon Jan 12 00:47:16 EST 2004
* Stefan Pinkert <stpinkert at stpinkert.de> [040111 22:57]:
> First of all is there anywhere a short description of the command line options
> of systrace?
man systrace :-)
> Patching and compiling the kernel wasn't a problem and until now it runs
> without any problems. The user-space tool was causing some problems but
> finally i was able to get it compiled. The first run (systrace -A /bin/ls)
> was successfull, but the second(systrace -f .systrace/bin_ls /bin/ls) died
> with a segfault. From what i can see from the strace log it seem to have
> problems with reading the policy file. Here are the corresponding lines from
> strace:
p.s. the -f option is not necessary; systrace will load
$HOME/.systrace/POLICY automatically.
> open(".systrace/bin_ls", O_RDONLY) = 3
> fstat64(3, {st_mode=S_IFREG|0600, st_size=1206, ...}) = 0
> mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
> 0x4001a000
> read(3, "Policy: /bin/ls, Emulation: linu"..., 4096) = 1206
> gettimeofday({1073871300, 815142}, NULL) = 0
> --- SIGSEGV (Segmentation fault) @ 0 (0) ---
> +++ killed by SIGSEGV +++
i am not able to replicate this problem; could you build systrace with
debugging turned on?
$ make CFLAGS=-g
and then when it segfaults (and dumps core), run
$ gdb `which systrace` systrace.core
you will then get a prompt
(gdb)
can you then provide me with the output of the "bt" command there?
i.e.
(gdb) bt
that would be tremendously helpful.
> The second problem i found is that i was not able to let pass any options to
> ls (systrace -A /bin/ls -l). Systrace just killed the command.
systrace should allow for options to be passed on; it is possible this
problem is related with your first problem.
marius.
--
marius a eriksen <marius at monkey.org> | http://monkey.org/~marius/
More information about the systrace
mailing list