Skip to content
Mateusz Piotrowski edited this page Aug 5, 2016 · 4 revisions

struct vnode_au_info

General

The structure is required by au_to_attr() (see `au_token(3)).

Definition

The structure is defined in sys/security/audit/audit_private.h.

/*
 * Audit data is generated as a stream of struct audit_record structures,
 * linked by struct kaudit_record, and contain storage for possible audit so
 * that it will not need to be allocated during the processing of a system
 * call, both improving efficiency and avoiding sleeping at untimely moments.
 * This structure is converted to BSM format before being written to disk.
 */
struct vnode_au_info {
	mode_t	vn_mode;
	uid_t	vn_uid;
	gid_t	vn_gid;
	dev_t	vn_dev;
	long	vn_fsid;
	long	vn_fileid;
	long	vn_gen;
};

Usage

I've not found any interface functions for this structure so I guess it has to be managed manually.

Additionally, as we can see in contrib/openbsm/sys/bsm/audit_record.h:

#if defined(_KERNEL) || defined(KERNEL)
token_t	*au_to_attr(struct vnode_au_info *vni);
token_t	*au_to_attr32(struct vnode_au_info *vni);
token_t	*au_to_attr64(struct vnode_au_info *vni);
#endif