Puppet Class: auditd::config::audit_profiles::simp
- Defined in:
- manifests/config/audit_profiles/simp.pp
Summary
A set of general purpose audit rules that should meet most security policy requirementsOverview
The defaults for this profile generate a set of audit rules that are both usable on most systems and conformant with standard auditing requirements. A few key usage/implementation details about this profile should be noted:
* This profile uses optimized audit rules. Specifically, it
* Combines system call rules as much as possible
* By default, uses initial drop rules for the `auid` filters that
would be otherwise applied to all system call rules
* By default, uses an initial drop rule for cron events that are
prolific, but whose audit records are of very limited utility
* Although all security requirements allow optimization of audit rules,
most of the automated security scanners do not yet understand audit
rule optimizations. So, use of this profile may require explanation
of these simple, yet effective, optimizations.
* You may overload your system and/or log server, if you enable the
highly-prolific, but limited-utility audit capabilities that have been
intentionally disabled, here, despite being required by specific
security standards. 'chmod' auditing for all non-service users
is an example of such a capability.
* In some cases, the more targeted set of rules for non-service users
that have su'd to root may provide a viable subset of required auditing.
This targeting filtering is enabled by `$audit_su_root_activity` and
customized by `$root_audit_level`, `$basic_root_audit_syscalls`,
`$aggressive_root_audit_syscalls, and `$insane_root_audit_syscalls`.
383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 |
# File 'manifests/config/audit_profiles/simp.pp', line 383
class auditd::config::audit_profiles::simp (
Auditd::RootAuditLevel $root_audit_level = $::auditd::root_audit_level,
Boolean $audit_32bit_operations = $facts['os']['hardware'] ? { 'x86_64' => true, default => false },
String[1] $audit_32bit_operations_tag = '32bit-api',
Boolean $audit_auditd_cmds = true,
String[1] $audit_auditd_cmds_tag = 'access-audit-trail',
Array[String[1]] $audit_auditd_cmds_list, # data in modules
Boolean $audit_unsuccessful_file_operations = true,
String[1] $audit_unsuccessful_file_operations_tag = 'access',
Boolean $audit_chown = true,
String[1] $audit_chown_tag = 'chown',
Boolean $audit_chmod = false,
String[1] $audit_chmod_tag = 'chmod',
Boolean $audit_attr = true,
String[1] $audit_attr_tag = 'attr',
Boolean $audit_rename_remove = false,
String[1] $audit_rename_remove_tag = 'delete',
Boolean $audit_su_root_activity = true,
String[1] $audit_su_root_activity_tag = 'su-root-activity',
Boolean $audit_suid_sgid = true,
String[1] $audit_suid_sgid_tag = 'suid-exec',
Boolean $audit_kernel_modules = true,
String[1] $audit_kernel_modules_tag = 'modules',
Boolean $audit_time = true,
String[1] $audit_time_tag = 'audit_time_rules',
Boolean $audit_locale = true,
String[1] $audit_locale_tag = 'audit_network_modifications',
Boolean $audit_network_ipv4_accept = true,
String[1] $audit_network_ipv4_accept_tag = 'ipv4_in',
Boolean $audit_network_ipv6_accept = true,
String[1] $audit_network_ipv6_accept_tag = 'ipv6_in',
Boolean $audit_network_ipv4_connect = false,
String[1] $audit_network_ipv4_connect_tag = 'ipv4_in',
Boolean $audit_network_ipv6_connect = false,
String[1] $audit_network_ipv6_connect_tag = 'ipv6_in',
Boolean $audit_mount = true,
String[1] $audit_mount_tag = 'mount',
Boolean $audit_umask = false,
String[1] $audit_umask_tag = 'umask',
Boolean $audit_local_account = true,
String[1] $audit_local_account_tag = 'audit_account_changes',
Boolean $audit_selinux_policy = true,
String[1] $audit_selinux_policy_tag = 'MAC-policy',
Boolean $audit_selinux_cmds = false,
String[1] $audit_selinux_cmds_tag = 'privileged-priv_change',
Boolean $audit_login_files = true,
String[1] $audit_login_files_tag = 'logins',
Boolean $audit_session_files = true,
String[1] $audit_session_files_tag = 'session',
Optional[Boolean] $audit_sudoers = undef,
Optional[String[1]] $audit_sudoers_tag = undef,
Boolean $audit_cfg_sudoers = true,
String[1] $audit_cfg_sudoers_tag = 'CFG_sys',
Optional[Boolean] $audit_grub = undef,
Optional[String[1]] $audit_grub_tag = undef,
Boolean $audit_cfg_grub = true,
String[1] $audit_cfg_grub_tag = 'CFG_grub',
Boolean $audit_cfg_sys = true,
String[1] $audit_cfg_sys_tag = 'CFG_sys',
Boolean $audit_cfg_cron = true,
String[1] $audit_cfg_cron_tag = 'CFG_cron',
Boolean $audit_cfg_shell = true,
String[1] $audit_cfg_shell_tag = 'CFG_shell',
Boolean $audit_cfg_pam = true,
String[1] $audit_cfg_pam_tag = 'CFG_pam',
Boolean $audit_cfg_security = true,
String[1] $audit_cfg_security_tag = 'CFG_security',
Boolean $audit_cfg_services = true,
String[1] $audit_cfg_services_tag = 'CFG_services',
Boolean $audit_cfg_xinetd = true,
String[1] $audit_cfg_xinetd_tag = 'CFG_xinetd',
Optional[Boolean] $audit_yum = undef,
Optional[String[1]] $audit_yum_tag = undef,
Boolean $audit_cfg_yum = true,
String[1] $audit_cfg_yum_tag = 'yum-config',
Boolean $audit_yum_cmd = false,
String[1] $audit_yum_cmd_tag = 'package_changes',
Boolean $audit_rpm_cmd = false,
String[1] $audit_rpm_cmd_tag = 'package_changes',
Boolean $audit_ptrace = true,
String[1] $audit_ptrace_tag = 'paranoid',
Boolean $audit_personality = true,
String[1] $audit_personality_tag = 'paranoid',
Boolean $audit_passwd_cmds = true,
String[1] $audit_passwd_cmds_tag = 'privileged-passwd',
Boolean $audit_priv_cmds = true,
String[1] $audit_priv_cmds_tag = 'privileged-priv_change',
Boolean $audit_postfix_cmds = true,
String[1] $audit_postfix_cmds_tag = 'privileged-postfix',
Boolean $audit_ssh_keysign_cmd = true,
String[1] $audit_ssh_keysign_cmd_tag = 'privileged-ssh',
Boolean $audit_suspicious_apps = true,
String[1] $audit_suspicious_apps_tag = 'suspicious_apps',
Array[Stdlib::Absolutepath] $audit_suspicious_apps_list, # data in modules
Boolean $audit_systemd = true,
String[1] $audit_systemd_tag = 'systemd',
Boolean $audit_crontab_cmd = true,
String[1] $audit_crontab_cmd_tag = 'privileged-cron',
Boolean $audit_pam_timestamp_check_cmd = true,
String[1] $audit_pam_timestamp_check_cmd_tag = 'privileged-pam',
Array[String[1]] $basic_root_audit_syscalls, # data in modules
Array[String[1]] $aggressive_root_audit_syscalls, # data in modules
Array[String[1]] $insane_root_audit_syscalls # data in modules
) {
assert_private()
if $audit_sudoers != undef {
deprecation("${name}::audit_sudoers",
"'${name}::audit_sudoers' is deprecated. Use '${name}::audit_cfg_sudoers' instead")
$_audit_cfg_sudoers = $audit_sudoers
} else {
$_audit_cfg_sudoers = $audit_cfg_sudoers
}
if $audit_sudoers_tag != undef {
deprecation("${name}::audit_sudoers_tag",
"'${name}::audit_sudoers_tag' is deprecated. Use '${name}::audit_cfg_sudoers_tag' instead")
$_audit_cfg_sudoers_tag = $audit_sudoers_tag
} else {
$_audit_cfg_sudoers_tag = $audit_cfg_sudoers_tag
}
if $audit_grub != undef {
deprecation("${name}::audit_grub",
"'${name}::audit_grub' is deprecated. Use '${name}::audit_cfg_grub' instead")
$_audit_cfg_grub = $audit_grub
} else {
$_audit_cfg_grub = $audit_cfg_grub
}
if $audit_grub_tag != undef {
deprecation("${name}::audit_grub_tag",
"'${name}::audit_grub_tag' is deprecated. Use '${name}::audit_cfg_grub_tag' instead")
$_audit_cfg_grub_tag = $audit_grub_tag
} else {
$_audit_cfg_grub_tag = $audit_cfg_grub_tag
}
if $audit_yum != undef {
deprecation("${name}::audit_yum",
"'${name}::audit_yum' is deprecated. Use '${name}::'audit_cfg_yum instead")
$_audit_cfg_yum = $audit_yum
} else {
$_audit_cfg_yum = $audit_cfg_yum
}
if $audit_yum_tag != undef {
deprecation("${name}::audit_yum_tag",
"'${name}::audit_yum_tag' is deprecated. Use '${name}::'audit_cfg_yum_tag instead")
$_audit_cfg_yum_tag = $audit_yum_tag
} else {
$_audit_cfg_yum_tag = $audit_cfg_yum_tag
}
$_short_name = 'simp'
$_idx = auditd::get_array_index($_short_name, $auditd::config::profiles)
file { "/etc/audit/rules.d/50_${_idx}_${_short_name}_base.rules":
mode => $auditd::config::config_file_mode,
content => epp("${module_name}/rule_profiles/simp/base.epp")
}
}
|