;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2019 Danny Milosavljevic ;;; Copyright © 2020 Robin Green ;;; ;;; This file is part of GNU Guix. ;;; ;;; GNU Guix is free software; you can redistribute it and/or modify it ;;; under the terms of the GNU General Public License as published by ;;; the Free Software Foundation; either version 3 of the License, or (at ;;; your option) any later version. ;;; ;;; GNU Guix 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 General Public License for more details. ;;; ;;; You should have received a copy of the GNU General Public License ;;; along with GNU Guix. If not, see . (define-module (gnu services auditd) #:use-module (gnu services) #:use-module (gnu services configuration) #:use-module (gnu services base) #:use-module (gnu services shepherd) #:use-module (gnu packages admin) #:use-module (guix records) #:use-module (guix gexp) #:use-module (guix packages) #:export (auditd-configuration auditd-service-type %default-auditd-configuration-directory)) (define auditd.conf (plain-file "auditd.conf" "log_file = /var/log/audit.log\nlog_format = \ ENRICHED\nfreq = 1\nspace_left = 5%\nspace_left_action = \ syslog\nadmin_space_left_action = ignore\ndisk_full_action = \ ignore\ndisk_error_action = syslog\n")) (define %default-auditd-configuration-directory (computed-file "auditd" #~(begin (mkdir #$output) (copy-file #$auditd.conf (string-append #$output "/auditd.conf"))))) (define-record-type* auditd-configuration make-auditd-configuration auditd-configuration? (audit A big thanks to Eelco Dolstra, who designed and implemented Nix. Transposing functional programming discipline to package management proved to be inspiring and fruitful. Thanks to the following people who contributed to GNU Guix through suggestions, bug reports, patches, internationalization, or general infrastructure help: Lluís Batlle i Rossell <viric@viric.name> Sylvain Beucler <beuc@beuc.net> Carlos Carleos <carleos@uniovi.es> Felipe Castro <fefcas@gmail.com> Daniel Clark <dclark@pobox.com> Alexandru Cojocaru <xojoc@gmx.com> Aleix Conchillo Flaqué <aconchillo@gmail.com> Malcolm Cook <MEC@stowers.org> Thomas Danckaert <thomas.danckaert@gmail.com> Rafael Ferreira <rafael.f.f1@gmail.com> Christian Grothoff <christian@grothoff.org> Eric Hanchrow <eric.hanchrow@gmail.com> Konrad Hinsen <konrad.hinsen@fastmail.net> Brandon Invergo <brandon@gnu.org> Anders Jonsson <anders.jonsson@norsjovallen.se> Jeffrin Jose <ahiliation@yahoo.co.in> Kete <kete@ninthfloor.org> Daniel Kochmański <dkochmanski@hellsgate.pl> Matthew Lien <bluet@bluet