-
Notifications
You must be signed in to change notification settings - Fork 1
/
README
34 lines (24 loc) · 1.39 KB
/
README
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
libpretrace is a preload library that allows specified (dynamically linked)
applications to always be executed under a debugging environment. To start
using pretrace, add libpretrace.so to your /etc/ld.so.preload.
root# echo /lib/libpretrace.so >> /etc/ld.so.preload
You can now specify applications to trace in /etc/pretrace.conf, the format
is one application per line, if you would like to specify a debugger append
a colon, then the full path to the debugger and any arguments you would like
to pass. If you do not specify a debugger, you get the default, strace, which
saves the output to .logfile in the current working directory.
An optional number can be appended in the format %N, eg %50, to specify what
percentage of invocations should be traced.
# this is a comment
/full/path/to/application[%percent][:/full/path/to/debugger [arg1 arg2 ...]]
An example pretrace.conf is provided with this distribution.
After modifying pretrace.conf, you should execute ptgenmap to generate a new
map file, this is used to quickly parse the configuration file with minimal
impact on initialisation time.
libpretrace is designed as a debugging utility for developers and auditors,
and should not be used in a production environment.
libpretrace is released under GPL version 2, and was created by Rob Holland
and Tavis Ormandy of the Gentoo Linux Security Audit Team.
April, 2005.