Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

xattrat syscalls: update normalizer and interpreter #431

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 30 additions & 2 deletions auparse/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ BUILT_SOURCES = accesstabs.h captabs.h clocktabs.h clone-flagtabs.h \
netactiontabs.h \
normalize_obj_kind_maps.h normalize_record_maps.h \
normalize_syscall_maps.h normalize_evtypetabs.h bpftabs.h \
openat2-resolvetabs.h
openat2-resolvetabs.h xattr-atflagtabs.h access-flagtabs.h
noinst_PROGRAMS = gen_accesstabs_h gen_captabs_h gen_clock_h \
gen_clone-flagtabs_h \
gen_epoll_ctls_h gen_famtabs_h gen_fcntl-cmdtabs_h \
Expand All @@ -86,7 +86,7 @@ noinst_PROGRAMS = gen_accesstabs_h gen_captabs_h gen_clock_h \
gen_umounttabs_h gen_inethooktabs_h gen_netactiontabs_h \
gen_normalize_record_map gen_normalize_syscall_map \
gen_normalize_obj_kind_map gen_normalize_evtypetabs_h gen_bpftabs_h \
gen_openat2-resolvetabs_h
gen_openat2-resolvetabs_h gen_xattr-atflagtabs_h gen_access-flagtabs_h

gen_accesstabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h accesstab.h
gen_accesstabs_h_CFLAGS = '-DTABLE_H="accesstab.h"'
Expand All @@ -101,6 +101,20 @@ gen_accesstabs_h$(BUILD_EXEEXT): LDFLAGS=$(LDFLAGS_FOR_BUILD)
accesstabs.h: gen_accesstabs_h Makefile
./gen_accesstabs_h --i2s-transtab access > $@

gen_access_flagtabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h \
access-flagtab.h
gen_access_flagtabs_h_CFLAGS = '-DTABLE_H="access-flagtab.h"'
$(gen_access_flagtabs_h_OBJECTS): CC=$(CC_FOR_BUILD)
$(gen_access_flagtabs_h_OBJECTS): CFLAGS=$(CFLAGS_FOR_BUILD)
$(gen_access_flagtabs_h_OBJECTS): CPPFLAGS=$(CPPFLAGS_FOR_BUILD)
$(gen_access_flagtabs_h_OBJECTS): LDFLAGS=$(LDFLAGS_FOR_BUILD)
gen_access-flagtabs_h$(BUILD_EXEEXT): CC=$(CC_FOR_BUILD)
gen_access-flagtabs_h$(BUILD_EXEEXT): CFLAGS=$(CFLAGS_FOR_BUILD)
gen_access-flagtabs_h$(BUILD_EXEEXT): CPPFLAGS=$(CPPFLAGS_FOR_BUILD)
gen_access-flagtabs_h$(BUILD_EXEEXT): LDFLAGS=$(LDFLAGS_FOR_BUILD)
access-flagtabs.h: gen_access-flagtabs_h Makefile
./gen_access-flagtabs_h --i2s-transtab access_flag > $@

gen_captabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h captab.h
gen_captabs_h_CFLAGS = '-DTABLE_H="captab.h"'
$(gen_captabs_h_OBJECTS): CC=$(CC_FOR_BUILD)
Expand Down Expand Up @@ -325,6 +339,20 @@ gen_open-flagtabs_h$(BUILD_EXEEXT): LDFLAGS=$(LDFLAGS_FOR_BUILD)
open-flagtabs.h: gen_open-flagtabs_h Makefile
./gen_open-flagtabs_h --i2s-transtab open_flag > $@

gen_xattr_atflagtabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h \
xattr-atflagtab.h
gen_xattr_atflagtabs_h_CFLAGS = '-DTABLE_H="xattr-atflagtab.h"'
$(gen_xattr_atflagtabs_h_OBJECTS): CC=$(CC_FOR_BUILD)
$(gen_xattr_atflagtabs_h_OBJECTS): CFLAGS=$(CFLAGS_FOR_BUILD)
$(gen_xattr_atflagtabs_h_OBJECTS): CPPFLAGS=$(CPPFLAGS_FOR_BUILD)
$(gen_xattr_atflagtabs_h_OBJECTS): LDFLAGS=$(LDFLAGS_FOR_BUILD)
gen_xattr-atflagtabs_h$(BUILD_EXEEXT): CC=$(CC_FOR_BUILD)
gen_xattr-atflagtabs_h$(BUILD_EXEEXT): CFLAGS=$(CFLAGS_FOR_BUILD)
gen_xattr-atflagtabs_h$(BUILD_EXEEXT): CPPFLAGS=$(CPPFLAGS_FOR_BUILD)
gen_xattr-atflagtabs_h$(BUILD_EXEEXT): LDFLAGS=$(LDFLAGS_FOR_BUILD)
xattr-atflagtabs.h: gen_xattr-atflagtabs_h Makefile
./gen_xattr-atflagtabs_h --i2s-transtab xattr_atflag > $@

gen_persontabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h persontab.h
gen_persontabs_h_CFLAGS = '-DTABLE_H="persontab.h"'
$(gen_persontabs_h_OBJECTS): CC=$(CC_FOR_BUILD)
Expand Down
26 changes: 26 additions & 0 deletions auparse/access-flagtab.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
/* access-modetab.h --
* Copyright Red Hat Inc.
* All Rights Reserved.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
* Authors:
* Attila Lakatos <[email protected]>
* Location: fcntl.h
*/

_S(0x100, "AT_SYMLINK_NOFOLLOW" )
_S(0x200, "AT_EACCESS" )
_S(0x1000, "AT_EMPTY_PATH" )
2 changes: 1 addition & 1 deletion auparse/accesstab.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
* Location: ?
*/


// _S(0x0U, "F_OK" ) handled in interpret
_S(0x1U, "X_OK" )
_S(0x2U, "W_OK" )
_S(0x4U, "R_OK" )
Expand Down
Loading