Debian Codegraph @

upstream/debian-unstable/man3/ausearch_add_expression.3

raw
1 .TH "AUSEARCH_ADD_EXPRESSION" "3" "Feb 2008" "Red Hat" "Linux Audit API"
2 .SH NAME
3 ausearch_add_expression \- build up search expression
4 .SH "SYNOPSIS"
5 .nf
6 .B #include <auparse.h>
7 .PP
8 .BI "int ausearch_add_expression(auparse_state_t *" au ", const char *" expression ", char **" error ", ausearch_rule_t " how );"
9 .fi
10
11 .SH "DESCRIPTION"
12 .B ausearch_add_item
13 adds an expression to the current audit search expression. The search conditions can then be used to scan logs, files, or buffers for something of interest. The \fIexpression\fP parameter contains an expression, as specified in
14 .BR ausearch\-expression (5).
15 The \fIhow\fP parameter determines how this search expression will affect the existing search expression, if one is already defined. The possible values are:
16 .RS
17 .TP
18 .I AUSEARCH_RULE_CLEAR
19 Clear the current search expression, if any, and use only this search expression.
20 .TP
21 .I AUSEARCH_RULE_OR
22 If a search expression
23 .I E
24 is already configured, replace it by \fB(\fIE\fB || this_search_expression)\fR.
25 .TP
26 .I AUSEARCH_RULE_AND
27 If a search expression
28 .I E
29 is already configured, replace it by \fB(\fIE\fB && this_search_expression)\fR.
30 .RE
31 The caller must free the error message using
32 .BR free (3).
33 If an error message is not available or can not be allocated, \fB*\fIerror\fR
34 is set to \fBNULL\fR.
35
36 .SH "SEE ALSO"
37
38 .BR ausearch_add_item (3),
39 .BR ausearch_add_interpreted_item (3),
40 .BR ausearch_add_timestamp_item (3),
41 .BR ausearch_add_regex (3),
42 .BR ausearch_set_stop (3),
43 .BR ausearch_clear (3),
44 .BR ausearch_next_event (3),
45 .BR ausearch_cur_event (3),
46 .BR ausearch\-expression (5).
47
48 .SH AUTHOR
49 Miloslav Trmac