MCPcopy Create free account
hub / github.com/F-Stack/f-stack / mac_check_structmac_consistent

Function mac_check_structmac_consistent

freebsd/security/mac/mac_framework.c:726–736  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

724}
725
726int
727mac_check_structmac_consistent(struct mac *mac)
728{
729
730 /* Require that labels have a non-zero length. */
731 if (mac->m_buflen > MAC_MAX_LABEL_BUF_LEN ||
732 mac->m_buflen <= sizeof(""))
733 return (EINVAL);
734
735 return (0);
736}
737
738SYSINIT(mac, SI_SUB_MAC, SI_ORDER_FIRST, mac_init, NULL);
739SYSINIT(mac_late, SI_SUB_MAC_LATE, SI_ORDER_FIRST, mac_late_init, NULL);

Callers 13

mac_execve_enterFunction · 0.85
sys___mac_get_pidFunction · 0.85
sys___mac_get_procFunction · 0.85
sys___mac_set_procFunction · 0.85
sys___mac_get_fdFunction · 0.85
kern___mac_get_pathFunction · 0.85
sys___mac_set_fdFunction · 0.85
kern___mac_set_pathFunction · 0.85
mac_setsockopt_labelFunction · 0.85
mac_getsockopt_labelFunction · 0.85
mac_getsockopt_peerlabelFunction · 0.85
mac_ifnet_ioctl_getFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected