File: trick-logopen.1

package info (click to toggle)
libtricks 0.2-5
  • links: PTS
  • area: main
  • in suites: slink
  • size: 548 kB
  • ctags: 328
  • sloc: ansic: 2,292; sh: 1,984; perl: 701; cpp: 306; makefile: 86
file content (91 lines) | stat: -rw-r--r-- 1,930 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
.\" Process this file with
.\" groff -man -Tascii foo.1
.\"
.\" "verbatim" environment (from strace.1)
.de CW
.sp
.nf
.ft CW
..
.de CE
.ft
.fi
.sp
..
.TH trick-logopen 1 "15 Augustus 1998" "Debian Project" "Debian GNU/Linux manual"
.SH NAME
trick-logopen

.SH SYNOPSIS
.B trick-logopen
[
--libpath directory
]
[ 
--file outputfile
]
[
command
]

.B trick-logopen
Generates a report of all open() calls, and writes it to a file.

.SH DESCRIPTION
By setting the VPATH environment variable appropiratly, and setting
LD_PRELOAD to
.B libtricks(1)
the mentioned library will create an environment where all open()
calls are reported, and logged to a file.

Note that this is not in any way `safe': statically linked binaries
will still be able open files, without libtricks noticing it.


.B trick-logopen
Note
provides a lot less security than the real (kernel) chroot,
but please note that root can easily break out of a real chroot shell
too. Neigther this trick-chroot nor the real chroot should be
considered `safe'.



The main purpose of this script is to show an example of how to
work with 
.B libtricks(1) .

Note btw that, as the dynamic linker (/lib/ld.so-linux) is statically
linked, it will search the libraries in the real root, not in this
chroot environment. So, you don't have to populate ${CHROOT}/lib.

.SS OPTIONS
.TP
.I "\-\-file filename"
The outputfile to use. Default: trick-open.log (in the directory where
.B trick-logopen
was started)

.TP
.I "\-\-libpath path"
specify the path of the libtrick library. Default: /usr/lib/libtricks/


.SH BUGS
Using libtricks-0.2, it seems that open() calls from
.B less(1)
etc are not logged. Will look into that.

.SH COPYING
.B libtricks
is distributed under the GNU General Public License.
(GPL 2.0 or greater).
.SH AUTHOR
joost witteveen
.RI <joostje@debian.org>
.SH "SEE ALSO"
.BR trick-chktmp(1),
.BR trick-chroot(1),
.BR fakeroot(1)
.BR /usr/doc/libtricks/README