osquery-1/osquery/tables/CMakeLists.txt

117 lines
3.2 KiB
CMake
Raw Normal View History

if(APPLE)
2014-09-23 03:40:28 +00:00
ADD_OSQUERY_OBJCXX_LIBRARY(osquery_tables_objc
2014-09-05 14:54:41 +00:00
../core/darwin/NSProcessInfo+PECocoaBackports.mm
../core/darwin/NSProcessInfo+PECocoaBackports.h
../core/darwin/PECocoaBackportsGlobal.h
2014-09-05 14:54:41 +00:00
system/darwin/osx_version.mm
2014-10-10 01:08:18 +00:00
system/darwin/users.mm
system/darwin/groups.mm
system/darwin/ca_certs.mm
)
2014-09-23 03:40:28 +00:00
ADD_OSQUERY_LIBRARY(osquery_tables_darwin
events/darwin/passwd_changes.cpp
events/darwin/hardware_events.cpp
2014-09-09 05:44:46 +00:00
networking/darwin/listening_ports.cpp
networking/darwin/routes.cpp
2014-09-05 14:54:41 +00:00
system/darwin/apps.cpp
system/darwin/ca_certs_utils.cpp
system/darwin/firewall.h
2014-09-05 14:54:41 +00:00
system/darwin/firewall.cpp
system/darwin/homebrew_packages.cpp
2014-09-05 14:54:41 +00:00
system/darwin/kextstat.cpp
system/darwin/launchd.cpp
system/darwin/mounts.cpp
2014-09-05 14:54:41 +00:00
system/darwin/nvram.cpp
system/darwin/processes.cpp
system/darwin/process_open_files.cpp
system/darwin/quarantine.cpp
2014-12-10 22:51:43 +00:00
system/darwin/pci_devices.cpp
system/darwin/usb_devices.cpp
2014-10-30 01:10:26 +00:00
system/darwin/startup_items.cpp
2014-12-16 04:16:52 +00:00
system/darwin/xprotect.cpp
)
2014-09-06 01:12:37 +00:00
ADD_OSQUERY_LINK("-framework CoreFoundation")
ADD_OSQUERY_LINK("-framework Security")
ADD_OSQUERY_LINK("-framework OpenDirectory")
2014-11-13 20:00:41 +00:00
elseif(FREEBSD)
ADD_OSQUERY_LIBRARY(osquery_tables_freebsd
events/freebsd/passwd_changes.cpp
networking/freebsd/routes.cpp
system/freebsd/processes.cpp
system/freebsd/users.cpp
system/freebsd/groups.cpp
2014-11-13 20:00:41 +00:00
)
2014-09-05 14:54:41 +00:00
else()
2014-09-23 03:40:28 +00:00
ADD_OSQUERY_LIBRARY(osquery_tables_linux
events/linux/passwd_changes.cpp
2014-12-08 10:22:59 +00:00
events/linux/hardware_events.cpp
2014-09-09 05:44:46 +00:00
networking/linux/routes.cpp
networking/linux/socket_inode.cpp
networking/linux/port_inode.cpp
networking/linux/arp_cache.cpp
2014-12-06 21:40:55 +00:00
system/linux/kernel_integrity.cpp
2014-09-05 14:54:41 +00:00
system/linux/kernel_modules.cpp
system/linux/processes.cpp
2014-10-10 01:08:18 +00:00
system/linux/users.cpp
system/linux/groups.cpp
2014-11-01 00:16:36 +00:00
system/linux/mounts.cpp
system/linux/pci_devices.cpp
2014-12-10 22:51:43 +00:00
system/linux/usb_devices.cpp
2014-10-31 23:46:14 +00:00
system/linux/block_devices.cpp
2014-09-05 14:54:41 +00:00
)
2014-10-29 05:59:25 +00:00
2014-12-31 17:33:19 +00:00
if(CENTOS)
# CentOS specific tables
ADD_OSQUERY_LIBRARY(osquery_tables_redhat
system/linux/rpm_packages.cpp
)
2014-12-30 22:24:49 +00:00
2014-12-31 17:33:19 +00:00
ADD_OSQUERY_LINK("rpm")
ADD_OSQUERY_LINK("rpmio")
elseif(UBUNTU)
# Ubuntu specific tables
ADD_OSQUERY_LIBRARY(osquery_tables_ubuntu
system/linux/deb_packages.cpp
2014-12-30 01:34:19 +00:00
system/linux/apt_sources.cpp
)
ADD_OSQUERY_LINK("apt-pkg")
ADD_OSQUERY_LINK("dpkg")
endif()
ADD_OSQUERY_LINK("procps" "proc")
ADD_OSQUERY_LINK("blkid")
ADD_OSQUERY_LINK("udev")
ADD_OSQUERY_LINK("uuid")
endif()
2014-09-23 03:40:28 +00:00
ADD_OSQUERY_LIBRARY(osquery_tables
2014-09-09 05:44:46 +00:00
networking/utils.cpp
networking/interfaces.cpp
networking/etc_hosts.cpp
networking/etc_services.cpp
system/cpuid.cpp
2014-12-23 22:39:59 +00:00
system/crontab.cpp
2014-10-14 01:19:08 +00:00
system/last.cpp
system/shell_history.cpp
Add suid_bin vtable The vtabel report : - path: full path of the file - unix_user: name of the owner (if not available display the uid) - unix_group: name of the groupe (if not available display the gid) - permissions: report suid or guid * S for suid bin * G for guid bin Example : osquery> select * from suid_bin; +----------------------------------------------------------------------------------------------------+-----------+---------------+-------------+ | path | unix_user | unix_group | permissions | +----------------------------------------------------------------------------------------------------+-----------+---------------+-------------+ | "/bin/ps" | root | wheel | S | | "/bin/rcp" | root | wheel | S | | "/Users/vmauge/suid_test" | vmauge | 999 | SG | | "/usr/bin/at" | root | wheel | S | | "/usr/bin/atq" | root | wheel | S | | "/usr/bin/atrm" | root | wheel | S | | "/usr/bin/batch" | root | wheel | S | | "/usr/bin/crontab" | root | wheel | S | | "/usr/bin/ipcs" | root | wheel | S | | "/usr/bin/lockfile" | root | mail | G | | "/usr/bin/login" | root | wheel | S | | "/usr/bin/newgrp" | root | wheel | S | | "/usr/bin/procmail" | root | mail | G | | "/usr/bin/quota" | root | wheel | S | | "/usr/bin/rlogin" | root | wheel | S | | "/usr/bin/rsh" | root | wheel | S | | "/usr/bin/su" | root | wheel | S | | "/usr/bin/sudo" | root | wheel | S | | "/usr/bin/top" | root | wheel | S | | "/usr/bin/wall" | root | tty | G | | "/usr/bin/write" | root | tty | G | | "/usr/sbin/postdrop" | root | _postdrop | G | | "/usr/sbin/postqueue" | root | _postdrop | G | | "/usr/sbin/rpc.net" | root | wheel | S | | "/usr/sbin/rpcset" | root | wheel | S | | "/usr/sbin/traceroute" | root | wheel | S | | "/usr/sbin/traceroute6" | root | wheel | S | +----------------------------------------------------------------------------------------------------+-----------+---------------+-------------+ This commit fixes issue #253.
2014-10-29 05:08:10 +00:00
system/suid_bin.cpp
2014-11-23 04:49:37 +00:00
system/logged_in_users.cpp
2014-07-31 00:35:19 +00:00
)
ADD_OSQUERY_CORE_LIBRARY(osquery_utility_tables
utility/time.cpp
utility/hash.cpp
utility/file.cpp
utility/osquery.cpp
)
2015-01-07 20:29:24 +00:00
ADD_OSQUERY_TEST(etc_hosts_tests networking/etc_hosts_tests.cpp TRUE)
2014-08-30 21:26:24 +00:00
if(APPLE)
2015-01-07 20:29:24 +00:00
ADD_OSQUERY_TEST(apps_tests system/darwin/apps_tests.cpp TRUE)
ADD_OSQUERY_TEST(ca_certs_tests system/darwin/ca_certs_tests.cpp TRUE)
ADD_OSQUERY_TEST(firewall_tests system/darwin/firewall_tests.cpp TRUE)
ADD_OSQUERY_TEST(launchd_tests system/darwin/launchd_tests.cpp TRUE)
2014-08-30 21:26:24 +00:00
endif()