AUDIT_REQUEST_STATUS(3)
β¨ AUDIT_REQUEST_STATUS(3) β¨
okay so bestie, we're in the Linux Audit API today and this one is genuinely a little baddie π it lives in section 3 of the manual, and it's about asking the kernel to spill the tea about your audit setup. yes ma'am.
πΈ NAME πΈ
audit_request_status β request the status of the audit system. like, "hey kernel, how we doin?" and it actually answers π«Ά
π SYNOPSIS π
#include <libaudit.h>
int audit_request_status(int fd);"
π DESCRIPTION π
so audit_request_status basically walks up to the kernel and is like "pls send me a status structure" β and the kernel is like "say less". it requests that the kernel send a status structure describing the various settings, over the descriptor you hand it in fd.
and the structure it sends back? it's the audit_status struct, and it looks like this, no cap:
struct audit_status {
__u32 mask; /* Bit mask for valid entries */
__u32 enabled; /* 1 = enabled, 0 = disabled */
__u32 failure; /* Failure-to-log action */
__u32 pid; /* pid of auditd process */
__u32 rate_limit; /* messages rate limit (per second) */
__u32 backlog_limit; /* waiting messages limit */
__u32 lost; /* messages lost */
__u32 backlog; /* messages waiting in queue */
};
look at her. eight fields. iconic. β¨
π¦ RETURN VALUE π¦
so the return value is <= 0 on error β yes, zero or less means something went wrong, watch out for that one bestie π β otherwise it's the netlink sequence id number. and ngl, this function can have any error that sendto would encounter, so whatever sendto can throw at you, this can too. it's giving "inherited the whole family's problems" π
π SEE ALSO π
π AUTHOR π
Steve Grubb π (yes, THE Steve Grubb, we stan)
and that's the whole page, bestie!! this one came from Red Hat, back in Oct 2006, and it's still out here doing its thing. go get that status, queen. slay πβ¨π¦π
π¦ where this page comes from
- alpine 3.23: audit-doc 4.1.2-r2 Β· LGPL-2.1-or-later
- alpine 3.24: audit-doc 4.1.2-r6 Β· LGPL-2.1-or-later
- arch rolling: audit 4.2.1-1 Β· GPL-2.0-or-later AND LGPL-2.0-or-later
- centos-stream 10: audit-libs-devel 4.2.1-3.el10 Β· LGPL-2.0-or-later
- fedora 43: audit-libs-devel 4.1.1-2.fc43 Β· LGPL-2.0-or-later
- fedora 43: audit-libs-devel 4.1.1-2.fc43 Β· LGPL-2.0-or-later
- fedora 43: audit-libs-devel 4.2.1-1.fc43 Β· LGPL-2.0-or-later
- fedora 43: audit-libs-devel 4.2.1-1.fc43 Β· LGPL-2.0-or-later
- fedora 44: audit-libs-devel 4.1.4-1.fc44 Β· LGPL-2.0-or-later
- fedora 44: audit-libs-devel 4.1.4-1.fc44 Β· LGPL-2.0-or-later
- fedora 44: audit-libs-devel 4.2.1-1.fc44 Β· LGPL-2.0-or-later
- fedora 44: audit-libs-devel 4.2.1-1.fc44 Β· LGPL-2.0-or-later
- nixpkgs unstable: audit 4.2.1
- ubuntu resolute: libaudit-dev 1:4.1.2-1build1 Β· GPL-2.0-only
- ubuntu resolute: libaudit-dev 1:4.1.2-1ubuntu0.1 Β· GPL-2.0-only
- ubuntu stonking: libaudit-dev 1:4.1.2-1ubuntu1 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms