Lines Matching refs:hat
587 * aa_change_hat - change hat to/from subprofile
588 * @hats: vector of hat names to try changing into (MAYBE NULL if @count == 0)
589 * @count: number of hat names in @hats
590 * @token: magic value to validate the hat change
604 struct aa_profile *profile, *previous_profile, *hat = NULL;
624 /* attempting to change into a new hat or switch to a sibling */
628 /* find first matching hat */
629 for (i = 0; i < count && !hat; i++)
631 hat = aa_find_child(root, hats[i]);
632 if (!hat) {
643 * Audit the failure is based off of the first hat
654 hat = aa_new_null_profile(profile, 1);
655 if (!hat) {
661 target = hat->base.hname;
662 if (!PROFILE_IS_HAT(hat)) {
663 info = "target not hat";
669 error = may_change_ptraced_domain(current, hat);
677 error = aa_set_current_hat(hat, token);
703 aa_put_profile(hat);