Lines Matching defs:mac
362 mac_setsockopt_label(kauth_cred_t cred, struct socket *so, struct mac *mac)
369 error = mac_check_structmac_consistent(mac);
373 MALLOC(buffer, char *, mac->m_buflen, M_MACTEMP, M_WAITOK);
374 error = copyinstr(CAST_USER_ADDR_T(mac->m_string), buffer,
375 mac->m_buflen, &len);
395 struct mac *mac)
402 error = mac_check_structmac_consistent(mac);
406 MALLOC(elements, char *, mac->m_buflen, M_MACTEMP, M_WAITOK);
407 error = copyinstr(CAST_USER_ADDR_T(mac->m_string), elements,
408 mac->m_buflen, &len);
414 MALLOC(buffer, char *, mac->m_buflen, M_MACTEMP, M_WAITOK | M_ZERO);
418 mac->m_buflen);
421 error = copyout(buffer, CAST_USER_ADDR_T(mac->m_string),
432 struct mac *mac)
439 error = mac_check_structmac_consistent(mac);
443 MALLOC(elements, char *, mac->m_buflen, M_MACTEMP, M_WAITOK);
444 error = copyinstr(CAST_USER_ADDR_T(mac->m_string), elements,
445 mac->m_buflen, &len);
451 MALLOC(buffer, char *, mac->m_buflen, M_MACTEMP, M_WAITOK | M_ZERO);
455 mac->m_buflen);
458 error = copyout(buffer, CAST_USER_ADDR_T(mac->m_string),