| 972 | } |
| 973 | |
| 974 | static int |
| 975 | lomac_cred_check_visible(struct ucred *cr1, struct ucred *cr2) |
| 976 | { |
| 977 | struct mac_lomac *subj, *obj; |
| 978 | |
| 979 | if (!lomac_enabled) |
| 980 | return (0); |
| 981 | |
| 982 | subj = SLOT(cr1->cr_label); |
| 983 | obj = SLOT(cr2->cr_label); |
| 984 | |
| 985 | /* XXX: range */ |
| 986 | if (!lomac_dominate_single(obj, subj)) |
| 987 | return (ESRCH); |
| 988 | |
| 989 | return (0); |
| 990 | } |
| 991 | |
| 992 | static void |
| 993 | lomac_cred_create_init(struct ucred *cred) |
nothing calls this directly
no test coverage detected