Commit Graph

36 Commits

Author SHA1 Message Date
Chris PeBenito 0992763548 Update callers for "pid" to "runtime" interface rename.
Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2020-06-28 16:03:45 -04:00
Chris PeBenito 309f655fdc various: Module version bump.
Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2020-06-10 15:02:27 -04:00
Topi Miettinen 1d8333d7a7
Remove unlabeled packet access
When SECMARK or Netlabel packet labeling is used, it's useful to
forbid receiving and sending unlabeled packets. If packet labeling is
not active, there's no effect.

Signed-off-by: Topi Miettinen <toiwoton@gmail.com>
2020-06-03 23:16:19 +03:00
Chris PeBenito b2f72e833b Bump module versions for release.
Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2020-02-29 16:54:39 -05:00
Chris PeBenito 7af9eb3e91 various: Module version bump.
Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2020-01-15 10:42:45 -05:00
Stephen Smalley 161bda392e access_vectors: Remove unused permissions
Remove unused permission definitions from SELinux.
Many of these were only ever used in pre-mainline
versions of SELinux, prior to Linux 2.6.0.  Some of them
were used in the legacy network or compat_net=1 checks
that were disabled by default in Linux 2.6.18 and
fully removed in Linux 2.6.30.

The corresponding classmap declarations were removed from the
mainline kernel in:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=42a9699a9fa179c0054ea3cf5ad3cc67104a6162

Permissions never used in mainline Linux:
file swapon
filesystem transition
tcp_socket { connectto newconn acceptfrom }
node enforce_dest
unix_stream_socket { newconn acceptfrom }

Legacy network checks, removed in 2.6.30:
socket { recv_msg send_msg }
node { tcp_recv tcp_send udp_recv udp_send rawip_recv rawip_send dccp_recv dccp_send }
netif { tcp_recv tcp_send udp_recv udp_send rawip_recv rawip_send dccp_recv dccp_send }

Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
2020-01-14 13:41:50 -05:00
Chris PeBenito 291f68a119 various: Module version bump.
Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2019-09-30 20:39:31 -04:00
Chris PeBenito d6c7154f1c Reorder declarations based on *_runtime_t renaming.
Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2019-09-30 20:02:43 -04:00
Chris PeBenito 69a403cd97 Rename *_var_run_t types to *_runtime_t.
Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2019-09-30 20:02:43 -04:00
Chris PeBenito 3ab07a0e1e Move all files out of the old contrib directory. 2018-06-23 10:38:58 -04:00
Chris PeBenito 09248fa0db Move modules to contrib submodule. 2011-09-09 10:10:03 -04:00
Chris PeBenito d3a85bbc0b Module version bump for zabbix patch from Sven Vermeulen. 2011-08-16 15:23:39 -04:00
Sven Vermeulen 0caefef811 Allow zabbix to connect to mysql through TCP
The mysql_stream_connect interface, which is already in use, is only for local
MySQL databases (not through TCP/IP).

Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
2011-08-16 15:23:11 -04:00
Chris PeBenito aa4dad379b Module version bump for release. 2011-07-26 08:11:01 -04:00
Chris PeBenito ccf8bdea90 Add agent support to zabbix from Sven Vermeulen. 2011-06-15 14:11:14 -04:00
Chris PeBenito cae953ff01 Rearrange lines in zabbix. 2011-06-15 13:51:22 -04:00
Chris PeBenito 2c59cf9cf9 Remove unnecessary comments in zabbix.te. 2011-06-15 13:47:08 -04:00
Sven Vermeulen b6b23abade Allow zabbix agent to query system state and other monitorable aspects
The zabbix agent is responsible for collecting the system state and other
monitorable aspects. This include
- information from /proc
- read attributes of various files (tamper detection)
- connect to the ssh service (check if it is reachable)
- get file system information
- read login information
- ...

It should be noted that the agent can do a lot more, depending on the target
system (what is being monitored) and the running services. The allowed
privileges here will in the future expand more as more templates are
checked.

Update: follow styleguide

Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
2011-06-15 13:41:15 -04:00
Sven Vermeulen d30069e4dc Allow zabbix server to connect to agent (active monitoring)
The zabbix server also connects to the agents (this is called "active
monitoring" in the zabbix terms). So we create a zabbix_agent_tcp_connect
interface, use it for the zabbix_t domain and, since zabbix can use
hostname-based connections, allow DNS resolving for the zabbix server.

Update: Follow styleguide

Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
2011-06-15 13:41:09 -04:00
Sven Vermeulen 80b95df00a Zabbix agent binds on its own port, connects to zabbix server
The zabbix agent has its own dedicated port (10050) on which it needs to
bind/listen.

Also, the agent connects to the server so we add the zabbix_tcp_connect
interface (shamelessly copied from mysql_tcp_connect) and use it for the
zabbix_agent_t domain.

Update: structure interface calls more closely to styleguide

Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
2011-06-15 13:41:03 -04:00
Sven Vermeulen 5b85c03633 Support different domain for zabbix agent (start with skeleton)
The zabbix agent should be confined within its own domain. We start with the
definition of a small(er) skeleton to work from. This includes proper file
context definitions, standard interdomain privileges (which are quite
similar to those of the server) and the proper log- and pid access
privileges.

Update: attempt to follow styleguide more closely

Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
2011-06-15 13:40:58 -04:00
Sven Vermeulen 5b17d3e7d6 Define zabbix port and allow server to listen/bind on it
The zabbix server uses a dedicated port (10051). We define it and allow the
zabbix server to bind/listen on it.

Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
2011-06-15 13:40:54 -04:00
Sven Vermeulen 1f1723e008 Support shared memory
On Mon, Jun 13, 2011 at 10:28:15AM +0200, Sven Vermeulen wrote:
> Zabbix servers use shared memory to keep common information and structures.
> This is implemented on tmpfs. We support this by introducing a
> zabbix_tmpfs_t type and allow the server proper access to it.

After a small discussion and a few more tests, drop the "dir" in
fs_tmpfs_filetrans.

For posterity's sake, this is the denial one gets when no tmpfs_t related
privileges are given:

Jun 13 11:24:06 build kernel: [  213.054230] type=1400
audit(1307957046.001:106): avc:  denied  { read write } for  pid=3162
comm="zabbix_agentd" path=2F535953563663303132323534202864656C6574656429
dev=tmpfs ino=32768 scontext=system_u:system_r:zabbix_agent_t
tcontext=system_u:object_r:tmpfs_t tclass=file

With fs_tmpfs_filetrans(..., file) the same denial is given, but as
tcontext=zabbix_tmpfs_t. Hence the rw_files_pattern() enhancement.

Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
2011-06-15 13:40:49 -04:00
Sven Vermeulen ae5814904e zabbix server spawns multiple processes
The zabbix server process is a multi-process system.

In order to, for instance, shut it down, signalling within the domain is
necessary. Otherwise, the processes remain running.

Also, since there are multiple processes trying to use the same log file,
the zabbix server uses semaphores to ensure proper access to the log files
(concurrency).

Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
2011-06-15 13:40:45 -04:00
Chris PeBenito 826d014241 Bump module versions for release. 2010-12-13 09:12:22 -05:00
Chris PeBenito fee48647ac Module version bump for c17ad38 5271920 2a2b6a7 01c4413 c4fbfae a831710
67effb0 483be01 c6c63f6 b0d8d59 5b082e4 b8097d6 689d954 5afc3d3 f3c5e77
a59e50c cf87233 17759c7 dc1db54 e9bf16d 4f95198 bf40792 622c63b c20842c
dc7cc4d 792d448
2010-09-15 10:42:34 -04:00
Jeremy Solt 622c63b4e3 zabbix patch from Dan Walsh 2010-09-15 09:14:55 -04:00
Chris PeBenito 48f99a81c0 Whitespace change: drop unnecessary blank line at the start of .te files. 2010-06-10 08:16:35 -04:00
Chris PeBenito 2cca6b79b4 trunk: remove redundant shared lib calls. 2008-10-17 17:31:04 +00:00
Chris PeBenito 5d4f4b5375 trunk: bump version numbers for release. 2008-10-14 15:46:36 +00:00
Chris PeBenito e87221cefe trunk: 21 patches from dan. 2008-10-08 15:50:03 +00:00
Chris PeBenito 0bfccda4e8 trunk: massive whitespace cleanup from dominick grift. 2008-07-23 21:38:39 +00:00
Chris PeBenito f7925f25f7 trunk: bump module versions for release. 2007-12-14 14:23:18 +00:00
Chris PeBenito 12e9ea1ae3 trunk: module version bumps for previous commit. 2007-10-02 17:15:07 +00:00
Chris PeBenito 350b6ab767 trunk: merge strict and targeted policies. merge shlib_t into lib_t. 2007-10-02 16:04:50 +00:00
Chris PeBenito 97e8156ecb add zabbix from dan 2007-04-11 18:55:44 +00:00